Uploaded image for project: 'Webservices REST Module'
  1. Webservices REST Module
  2. RESTWS-456

Cannot unretire locations (or other metadata) via REST

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Should
    • Resolution: Fixed
    • Affects Version/s: 2.6
    • Fix Version/s: 2.12
    • Component/s: None

      Description

      Using the REST API I can retire a location like this:

      DELETE .../location/some-long-uuid
      

      I would expect to be able to unretire a location like this:

      POST .../location/some-long-uuid
      content: { retired: false }
      

      However this returns a status of 500 (which is also wrong, but ignore that) whose cause is "Some properties are not allowed to be set: retired".

      The location resource (and other metadata resources) should allow you unretire things.

      Dev Notes

      • I think we should add a default implementation of getUpdatableProperties() in MetadataDelegatingCrudResource that overrides the implementation in BaseDelegatingResource to add "retired".
      • Also, we have to go through all existing metadata resources and fix this in those, like LocationResource, that are overriding getUpdatableProperties().

        Gliffy Diagrams

          Attachments

            Activity

              People

              Assignee:
              dkayiwa Daniel Kayiwa
              Reporter:
              darius Darius Jazayeri
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - 3 hours
                  3h
                  Remaining:
                  Time Spent - 1 hour Remaining Estimate - 2 hours
                  2h
                  Logged:
                  Time Spent - 1 hour Remaining Estimate - 2 hours
                  1h