Uploaded image for project: 'Alfresco'
  1. Alfresco
  2. ALF-21511

When using the AlfDynamicPayloadButton it triggers an extra request in some cases

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Unprioritized
    • Resolution: Not a bug
    • Affects Version/s: 5.0.d Community
    • Fix Version/s: None
    • Component/s: Aikau
    • Security Level: external (External user)
    • Labels:
      None
    • Environment:
      Tomcat 7, MySQL, Windows 10
    • Resolution Time Custom Field:
      2 weeks, 5 days, 18 hours, 56 minutes, 15 seconds

      Description

      When using the AlfDynamicPayloadButton in this case on the ALF_SEARCH_REQUEST payload it triggers a double search request in some cases.

      This happens without the button is pushed.

      Steps to reproduce:
      Add the below code to faceted-search.get.js wrapped in an extension module.
      When pressing enter/button on the search field once the double results are listed and 2 is the search request fired seen in firebug.
      When pressing it again only once it's fired.

      if you change the name again in the input field the request is fired twice.

      
      var widget = widgetUtils.findObject(model.jsonModel.widgets, "id", "FCTSRCH_RESULTS_MENU_BAR");
      var actionDynamicResults = {
          name: "alfresco/buttons/AlfDynamicPayloadButton",
          config: {
              label: "Download As Zip",
              publishTopic: "CNTZ_DOWNLOAD_SEARCH",
              publishPayloadSubscriptions: [{
                  topic: "ALF_SEARCH_REQUEST"
              }],
          }
      };
      
      widget.config.widgets.push(actionDynamicResults);
      

        Attachments

          Structure

            Activity

              People

              • Assignee:
                closedissues Closed Issues
                Reporter:
                tmalik Tahir Malik
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Date of First Response:

                  Structure Helper Panel