User tests: Successful: Unsuccessful:
Pull Request for Issue #16954 .
The operator precedence in showon expressions was not working as expected, that is, from left to right. All operators prior to the right-most were being ignored completely.
Set up a form using the XML file (which is actually the .txt file in the attached zip). This has three fields (Field 1, Field 2 and Field3) which can each be set to Yes or No. Depending on the state of these fields, further fields will be shown or hidden according to the showon expressions they contain. All possible operator combinations for the three fields are included. Change the field states and compare with the spreadsheet in the attached zip which shows the actual and expected results.
As per the Expected section of the spreadsheet in the attached zip.
As per the Actual section of the spreadsheet in the attached zip.
Add a note to https://docs.joomla.org/Form_field to explain that left-right precedence should be expected.
Status | New | ⇒ | Pending |
Category | ⇒ | JavaScript |
Not in j3. take your pick
Labels |
Added:
?
|
Minified file added.
@chrisdavenport could you please do the same changes for J4: https://github.com/joomla/joomla-cms/blob/4.0-dev/build/media_source/system/js/showon.es6.js
I have tested this item
Title |
|
Status | Pending | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2019-04-02 15:15:15 |
Closed_By | ⇒ | HLeithner |
I tested it successful. thx
The cms.js file will also need to be amended. Any preference on minifiers?