Uploaded image for project: 'Stripes'
  1. Stripes
  2. STRIPES-130

Substitution syntax in manifest template strings

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed (View Workflow)
    • P3
    • Resolution: Done
    • None
    • None
    • None

    Description

      At present, template strings in a Stripes Connect manifest can recognise and substitute sequences of the form:

      • ?{name} – replaced with the URL query parameter name
      • :{name} – replaced with the URL path component name

      (And we will in future also be able to substitute from the React component state and/or props – see STRIPES-123.)

      But sometimes we need to do more sophisticated things, dependent on whether or not the named parameter has a defined value. For example, to implement sorting, we want to include the sortby keyword in the CQL query only when the sort URL query parameter is defined.

      To support this, we should implement fallbacks as in Bash, the Bourne Again Shell. See the Parameter Expansion section of its manual. For example, ?{sort:+sortby} should expand to the constant string sortby when the sort URL query parameter is defined, and nothing at all when it is not.

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                mike Mike Taylor
                mike Mike Taylor
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - 0 minutes
                    0m
                    Logged:
                    Time Spent - 5 hours
                    5h

                    TestRail: Runs

                      TestRail: Cases