Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-25549

Picture.Resize does not work with Document as input

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 9.10-HF13, 10.2, 10.3-SNAPSHOT
    • Fix Version/s: 10.10-HF10, 11.1, 2021.0
    • Component/s: Image Management
    • Release Notes Summary:
      The operation Picture.Resize works with Document as input.
    • Backlog priority:
      150

      Description

      Having a document as input (a regular `Picture` with all its view already computed for example), calling the `Picture.Resize` operation with a document as input fails at line 62:

      pictureBlob = (Blob) mvp.getView(mvp.getOrigin()).getContent();
      

      This is because mvp.getOrigin() gets the document property "picture", field "origin", which stays empty most of the time. So ` mvp.getView` fails with a NPE.

      The code should not try to get any image from picture:views, but file:content. Maybe with an optional parameter to get the blob from another field. Maybe also using MultiviewPicture but then with a parameter telling which view to use.

      Workaround waiting for the fix: get the blob and pass it to the operation

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                6 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