Uploaded image for project: 'Service Packs and Hot Fixes'
  1. Service Packs and Hot Fixes
  2. MNT-7084

Form asset output paths should be updated whenever their content is updated

    Details

    • Type: Service Pack Request
    • Status: Closed (View Workflow)
    • Resolution: Won't Fix
    • Affects Version/s: No Version
    • Fix Version/s: 4.0
    • Component/s: ZZ_Archive
    • Labels:
      None
    • Bug Priority:
      Category 2
    • ACT Numbers:

      550, 13975

      Description

      When the output path pattern for a web form instance data or rendition contains a reference to the xml variable (for example, /${webapp}/data/${xml['/ns:foo/ns:bar']}.xml ) the generated content will be located in a path which depends on the data entered by the content author... but only the very first time the content is generated. If a content author subsequently edits the data, the output path of the xml file or rendition does not change to reflect the new data. This is inconsistent: if the user were to delete and re-create the form assets, they'd end up in a different place.

      We want the output paths to be updated whenver the form assets are updated. This mostly involves re-evaluating the output path when a form asset is regenerated or edited, and performing a rename operation if this output path has changed. That's fairly simple, although complications arise if the updated output path corresponds to a node that already exists. We'd prefer that this node be deleted or renamed out of the way, or at least that this be a configurable option on a per-output-path-pattern basis.

      A possible problem with updating output paths in this way is that the date variable (e.g., /${webapp}/data/data-${date?string("yyyy-MM-dd")}.xml) seems like it was designed never to be updated. That is, it was meant to "capture" the date of the original creation. If so, there are several ways to deal with this: you could specifically wire the date variable so it alone never changes, even in subsequent evaluations of the output path. Or, you could have whether or not the output path is re-evaluated be a configurable option on a per-output-path-pattern basis.

      Thus, one possible way web form output path patterns would be configured via the UI:

      Save Location
      Use the following pattern when saving content:
      Output path pattern: [ /${webapp}/data/${xml['/ns:foo/ns:bar']}.xml ]
      Update the location (o) every time the content is regenerated or edited ( ) only when the content is first created
      If other content already exists in the save location, (o) delete it ( ) rename it out of the way ( ) report an error

        Attachments

          Structure

            Activity

              People

              • Assignee:
                closedissues Closed Issues
                Reporter:
                saltine Joseph Calzaretta
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Structure Helper Panel