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

Use languageId to determine Content Locale in JournalTransformer

    Details

      Description

      Given that getArticleContent can be called through the JSON WS where themeDisplay is very hard to set, I think it would be better to use languageId first when translating the template.

       

       

      Steps to reproduce:

      1. Create a structure with a Select field (and a template for it). Create a web content from this structure.
      2. Access the /api/jsonws page, select "journal" for Context Name, and then select the get-article-content method that accepts groupId, articleId, languageId and themeDisplay parameters.
      3. Fill in the groupId and articleId of the web content, en_US for languageId, and leave themeDisplay empty. Click Invoke.

      Result: The content is not shown and in the Tomcat console you see

      2018-08-22 15:06:43.413 ERROR [http-apr-8080-exec-3][JSONWebServiceServiceAction:97] com.liferay.portal.kernel.templateparser.TransformException: Unhandled exception 

        Attachments

          Activity

            People

            Assignee:
            brian.chan Brian Chan
            Reporter:
            balazs.safrany-kovalik Balázs Sáfrány-Kovalik
            Recent user:
            Csaba Turcsan
            Participants of an Issue:
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Packages

                Version Package
                7.0.0 DXP FP60
                7.0.0 DXP SP9
                7.0.X
                7.1.10 DXP FP3
                7.1.1 CE GA2
                7.1.10.1 SP1
                7.1.X
                Master