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

The scheduled task to "approve" scheduled web content is changing the modified date

    Details

      Description

      The scheduled task to "approve" scheduled web content is changing the modified date and this opperation is not changing the content.

      This task should be change only the statusDate, indicating the date in where the status was changed.

      Steps to reproduce:

      1. Set journal.article.check.interval=2 in the portal-ext.properties and restart the server.

      2. Create a Web Content:

      WC1: Title=WC1, Content=WC1 and in the Scheduled dates set the display date as the current date plus 2 minutes.

      3. Launch the next query:

      SELECT urlTitle,createDate,modifiedDate,displayDate,status,statusDate FROM JournalArticle;
      
      urlTitle	createDate	modifiedDate	displayDate	status	statusDate
      wc1	2014-09-02 18:19:25.0	2014-09-02 18:19:25.0	2014-09-02 18:20:00.0	7	2014-09-02 18:19:25.0		
      

      Note that the status=7 and the createDate, modifiedDate, displayDate and the statusDate are 2014-09-02 18:19:25.0

      4. Wait for 2 minutes and launch again the same query

      urlTitle	createDate	modifiedDate	displayDate	status	statusDate
      wc1	2014-09-02 18:19:25.0	2014-09-02 18:20:59.0	2014-09-02 18:20:00.0	0	2014-09-02 18:20:59.0
      

      Result the status=0 and the modifiedDate and the statusDate are equals, just 2014-09-02 18:19:25.0.

      Expected the modifiedDate is not changed and only it is updated the statusDate.
      Reason an status change should not update the metadata of a Web Content, specially if this metadata are used in the wcm interface.

      This is a regression of behaviour after introduce the SCHEDULED status in WC.

      NOTE: A similar issue happens if you send a WC to the Recycle bin and then restore it.

        Attachments

        1. fixed_1.png
          fixed_1.png
          7 kB
        2. fixed_2.png
          fixed_2.png
          6 kB
        3. fixed_3.png
          fixed_3.png
          6 kB
        4. fixed_4.png
          fixed_4.png
          6 kB
        5. reproduced_1.png
          reproduced_1.png
          6 kB
        6. reproduced_2.png
          reproduced_2.png
          6 kB

          Issue Links

            Activity

              People

              • Assignee:
                yvonne.han Yvonne Han
                Reporter:
                jose.jimenez Jose Jimenez
                Participants of an Issue:
                Recent user:
                Esther Sanz
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  4 years, 36 weeks, 3 days ago