No Code Attached Yet J3 Issue
avatar billtomczak
billtomczak
16 Jul 2018

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

Steps to reproduce the issue

Edit /administrator/components/com_content/models/forms/article.xml and edit the publish_up field attributes:

  • remove translateformat
  • add format="%Y-%m-%d %I:%M %P"
  • add 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.

Expected result

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)

Actual result

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)

System information (as much as possible)

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".

Additional comments

screen shot 2017-10-11 at 01 57 39

avatar billtomczak billtomczak - open - 16 Jul 2018
avatar joomla-cms-bot joomla-cms-bot - change - 16 Jul 2018
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 16 Jul 2018
avatar franz-wohlkoenig franz-wohlkoenig - change - 17 Jul 2018
Category JavaScript
avatar franz-wohlkoenig franz-wohlkoenig - change - 23 Jul 2018
Status New Information Required
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 23 Jul 2018

@dgrammatiko a Comment by you?


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

avatar GCLW
GCLW - comment - 27 Jul 2018

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 also noticed that manually editing the input field and then clicking on the calendar, the calendar would not display the AM/PM correctly. I made further changes to correct that. Yes, a client of mine will actually manually type in a change to the input field.

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.


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

avatar brianteeman brianteeman - change - 2 Aug 2018
Labels Added: J3 Issue
avatar brianteeman brianteeman - labeled - 2 Aug 2018
avatar franz-wohlkoenig franz-wohlkoenig - change - 24 Aug 2018
Status Information Required Discussion
avatar joomla-cms-bot joomla-cms-bot - change - 30 Mar 2019
Closed_Date 2019-03-30 11:20:43 2019-03-30 11:20:44
Closed_By franz-wohlkoenig joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 30 Mar 2019
avatar franz-wohlkoenig franz-wohlkoenig - change - 30 Mar 2019
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2019-03-30 11:20:43
Closed_By franz-wohlkoenig
avatar joomla-cms-bot
joomla-cms-bot - comment - 30 Mar 2019
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 30 Mar 2019

closed as having Pull Request #24417

avatar billtomczak
billtomczak - comment - 1 Apr 2019

Thank you https://github.com/Arpit-24! I can confirm the PR corrects the problem in English.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 1 Apr 2019

@billtomczak please mark your Test at https://issues.joomla.org/tracker/joomla-cms/24417 as successfully

avatar laoneo laoneo - change - 14 Apr 2022
Status Closed New
Closed_Date 2019-03-30 11:20:44
Closed_By joomla-cms-bot
Labels Added: No Code Attached Yet
Removed: ?
avatar laoneo laoneo - reopen - 14 Apr 2022
avatar laoneo
laoneo - comment - 14 Apr 2022

Pr #24417 is abandoned. So reopening the issue.

avatar brianteeman
brianteeman - comment - 23 Aug 2022

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

avatar zero-24 zero-24 - change - 23 Aug 2022
Status New Closed
Closed_Date 0000-00-00 00:00:00 2022-08-23 13:45:58
Closed_By zero-24
avatar zero-24 zero-24 - close - 23 Aug 2022

Add a Comment

Login with GitHub to post a comment