[4.0] Null date corrections for Jgrid and Published buttons#26751
[4.0] Null date corrections for Jgrid and Published buttons#26751wilsonge merged 7 commits intojoomla:4.0-devfrom
Conversation
|
@infograf768 Was on my task list, but you were faster. Code looks good to me. Will test tonight after work. |
|
@richard67 |
|
@infograf768 I know. Not all of them shall be thrown away, some of them we need to keep for 3rd party extensions. But a check for real NULL should be added. Maybe @wilsonge can check hf the changes here are ok. To me they seem to be ok. |
|
I have tested this item ✅ successfully on d5feaae This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/26751. |
|
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/26751. |
|
@ChristineWk |
|
If we want to support 3rd party extensions with this layout which doesn't null as date type we have to keep getNullDate and just add a === NULL to the if-statement. If we don't want to support this, you can remove the $nullDate variable completely. Since we still have getNullDate in the near future (4.x) we should support it in the layout too. Please change thx |
Should be lowercase @infograf768 In PublishedButton.php the checks in lines 89 and 95 should also be corrected. They were wrong before nulldate changes, too, because in lines 63 and 64 the datetimes are set to |
Thanks, please do and correct all. |
|
@wilsonge Shall JGrid or the Published Buttons be usable by 3rd party extensions so we have to keep old nulldate checks here? |
|
Trashed previous and made new with tomorrow date :-) |
Of course they must be - they are part of the librarries |
|
Yup we need to keep compat in the libraries please. but we can definitely mark as deprecated |
[4.0] Check for both old (pseudo-)null dates and real NULL values in Jgrid and Published buttons
|
I merged @richard67 patch into this. It works fine for me. Do we also need to modify
@ChristineWk |
|
@wilsonge I don't know what exactly to mark as deprecated. |
That was for the icon on front end editing iirc |
|
@ChristineWk If I understand the functionality right, the above is correct. Pending means publish up is in future. Today is the 21st. |
|
Or do I maybe understand the issue wrong? |
|
I have tested this item ✅ successfully on d0128ab After patch: Publish down time is only shown if really set. The icon and tool tip is set according to the times (expired if publish down in past, pending if publish up in future, published if publish up in past and publish down in future or no publish down set). This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/26751. |
|
I have tested this item ✅ successfully on d0128ab This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/26751. |
|
RTC This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/26751. |
|
If nobody else wants to do that, I will make another PR for |
|
Thanks! |





Pull Request for Issue #26660
Summary of Changes
Null Date is now defined by
nulland no more byFactory::getDbo()->getNullDate()Testing Instructions
Create a site or admin module and enter a date for the Start Publishing.
Although no Finish Publishing date is set, the tooltip will display a wrong finish date.
Before patch
After patch
Note:
Remains in core 3 files with instances of
Factory::getDbo()->getNullDate()I did not touch these as I was not sure where to test them.