Conflicting Files ? Failure

User tests: Successful: Unsuccessful:

avatar chmst
chmst
21 May 2019

Summary of Changes

Use created date in mod_popular and mod_latest if publish_up is nulldate.

Testing Instructions

Add a new article, then have a look on molule popular articles and mod_latest on the administrator panel.

Expected result

Dates are correct

Actual result

popular-publish_up

Documentation Changes Required

avatar chmst chmst - open - 21 May 2019
avatar chmst chmst - change - 21 May 2019
Status New Pending
avatar chmst chmst - change - 21 May 2019
Title
Use created date in mod popular if publish_up is nulldate
[4.0] Use created date in mod popular if publish_up is nulldate
avatar chmst chmst - change - 21 May 2019
Title
Use created date in mod popular if publish_up is nulldate
[4.0] Use created date in mod popular if publish_up is nulldate
avatar chmst chmst - edited - 21 May 2019
avatar joomla-cms-bot joomla-cms-bot - change - 21 May 2019
Category Modules Administration
avatar brianteeman
brianteeman - comment - 21 May 2019

The same is true for Recently Added Articles

avatar chmst chmst - change - 21 May 2019
Labels Added: ?
avatar chmst chmst - change - 21 May 2019
The description was changed
avatar chmst chmst - edited - 21 May 2019
avatar brianteeman
brianteeman - comment - 21 May 2019

Sorry but this looks to be a band aid solution and doesn't address the real issue as we are going to see the same problem throughout joomla and extensions wherever we use the publish_up date. Surely the fix is to return to the j3 method of setting the article publish_up date as equally to the created date by default instead of setting it to null.

avatar chmst
chmst - comment - 21 May 2019

What do you suggest to show in the modules if the publish_up date is null?

avatar brianteeman
brianteeman - comment - 21 May 2019

I just took a closer look and actually its complicated

The behaviour now in Joomla 4 is that if you create a new article with a status of unpublished then it is created with a null for publish_up
If you go in to the article and change the status to publish and then save and you get a publish_up of now
BUT If you change the status from the list view then you do not get a publish_up date at all

So I think there are two seperate bugs here.

  1. The article doesnt always get a publish_up date when it is published
  2. What to display for an article date in the module when it has no publish_up date

When Issue 1 is fixed then the only time you will not have a publish_up date is when it is not published. So in that scenario we should be displaying "Unpublished" - displaying two different dates (published/created) is not correct

avatar brianteeman
brianteeman - comment - 21 May 2019

OR it can always display created date

avatar richard67
richard67 - comment - 21 May 2019

I would assume by the name of that module, Popular Articles, that it does not show unpublished articles at all, because how shall an article become popular if it has never been published, or how shall it become more popular if it ever had been published and then was unpublished. But that's maybe only my opinion.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24968.

avatar brianteeman
brianteeman - comment - 21 May 2019

You assume incorrectly. It might have been published in the past for example

avatar richard67
richard67 - comment - 21 May 2019

Yes, and then be unpublished again. Question is if it then still makes sense to show it in the list of popular articles. I think that's a matter of taste.

Anyway, bug no. 1 with the status change in the list view to published does not set the publish date, this has to be fixed.

For 2. I think showing text "Unpublished" would be good for my taste, if that is possible.

avatar chmst
chmst - comment - 21 May 2019

Maybe showing the create date is the simplest and clearest solution. All other possible combinations need explanation. If the haeder says "Date created" instead of "Date" it is clear enough, no matter which history the article has gone through.
Additionally, the items could get the icon for published/unpublished also on the
modules.

avatar Quy
Quy - comment - 17 Oct 2019

Please fix conflicts and see related PRs regarding null value for dates.

avatar richard67
richard67 - comment - 17 Oct 2019

@chmst If necessary I can advise regarding null date, just ping me if needed.

avatar richard67
richard67 - comment - 17 Oct 2019

If an article is newly created with unpublished state, the publish_up time is null in PHP and NULL in SQL after recent merged PRs. Before it was set to (pseudo-)nulldates in that case. In this case the publish_up time should NOT be set to the created time. As soon as the article is published, publish_up should be set by the software, otherwise it is a bug and has to be fixed. An article newly created with published state should also have publish_up set. Unpublished articles should not be shown by these modules, as far as I understand. So I would recommend to test if the issue which shall be solved by this PR still is an issue on current 4.0-dev branch. If it still is, I will check and advise how to fix, otherwise if it is not an isue anymore, this issue can be closed.

avatar chmst
chmst - comment - 17 Oct 2019

Thank you for your time and information. The original issue (new itemwit date -0001 .. ) is solved in 4.0,
So I'll close this ussue.

avatar chmst chmst - close - 17 Oct 2019
avatar chmst chmst - change - 17 Oct 2019
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2019-10-17 18:10:48
Closed_By chmst
Labels Added: Conflicting Files
avatar richard67
richard67 - comment - 17 Oct 2019

Sometimes we are lucky with J4 ?

Add a Comment

Login with GitHub to post a comment