[MGNLUI-6966] Saving JcrMultiField on locale containing "_" results in wrong naming of the JCR nodes Created: 01/Dec/21 Updated: 09/May/23 Resolved: 27/Mar/23 |
|
| Status: | Closed |
| Project: | Magnolia UI |
| Component/s: | dialogs, forms |
| Affects Version/s: | 6.2.13 |
| Fix Version/s: | 6.3.0, 6.2.31 |
| Type: | Bug | Priority: | Major |
| Reporter: | Roberto Gaona | Assignee: | Antonín Juran |
| Resolution: | Fixed | Votes: | 2 |
| Labels: | VN-Analysis, VN-Testing | ||
| Σ Remaining Estimate: | Not Specified | Remaining Estimate: | Not Specified |
| Σ Time Spent: | 2.5d | Time Spent: | 2.5d |
| Σ Original Estimate: | Not Specified | Original Estimate: | Not Specified |
| Attachments: |
|
|||||||||||||||||||||||||
| Issue Links: |
|
|||||||||||||||||||||||||
| Sub-Tasks: |
|
|||||||||||||||||||||||||
| Template: | ||||||||||||||||||||||||||
| Acceptance criteria: |
Empty
|
|||||||||||||||||||||||||
| Task DoD: |
[X]*
Doc/release notes changes? Comment present?
[X]*
Downstream builds green?
[X]*
Solution information and context easily available?
[X]*
Tests
[X]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
|||||||||||||||||||||||||
| Bug DoR: |
[ ]*
Steps to reproduce, expected, and actual results filled
[ ]*
Affected version filled
|
|||||||||||||||||||||||||
| Release notes required: |
Yes
|
|||||||||||||||||||||||||
| Date of First Response: | ||||||||||||||||||||||||||
| Visible to: |
Thomas Duffey
|
|||||||||||||||||||||||||
| Epic Link: | FieldsMaintenance | |||||||||||||||||||||||||
| Sprint: | Nucleus 32 | |||||||||||||||||||||||||
| Story Points: | 3 | |||||||||||||||||||||||||
| Team: | ||||||||||||||||||||||||||
| Work Started: | ||||||||||||||||||||||||||
| Description |
Steps to reproduce
Definition used for the jcrMultiField property: form: properties: randomText: $type: textField label: Random text here mediaList: $type: jcrMultiField i18n: true required: false field: name: mediaSwitchable $type: switchableField field: $type: radioButtonGroupField name: mediaSwitchable layout: horizontal defaultValue: image datasource: $type: optionListDatasource options: - name: image label: global.label.image value: image - name: video label: Youtube value: video itemProvider: $type: currentItemProvider forms: - name: image properties: image: $type: damLinkField required: true - name: video properties: video: $type: compositeField itemProvider: $type: currentItemProvider label: "" properties: youtubeId: $type: textField required: true label: Youtube ID placeholderImage: $type: damLinkField required: true label: placeholderImage Find attached a i18n node configuration for the site: config.modules.multisite.config.sites.travel.i18n.xml Expected resultsData is stored in JCR without issues, naming each locale nodes after their respective locale. Actual resultsNode's locale gets repeated and extended every time an edit is done on the item:
WorkaroundDevelopment notes |
| Comments |
| Comment by Roman Kovařík [ 01/Dec/21 ] |
|
Where does that underscore come from, is it really added by the system or is it in an old content? |
| Comment by Jörg Wirsig [ 09/Dec/21 ] |
|
It is generated by the system. Maybe because of the configuration in i18n
But i think it is a standard isn't it? java.util.Locale#toString() * Returns a string representation of this <code>Locale</code> * object, consisting of language, country, variant, script, * and extensions as below: * <blockquote> * language + "_" + country + "_" + (variant + "_#" | "#") + script + "_" + extensions * </blockquote> https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/LocaleUtils.html#toLocale-java.lang.String- also supports that notation. Will this ticket be picked for upcoming release? And when is the next bugfix release plannend? |