Uploaded image for project: 'FreePBX'
  1. FreePBX
  2. FREEPBX-7338

CDR Reports CallerID Number & Destination - can't filter by both fields at once, it shows incorrect info

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.11
    • Fix Version/s: 2.11
    • Component/s: CDR Reports
    • Labels:
      None
    • ToDo:

      Description

      CDR Reports module 2.11.0.8
      I think there is a mistype in /admin/modules/cdr/page.cdr.php on line 654

      
      //Allow people to search SRC and DSTChannels using existing fields
      if (isset($cnum)) {
        $cnum_length = strlen($cnum);
        $cnum_type = substr($cnum, 0 ,strpos($cnum , 'cnum') -1);
        $cnum_remaining = substr($cnum, strpos($cnum , 'cnum'));
        $src = str_replace('AND cnum', '', $cnum);
      
        $cnum = "$cnum_type ($cnum_remaining OR src $src)";
      } 
       \\
      if (isset($dst)) {
        $dst_length = strlen($dst);
        $dst_type = substr($dst, 0 ,strpos($dst , 'dst') -1);
        $dst_remaining = substr($dst, strpos($dst , 'dst'));
        $dstchannel = str_replace('AND dst', '', $dst);
      
        $cnum = "$dst_type ($dst_remaining OR dstchannel $dstchannel)";
      }
      

      I think it should be:

      
      -- $cnum = "$dst_type ($dst_remaining OR dstchannel $dstchannel)";
      ++ $dst = "$dst_type ($dst_remaining OR dstchannel $dstchannel)";
      

      With this change filter by both fields works correctly.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                kurpachev Alexey Kurpachev
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  NextupJiraPlusStatus

                  Error rendering 'slack.nextup.jira:nextup-jira-plus-status'. Please contact your Jira administrators.