This is a re-report of the issue reported in #18304. PR #18240 did not fix these issues and they remain as of v3.8.10
Creating a new issue as requested by franz-wohlkoenig
Edit /administrator/components/com_content/models/forms/article.xml and edit the publish_up field attributes:
translateformat
format="%Y-%m-%d %I:%M %P"
timeformat="12"
The final result should look something like:
<field
name="publish_up"
type="calendar"
label="COM_CONTENT_FIELD_PUBLISH_UP_LABEL"
description="COM_CONTENT_FIELD_PUBLISH_UP_DESC"
showtime="true"
format="%Y-%m-%d %I:%M %P"
timeformat="12"
size="22"
filter="user_utc"
/>
Then edit any article's Start Publishing
field to set the time to midnight using the calendar tool and save the changes.
After saving, the time displaying in the text field should be 12:00 am (as of v3.8.7, the am/pm selector forces to pm)
The time in the text field is set to 12:00 pm
Also, the am/pm selector text is not wide enough and the option texts are hidden (see screenshot)
The time can be set manually in the text box to '12:00 am' and is saved as expected. But then you'll notice the hour drop down selection is empty. (See screenshot)
For the am/pm selector, it has a colspan="1"
hardcoded and I believe it should be colspan="2"
.
Labels |
Added:
?
|
Category | ⇒ | JavaScript |
Status | New | ⇒ | Information Required |
While my attempted "fix" did work for format="%Y-%m-%d %H:%M:%S"
it did not fix other format and timeformat combinations.
While making additional changes I tested the following combinations:
format="%Y-%m-%d %I:%M %P"
& timeformat="12"
: passed
format="%Y-%m-%d %I:%M %P"
& timeformat="24"
: passed
format="%Y-%m-%d %H:%M:%S"
& timeformat="12"
: passed
format="%Y-%m-%d %H:%M:%S"
& timeformat="24"
: passed
The test was flipping noon and midnight back and forth while saving and paying attention to when the calendar updated, did the input field display the format correctly. Also the calendar reading the format and displaying in the correct timeformat the first time you click on it.
I'm attaching the updated calendar.txtcalendar.txt file, if someone would like to minify the file and test feel free. I'm not the original author of this powerful calendar code, I just made some changes where I thought they were needed.
Labels |
Added:
J3 Issue
|
Status | Information Required | ⇒ | Discussion |
Closed_Date | 2019-03-30 11:20:43 | ⇒ | 2019-03-30 11:20:44 |
Closed_By | franz-wohlkoenig | ⇒ | joomla-cms-bot |
Status | Discussion | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2019-03-30 11:20:43 |
Closed_By | ⇒ | franz-wohlkoenig |
Set to "closed" on behalf of @franz-wohlkoenig by The JTracker Application at issues.joomla.org/joomla-cms/21148
Thank you https://github.com/Arpit-24! I can confirm the PR corrects the problem in English.
@billtomczak please mark your Test at https://issues.joomla.org/tracker/joomla-cms/24417 as successfully
Status | Closed | ⇒ | New |
Closed_Date | 2019-03-30 11:20:44 | ⇒ | |
Closed_By | joomla-cms-bot | ⇒ | |
Labels |
Added:
No Code Attached Yet
Removed: ? |
Thank you for raising this issue.
Joomla 3 is now in security only mode with no further bug fixes or new features.
As this issue doesn't relate to Joomla 4 it will now been closed.
If we are mistaken and this does apply to Joomla 4 please open a new issue (and reference this one if you wish) with updated details for testing in Joomla 4.
cc @zero-24
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2022-08-23 13:45:58 |
Closed_By | ⇒ | zero-24 |
@dgrammatiko a Comment by you?
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/21148.