User tests: Successful: Unsuccessful:
…hEvent(new Event('change' - this ensures scripts that watch the input field using eventListeners and onchange attributes will respond to the event.
Pull Request for Issue # .
changes in calendar field javascript to mirror #33540 and #32756
edit the file administrator/components/com_content/forms/article.xml and find the publish_up field at line 129 and add the attrribute
onchange="alert(1);"
to this field and then edit an article and change the publish_up field (using the date picker)
Add to Atum index.php before closing tag :
<script type="module">
if (window.jform_publish_up){
window.jform_publish_up.addEventListener('change', () => {
alert(2);
})
}
</script>
Go to Article editing, and try to change the publish_up date.
You get a two alert(1) messages and one alert(2)
You get one alert(1) message and alert(2)
Status | New | ⇒ | Pending |
Category | ⇒ | JavaScript Repository NPM Change |
Labels |
Added:
NPM Resource Changed
?
|
Thanks @richard67 - conflict resolved now. Don't know why by fetch upstream and merge didn't work first time!
Not sure I understand this one. I get two (1) alerts and on (2) alert with or without the patch. I have checked that npm run build:js gives the correct js output. I must have done something wrong in the test.
Title |
|
Not sure I understand this one. I get two (1) alerts and on (2) alert with or without the patch. I have checked that npm run build:js gives the correct js output. I must have done something wrong in the test.
My mistake this PR mirrored one from Joomla 3.9.x and I had initially miss-read the code and added a duplicated dispatchEvent call by mistake. I did correct the file about 5 hours ago - I don't know if you had tested the patch before then or if the patch tester has a delay on it??
I have amended the testing instructions too now.
I have tested this item
Labels |
Added:
Conflicting Files
|
This PR can be closed since #5b54c98b762df1f342eb5c374cc7dff15d86bd3b on 22/05 merging in staging applied the same changes
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2021-06-17 11:39:06 |
Closed_By | ⇒ | GeraintEdwards |
@GeraintEdwards Your PR starts with a conflict in file
build/media_source/system/js/fields/calendar.es5.js
. Can it be that your 4.0-dev branch was outdated when you created that PR, or is that a while ago?