Uploaded image for project: 'Confluence Cloud'
  1. Confluence Cloud
  2. CONFCLOUD-70639

Calling getMacroData returns stale results

    XMLWordPrintable

Details

    Description

      Issue Summary

      The AP.confluence.getMacroData() operation does not reliably return the data saved using the AP.confluence.saveMacro() operation as indicated in the [API documentation|https://developer.atlassian.com/cloud/confluence/jsapi/confluence/]. 

      Steps to Reproduce

      1. Open a macro, hit submit and save data via javascript api.
      2. When rendering the preview inside the page editor, we call getMacroData and we are receiving an empty object.
      3. Edit the same macro and perform getMacroData. You get the correct information.
      4. Add more info, submit and save.
      5. When rendering the preview inside the page editor, call getMacroData().

       

      Expected Results

      At step 2, the data returned by getMacroData() is empty. At step 5, the data returned by getMacroData() is the data saved in step 4.

      Actual Results

      The data returned by getMacroData() is the same as the data saved using the saveMacro() as indicated in the [API documentation|https://developer.atlassian.com/cloud/confluence/jsapi/confluence/]. 

      Workaround

      Pass state to the macro view page using URL query parameters.

      Attachments

        Issue Links

          Activity

            People

              c72dac02e601 Tapan Parikh
              dmorrow@atlassian.com Dugald Morrow
              Votes:
              15 Vote for this issue
              Watchers:
              17 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: