I patched the code so the CDR works as expected.
--- showcdr.php.backup 2014-01-02 14:18:11.000000000 -0800
+++ showcdr.php 2014-01-02 16:23:48.135836816 -0800
@@ -161,7 +161,8 @@
$grid->set_pk('uniqueid');
$grid->add_structure('number', 'text',null,'');
$grid->salt("dldli3ksa");
-$grid->set_fields("calldate,IF(dst='".$extension."','inbound','outbound') as direction,IF(dst='".$extension."',src,dst) as number,duration,billsec,disposition,uniqueid");
+$grid->set_fields("calldate,IF(dst='".$extension."' OR dstchannel LIKE 'SIP/$extension-________' ,'inbound','outbound') as direction,IF(dst='".$extension."' OR dstchannel LIKE 'SIP/$extension-________' ,src,dst) as number,duration,billsec,disposition,uniqueid");
+
$grid->hide_field('uniqueid');
$grid->no_edit_field('uniqueid');
$grid->no_edit_field('number');
@@ -174,11 +175,11 @@
$mifilt = $_REQUEST['filterdir'];
if($mifilt=="") {
- $condstring ="(src='$extension' OR dst='$extension') ";
+ $condstring ="(src='$extension' OR dst='$extension' OR dstchannel LIKE 'SIP/$extension-________' OR channel LIKE 'SIP/$extension-________') ";
} else if($mifilt=="inbound") {
- $condstring ="(dst='$extension') ";
+ $condstring ="(dst='$extension' OR dstchannel LIKE 'SIP/$extension-________' ) ";
} else {
- $condstring="(src='$extension') ";
+ $condstring="(src='$extension' OR channel LIKE 'SIP/$extension-________' ) ";
}
$customboton="<div class='fbutton'>
@@ -211,6 +212,7 @@
$grid->set_condition($condstring);
+
/*
$fieldname = Array();
$fieldname[]=trans('Unique ID');