Running API calls on /rest/api/2/settings/columns with filter ID as parameter creates an inconsistency

XMLWordPrintable

    • 8.13
    • 1
    • Severity 3 - Minor
    • 1

      Issue Summary

      Based on our documentation If you are a Jira Admin, you will also see the System tab, where you can change the columns for all users who have not set their own defaults:

      That said, we started comparing the columns we have returning the GET of the API and the System tab, and we stated that they should match between themselves, we assume.
      Also because this System tab is the only way that ADMINs can edit the default system columns through the UI.

      During some tests running these APIs in a custom filter, we found one way to create an inconsistency.
      We basically removed all the default columns using the API, so it started returning [EMPTY], in the other side, the "System" tab continued to show columns selected.

      These are the issues faced caused by this inconsistency:

      • If you click on "Restore Defaults" button in "Columns", all the columns disappear;
      • If you go to "System" tab, it appears that we have Default columns selected.

      Steps to Reproduce

      For some reason, when we open a filter, and go to "Columns > System" it brings data from /rest/api/2/settings/columns?_=ID_HERE, instead of /rest/api/2/settings/columns.

      To reproduce the BUG:

      Obviously, this inconsistency can be created in different ways, because we started investigating it after an issue raised by a client. We are only showing that it's possible to be created:

      Run the following API to check the default system columns:

      /rest/api/2/settings/columns 

      Compare with what you have on JQL filters > Columns > System.

      To create an inconsistency: (Use an admin user)

      1. Create a new filter;
      2. Open it and Browser DevTools;
      3. Go to Network tab (Clean it);
      4. In Jira, click on Columns > System;
      5. It should return a request URL with something like:
      6. /rest/api/2/settings/columns?_=ID_HERE 
      7. Copy "As fetch";
      8. Go to the console, paste it and change the method from "GET" to "PUT" and Run (you must have Admin Rights);
      9. Run the following API to check the default system columns: (It should return empty " [] ")
      10.  /rest/api/2/settings/columns 
      11. Compare with what you have on JQL filters > Columns > System.
      12. You will see that the columns are still marked in System tab.

      The problem is that the fields in "Columns > System tab" are marked based on somewhere I didn't figure out yet.

      Expected Results

      Marked fields in Columns > System tab and the output of /rest/api/2/settings/columns API should match between themselves.

      Actual Results

      The fields marked in Columns > System tab and the output of /rest/api/2/settings/columns API are not matching.

      Workaround

      As an ADMIN, open the "Columns > System" tab > check if the columns are marked > and click on "DONE".

            Assignee:
            Unassigned
            Reporter:
            Mauricio Cardoso (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: