<!-- 
RSS generated by JIRA (9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b) at Mon Feb 12 09:04:38 CET 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>Magnolia - Issue tracker</title>
    <link>https://jira.magnolia-cms.com</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-uk</language>    <build-info>
        <version>9.4.2</version>
        <build-number>940002</build-number>
        <build-date>19-01-2023</build-date>
    </build-info>


<item>
            <title>[MGNLUI-3241] Composite Field: Add cross field validation between the subfields of the composite field</title>
                <link>https://jira.magnolia-cms.com/browse/MGNLUI-3241</link>
                <project id="10625" key="MGNLUI">Magnolia UI</project>
                    <description>&lt;p&gt;Cross field validation is not a feature of the current Magnolia Form UI implementation.&lt;/p&gt;

&lt;p&gt;I have created a general issue for requesting this feature as a general feature throughout form fields: &lt;a href=&quot;https://jira.magnolia-cms.com/browse/MGNLUI-3240&quot; title=&quot;UI Form: Add cross field validation feature&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MGNLUI-3240&quot;&gt;&lt;del&gt;MGNLUI-3240&lt;/del&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In this ticket the the idea is to implement it for the CompositeField, as it would be a alternative to handle many of the use cases that occur of fields that need to be cross validated.&lt;br/&gt;
Possible use cases:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;A &quot;point of interest&quot; CompositeField with the sub-fields &quot;Longitude&apos; and &apos;Latitude&apos;. The field is not required, BUT if in one sub field a value is entered, the other also needs a value (no value or all have a value situation).&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Idea:&lt;br/&gt;
Extending the CompositeField by a cross field validation of its sub fields.&lt;br/&gt;
Overriding the validate() method and delegating to a configurable field comparator class.&lt;/p&gt;

&lt;p&gt;POC implementation:&lt;br/&gt;
I tried quickly such an implementation to test if it is possible.&lt;br/&gt;
I created:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;CrossFieldsValidatingCompositeField.java which extends the CompositeField and its definition &amp;amp; factory class.&lt;br/&gt;
The field delegates to an implementation of the CrossFieldsComparator.java interface to do the field comparison.&lt;/li&gt;
	&lt;li&gt;CrossFieldsComparator.java does the field comparison.&lt;/li&gt;
	&lt;li&gt;AllEmptyOrNoneEmpty.java is the implementation for this use case, checking if one field ha a value.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Attention: This is just a POC, not product ready code! It can be used in projects, but will probably need some adaptions.&lt;/p&gt;

&lt;p&gt;Usage:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Add a &apos;fieldTypes&apos; mapping of the FieldDefinition and the FieldFactory class. (added bootstrap file)&lt;/li&gt;
	&lt;li&gt;Use the CrossFieldsValidatingCompositeField class for a composite field.&lt;/li&gt;
	&lt;li&gt;Define the crossFieldsComparator property pointing to the implementation CrossFieldsComparator for the specific use case, in this case here the AllEmptyOrNoneEmpty.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Other use cases:&lt;br/&gt;
Just implement another version of CrossFieldsComparator.&lt;/p&gt;

&lt;p&gt;Constraints:&lt;br/&gt;
I first tried to use a Vaadin Validator on the composite field.&lt;br/&gt;
This doesn&apos;t work because the Validator is decoupled form the invoked filed. So The Validator is not aware of any configured sub fields of a &quot;Magnolia Composite Field&quot;.&lt;br/&gt;
Providing this values to the Validator to do a comparison would be very hackish (interlinking Magnolia Configurations and Vaadin Validators).&lt;/p&gt;</description>
                <environment></environment>
        <key id="41487">MGNLUI-3241</key>
            <summary>Composite Field: Add cross field validation between the subfields of the composite field</summary>
                <type id="2" iconUrl="https://jira.magnolia-cms.com/secure/viewavatar?size=xsmall&amp;avatarId=10891&amp;avatarType=issuetype">New Feature</type>
                                            <priority id="6" iconUrl="https://jira.magnolia-cms.com/images/icons/priorities/neutral.gif">Neutral</priority>
                        <status id="6" iconUrl="https://jira.magnolia-cms.com/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are not closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="9">Obsolete</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="cringele">Christian Ringele</reporter>
                        <labels>
                    </labels>
                <created>Tue, 4 Nov 2014 13:50:21 +0100</created>
                <updated>Thu, 3 Mar 2016 16:16:26 +0100</updated>
                            <resolved>Thu, 3 Mar 2016 16:16:08 +0100</resolved>
                                    <version>5.2.10</version>
                    <version>5.3.5</version>
                                                    <component>forms</component>
                        <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="121721" author="mgeljic" created="Thu, 3 Mar 2016 16:16:08 +0100"  >&lt;p&gt;While we acknowledge the importance of this feature, we intend to address it from this higher-level issue: &lt;a href=&quot;https://jira.magnolia-cms.com/browse/MGNLUI-2542&quot; title=&quot;Dynamic forms &amp;amp; cross-field interaction&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MGNLUI-2542&quot;&gt;MGNLUI-2542&lt;/a&gt; (just rephrased it to &quot;dynamic forms &lt;b&gt;&amp;amp; cross-field validation&lt;/b&gt;&quot;, I also collected this requirement within composite fields there in description).&lt;br/&gt;
Therefore I&apos;m closing this issue, feel free to watch &lt;a href=&quot;https://jira.magnolia-cms.com/browse/MGNLUI-2542&quot; title=&quot;Dynamic forms &amp;amp; cross-field interaction&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MGNLUI-2542&quot;&gt;MGNLUI-2542&lt;/a&gt;. &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.magnolia-cms.com/images/icons/emoticons/wink.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10010">
                    <name>relation</name>
                                            <outwardlinks description="is related to">
                                                        </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="48237">MGNLUI-3617</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10022">
                    <name>supersession</name>
                                                                <inwardlinks description="is superseded by">
                                        <issuelink>
            <issuekey id="35611">MGNLUI-2542</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                            <attachment id="26324" name="AllEmptyOrNoneEmpty.java" size="2291" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26327" name="CrossFieldsComparator.java" size="1876" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26331" name="CrossFieldsValidatingCompositeField-Configuration.jpg" size="149086" author="cringele" created="Tue, 4 Nov 2014 13:52:34 +0100"/>
                            <attachment id="26328" name="CrossFieldsValidatingCompositeField.java" size="2563" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26329" name="CrossFieldsValidatingCompositeFieldDefinition.java" size="2780" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26330" name="CrossFieldsValidatingCompositeFieldFactory.java" size="3415" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26325" name="config.modules.training-templating.dialogs.myTextImage.form.tabs.tabMain.fields.pointOfInterest.xml" size="6003" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                            <attachment id="26326" name="config.modules.ui-framework.fieldTypes.crossValidatingCompositeField.xml" size="1888" author="cringele" created="Tue, 4 Nov 2014 13:50:21 +0100"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                            <customfield id="customfield_14166" key="com.okapya.jira.checklist:checklist">
                        <customfieldname>Acceptance criteria</customfieldname>
                        <customfieldvalues>
                            
        <checklist>
        <![CDATA[
                            




                
                                    <div class="o-completion" style="display: flex; flex-shrink: 0;"><span  class="aui-lozenge aui-lozenge-complete" style="font-size: 12px; font-weight: normal; display: flex; flex-direction: row; align-items: center;" ><span style="padding-right: 4px; vertical-align: middle;"><svg width="15" height="15" viewBox="0 0 15 15" xmlns="http://www.w3.org/2000/svg" fill="white"><path clip-rule="evenodd" d="m10.41037,3.42544l-7.86501,0c-0.72395,0 -1.31084,0.58688 -1.31084,1.31084l0,7.86508c0,0.7239 0.58689,1.3108 1.31084,1.3108l7.86501,0c0.724,0 1.3109,-0.5869 1.3109,-1.3108l0,-7.86508c0,-0.72396 -0.5869,-1.31084 -1.3109,-1.31084zm-7.86501,-0.65542c-1.08593,0 -1.96626,0.88032 -1.96626,1.96626l0,7.86508c0,1.0859 0.88033,1.9662 1.96626,1.9662l7.86501,0c1.086,0 1.9663,-0.8803 1.9663,-1.9662l0,-7.86508c0,-1.08594 -0.8803,-1.96626 -1.9663,-1.96626l-7.86501,0z" fill-rule="evenodd"/><path d="m5.09049,10.18526l-1.82767,-1.82766l-0.78479,0.78479l2.61246,2.61246l5.38758,-5.38754l-0.78483,-0.78479l-4.60275,4.60274z"/></svg></span><span>Empty</span></span></div>
                        ]]>
    </checklist>


                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10111" key="com.atlassian.jira.toolkit:reporterdomain">
                        <customfieldname>Company</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>magnolia-cms.com</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10031" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of First Response</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 3 Mar 2016 16:16:08 +0100</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_12730" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_14151" key="com.atlassian.jira.toolkit:message">
                        <customfieldname>Docu info</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10061" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comm is not jira-dev</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10071" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last participant</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>mgeljic</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_13136" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            7 years, 50 weeks, 3 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                            <customfield id="customfield_10020" key="com.atlassian.jira.toolkit:attachments">
                        <customfieldname>Number of attachments</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>8.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10150" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname>Number of comments</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10011" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>cringele</customfieldvalue>
            <customfieldvalue>mgeljic</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10090" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Patch included</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10100"><![CDATA[Yes]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10833" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|i0006v:048k</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10244" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>25753</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14145" key="com.intenso.jira.issue-templates:issue-templates-customfield">
                        <customfieldname>Template</customfieldname>
                        <customfieldvalues>
                            


                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                            <customfield id="customfield_15131" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Time in Discovery</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10032" key="com.atlassian.jira.ext.charting:timeinstatus">
                        <customfieldname>Time in Status</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        </customfields>
    </item>
</channel>
</rss>