Changeset 964

Show
Ignore:
Timestamp:
08/25/08 14:08:41 (3 months ago)
Author:
rach
Message:

add Sell Rates and Buy Rates CDR result

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/admin/Public/call-log-customers.php

    r956 r964  
    7676$FG_TABLE_COL[]=array (gettext("CalledNumber"), "calledstation", "10%", "center", "SORT", "30", "", "", "", "", "", "remove_prefix"); 
    7777$FG_TABLE_COL[]=array (gettext("Destination"), "destination", "10%", "center", "SORT", "30", "", "", "", "", "", "remove_prefix"); 
     78$FG_TABLE_COL[]=array (gettext("Buy Rate"), "buyrate", "5%", "center", "SORT", "30", "", "", "", "", "", "display_2bill"); 
     79$FG_TABLE_COL[]=array (gettext("Sell Rate"), "calledrate", "5%", "center", "SORT", "30", "", "", "", "", "", "display_2bill"); 
    7880$FG_TABLE_COL[]=array (gettext("Duration"), "sessiontime", "6%", "center", "SORT", "30", "", "", "", "", "", "display_minute"); 
    7981$FG_TABLE_COL[]=array (gettext("CardUsed"), "username", "6%", "center", "SORT", "", "30", "", "", "", "", "linktocustomer"); 
     
    9496         
    9597// This Variable store the argument for the SQL query 
    96 $FG_COL_QUERY='t1.starttime, t1.src, t1.dnid ,t1.calledstation, t1.destination, t1.sessiontime, t1.username, t3.trunkcode, t1.terminatecause, t1.sipiax, t1.buycost, t1.sessionbill, case when t1.sessionbill!=0 then ((t1.sessionbill-t1.buycost)/t1.sessionbill)*100 else NULL end as margin,case when t1.buycost!=0 then ((t1.sessionbill-t1.buycost)/t1.buycost)*100 else NULL end as markup'; 
     98$FG_COL_QUERY='t1.starttime, t1.src, t1.dnid ,t1.calledstation, t1.destination, t1.buyrate ,t1.calledrate ,t1.sessiontime, t1.username, t3.trunkcode, t1.terminatecause, t1.sipiax, t1.buycost, t1.sessionbill, case when t1.sessionbill!=0 then ((t1.sessionbill-t1.buycost)/t1.sessionbill)*100 else NULL end as margin,case when t1.buycost!=0 then ((t1.sessionbill-t1.buycost)/t1.buycost)*100 else NULL end as markup'; 
    9799if (LINK_AUDIO_FILE) { 
    98100        $FG_COL_QUERY .= ', t1.uniqueid'; 


Google