Uploaded image for project: 'Nuxeo Python Client'
  1. Nuxeo Python Client
  2. NXPY-25

Allow strings as properties

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.0
    • Fix Version/s: 2.0.0
    • Component/s: None
    • Tags:
    • Story Points:
      2

      Description

      Currently only array of properties are allowed in operations parameters. We can let the user construct the final properties by allowing string.

      Both snippets will do the same thing:

      operation = nuxeo.operation('Document.Create')
      operation.params({
          'type': 'File',
          'name': 'foo.txt',
          'properties': {'dc:title': 'foo.txt', 'dc:description': 'bar'}
      })
      operation.input('/')
      doc = operation.execute()
      
      operation = nuxeo.operation('Document.Create')
      operation.params({
          'type': 'File',
          'name': 'foo.txt',
          'properties': 'dc:title=foo.txt\ndc:description=bar'
      })
      operation.input('/')
      doc = operation.execute()
      

        Attachments

          Activity

            People

            • 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 - 15 minutes
                15m