08-09-2017 08:15 AM
In relation to a old question https://community.alfresco.com/thread/211781-selectoneftl-no-available-options i have a surf extensions with the configs tag, now i want to build my form:
<config evaluator="string-compare" condition="signed">
<forms>
<form>
<field-visibility>
............................................
<show id="my_form_sign_firma.tipo"/>
...................................
</field-visibility>
<appearance>
.....................
<field id="my_form_sign_firma.tipo" label-id="property.form.sign.my_form_sign_firma.tipo">
<control template="/org/alfresco/components/form/controls/selectone.ftl"/>
<control-param name="options">PADES,CADES,DETACHED</control-param>
</field>
....................
</appearance>
</form>
</forms>
</config>
this return the message "no options are aviable" when i "popup" the form.
I dont't want to build a model with a type and set a constraint for make it work, like suggested on the old topic, there is a more easy solution like customize the selectone.ftl for avoid this issue? if is a issue and not a bad configuration by me.
09-04-2017 11:48 AM
Hello.
The XML you are using is invalid, and that is why it is not working.
You should not be closing the <control> tag before adding the <control-param> one
Thy this one instead
<field id="my_form_sign_firma.tipo" label-id="property.form.sign.my_form_sign_firma.tipo">
<control template="/org/alfresco/components/form/controls/selectone.ftl">
<control-param name="options">PADES,CADES,DETACHED</control-param>
</control>
</field>
08-11-2017 10:20 AM
UPDATE: The problem is in the selectone.ftl template the control field.control.params.options?? && field.control.params.options != "" fail so it's just show me the else alternative but in theory i set the control-param-options like in the official documentation , this is all standard code of alfresco, it's must not fail and i don't understand where is the error.
09-04-2017 11:48 AM
Hello.
The XML you are using is invalid, and that is why it is not working.
You should not be closing the <control> tag before adding the <control-param> one
Thy this one instead
<field id="my_form_sign_firma.tipo" label-id="property.form.sign.my_form_sign_firma.tipo">
<control template="/org/alfresco/components/form/controls/selectone.ftl">
<control-param name="options">PADES,CADES,DETACHED</control-param>
</control>
</field>
Explore our Alfresco products with the links below. Use labels to filter content by product module.