Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Wed Apr 24, 2024 4:05 am
Voice Broadcast System


All times are UTC




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: FreeTime2Call interacts with initblock
PostPosted: Thu Jun 28, 2007 3:34 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
I've been testing the inclusive minutes feature and found that it works as expected (calls are billed at 0.00/min) unless initblock > 0. If the call is answered (initblock/60)*rateinitial is deducted from the card.

In this example I had a balance of 11, and the route costs 0.02. I could afford 550 minutes, but the 3,000 minutes/month package was added to the call timeout. All works as expected here.
Code:
a2billing.php|1: file:Class.A2Billing.php - line:760 - TIMEOUT::> 213000  : minutes=3550 - seconds=0
  a2billing.php|1: file:Class.RateEngine.php - line:960 - app_callingcard: Dialing 'SIP/[email protected]|60|HRrL(213000000:61000:30000)' with timeout of '213000'.
  a2billing.php|1:
  a2billing.php|1: file:Class.RateEngine.php - line:985 - app_callingcard: CIDGROUPID='-1' OUTBOUND CID SELECTED IS '0'.
    -- AGI Script Executing Application: (Dial) Options: (SIP/[email protected]|60|HRrL(213000000:61000:30000))
    -- Limit Data for this call:
    -- - timelimit     = 213000000
    -- - play_warning  = 61000
    -- - play_to_caller= yes
    -- - play_to_callee= no
    -- - warning_freq  = 30000
    -- - start_sound   = UNDEF
    -- - warning_sound = timeleft
    -- - end_sound     = UNDEF
    -- Called [email protected]
    -- SIP/xxx.xx.xx.xxx-0063da10 is ringing
    -- SIP/xxx.xx.xx.xxx-0063da10 answered SIP/xx.xx.xxx.xx-b8004900



And here we see 0.01 being deducted from the user which is the initblock x rateinitial == 30*0.02 == 0.01

Code:
  a2billing.php|1: file:Class.RateEngine.php - line:1086 - -> dialstatus : ANSWER, answered time is 61
  a2billing.php|1:
  a2billing.php|1: file:Class.RateEngine.php - line:1090 - [USEDRATECARD=0]
  a2billing.php|1: file:Class.RateEngine.php - line:777 - ft2c_package_offer : 1 ; 180000 ; 180000
  a2billing.php|1: file:Class.RateEngine.php - line:791 - :[ID_CARD_PACKAGE_OFFER CREATED : 16]:['3', '2', '61']
  a2billing.php|1: file:Class.RateEngine.php - line:848 - [CC_asterisk_stop  QUERY = INSERT INTO cc_call (uniqueid,sessionid,username,nasipaddress,starttime,sessiontime, calledstation,  terminatecause, stoptime, calledrate, sessionbill, calledcountry, calledsub, destination, id_tariffgroup, id_tariffplan, id_ratecard, id_trunk, src, sipiax, buyrate, buycost, id_card_package_offer) VALUES ('1183042214.1085', 'SIP/xx.xx.xxx.xx-b8004900',  'xxxxxxxxxx', '', CURRENT_TIMESTAMP - interval '61 seconds' , '61', '01xxxxxxxxx', 'ANSWER', now(), '0.02', '+0.01',  '', '', 'uk. exeter', '1', '9', '36197', '3', '1xxxxxxxxx', '0', '0.01275', '0.0129116666667', '16')]
  a2billing.php|1: file:Class.RateEngine.php - line:851 - [CC_asterisk_stop 1.1: SQL: DONE : result=1]
  a2billing.php|1: file:Class.RateEngine.php - line:869 - [CC_asterisk_stop 1.2: SQL: UPDATE cc_card SET credit= credit-0.01  , redial='01xxxxxxxxx' ,  lastuse=now(), nbused=nbused+1 WHERE username='2xxxxxxxxx']
  a2billing.php|1: file:Class.RateEngine.php - line:874 - UPDATE cc_trunk SET secondusedreal = secondusedreal + 61 WHERE id_trunk='3'
  a2billing.php|1: file:Class.RateEngine.php - line:878 - UPDATE cc_tariffplan SET secondusedreal = secondusedreal + 61 WHERE id='9'
  a2billing.php|1: file:a2billing.php - line:309 - [a2billing account stop]


Not so much a bug I guess, but something to be aware of.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 
VoIP Billing solution


All times are UTC


Who is online

Users browsing this forum: No registered users and 8 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group