Hello,
I defined some custom metadata (numeric and text) with constraint. I can edit it in share and all the constraint works fine. Like only numeric or specific length. I also customized the advanced search screen to use my custom field but the constraint did not work on the numeric field. I can input any character as much as i want without any validation. How come the validation works when editing and not when searching?
New field declaration:
<property name="fadq:no_clie">
<title>Numéro du client</title>
<description>Numéro du client</description>
<type>d:int</type>
<mandatory>false</mandatory>
<index enabled="true">
<tokenised>TRUE</tokenised>
<facetable>true</facetable>
</index>
<constraints>
<constraint name="fadq:MINMAX_790bb2f8-0589-4296-8919-278bc24758fd" type="MINMAX">
<parameter name="minValue">
<value>0.0</value>
</parameter>
<parameter name="maxValue">
<value>9999999.0</value>
</parameter>
</constraint>
</constraints>
</property>
Field used in advanced search:
<field id="fadq:no_clie" label-id="Numéro du client" set="deuxCol">
<control template="/org/alfresco/components/form/controls/number.ftl" />
</field>
Regards,
Marc
Does any information here assist you?
https://docs.alfresco.com/community/concepts/dev-extensions-share-form-field-validation-handlers.htm...
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.