Morning all, is it just me or has someone else come across the problem that CRON job a2billing_bill_diduse.php is charging users that have free DID's assigned to them. For instance I have a monthly charge rate assigned to a DID of $10 (for reference purposes). However I specify Free in the billing but it still goes ahead bills the calling card the amount stated in the MRC.
Looking at the SQL it seems there isnt an exclusion for billingtype = 3 (IE Free). When enumerating the DID's it's including the free ones.
Making a minor change to the Cron job seems to have fixed it ....
"SELECT id_did, reservationdate, month_payed, fixrate, cc_card.id, credit, email, did, typepaid, cc_did.billingtype,creditlimit,reminded FROM (cc_did_use INNER JOIN cc_card on cc_card.id=id_cc_card) INNER JOIN cc_did ON (id_did=cc_did.id) WHERE ( releasedate IS NULL OR releasedate < '1984-01-01 00:00:00') AND cc_did_use.activated=1 AND cc_did.billingtype <> '3' ORDER BY cc_card.id ASC"
A minor issue i know...
cheers
mike
|