Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-17498

Workflow: cannot approve Web Content via API

    Details

      Description

      Using the single approver v1.

      I have a standard web content file. With the API i try to approve it.

      i tried :

      ServiceContext approveContext = ServiceContextFactory.getInstance(JournalArticle.class.getName(), request);
      approveContext.setWorkflowAction(WorkflowConstants.ACTION_PUBLISH);
      JournalArticleLocalServiceUtil.updateStatus(getUserId(), journalArticle, WorkflowConstants.STATUS_APPROVED, URL, approveContext);

      and

      journalArticle.setStatus(WorkflowConstants.STATUS_APPROVED);
      JournalArticleLocalServiceUtil.updateJournalArticle(journalArticle);

      when i go back to the control panel i now have the document with the correct version number , with status approved.
      However the document is still under "my workflows".

        Attachments

          Activity

            People

            Assignee:
            mika.koivisto Mika Koivisto
            Reporter:
            luc.pannekoeke@honda-eu.com [email protected] (Inactive)
            Participants of an Issue:
            Recent user:
            Esther Sanz
            Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Days since last comment:
              8 years, 30 weeks, 6 days ago

                Packages

                Version Package
                6.1.1 CE GA2