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

"Additional Settings" not saved adding outbound route / "Additional Settings" applied to the wrong route adding an outbound route

    XMLWordPrintable

    Details

    • ToDo:

      Description

      This has probably been broken since FreePBX 13. The hook code uses a session variable based workaround to store and update Additional Setting values for new routes, The approach only works in the pre-v13 paradigm where the route page was simply refreshed upon submit. The current routing Table->Form structure breaks the add route hook code for Additional Settings.

      Unless I'm missing some unforeseen interaction, the core module fix is a one line change to update $_REQUEST with the new route id, allowing it to be visible to the any hooks called. Any modules hooking routing also needs to be updated.

      How to reproduce:

      Make sure the callrecording module is installed.

      "Additional Settings" are not saved when adding outbound route

      • Add a new minimal outbpund route
        1. Connectivity->Outbound Routes-> Add Outbound Route
        2. Set Route Settings -> Route Name = NeverTestRt
        3. Set Dial Patterns -> match pattern = X
        4. Set Additional Settings -> Call Recording = Never
        5. Click Submit
        6. Click Dashboard on the top bar menu
      • Go back to route and see if call recording setting was saved
        1. Connectivity->Outbound Routes
        2. Click Actions "edit" icon for NeverTestRt
        3. Click Additional Settings Tab

      At this point you should see the Call Recording method was not saved as "Never". The same symptoms can be reproduced with Pin Sets.

      "Additional Settings" may be applied to the wrong route when adding an outbound route

      • Edit/Confirm NeverTestRt to make sure Call Recording is set to Never
        1. Connectivity->Outbound Routes
        2. Click Action "edit" icon for NeverTestRt
        3. Set Additional Settings -> Call Recording = Never
        4. Click Submit
      • Go back to NeverTestRt and confirm call recording setting was saved
        1. Connectivity->Outbound Routes
        2. Click Action "edit" icon for NeverTestRt
        3. Click Additional Settings tab
        4. Confirm "Never" setting was saved for Call Recording.
      • Add a new *Force*TestRt outbound route
        1. Connectivity->Outbound Route-> Add Outbound Routes
        2. Set Route Settings -> Route Name = *Force*TestRt
        3. Set Dial Patterns -> match pattern = X
        4. Set Additional Settings -> Call Recording = Force
        5. Click Submit
        6. Click the Action "edit" icon for *Never*TestRt
        7. Click Additional Settings tab

      At this point you should see NeverTestRt's Call Recording erroneously changed from "Never" to "Force".

      Why it's been hard to test
      If you add a route and then immediately click edit on the same route, the session variable workaround executes and updates correctly.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                jerrm jerrm
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  NextupJiraPlusStatus

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