Child pages
  • Conditional validation rules against dataset

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Expand
Code Block
<ac:structured-macro ac:macro-id="e15f05e9-90a9-4725-bd84-af49bedf9a8c" ac:name="confiform" ac:schema-version="1">
  <ac:parameter ac:name="formName">f</ac:parameter>
  <ac:rich-text-body>
    <p>
      <ac:structured-macro ac:macro-id="56f6d25e-8791-4b69-9f83-93d3a9a85e29" ac:name="confiform-field-definition" ac:schema-version="1">
        <ac:parameter ac:name="fieldName">myddfield</ac:parameter>
        <ac:parameter ac:name="fieldLabel">My drop down field</ac:parameter>
        <ac:parameter ac:name="values">false[A=this is A|B=this is B|C=this is C|]</ac:parameter>
        <ac:parameter ac:name="type">select</ac:parameter>
      </ac:structured-macro>
    </p>
    <ac:structured-macro ac:macro-id="a855e900-ea9c-44e7-b838-dfe48529a95d" ac:name="confiform-field-definition-rules" ac:schema-version="1">
      <ac:parameter ac:name="condition">myddfield:B AND [count]:&gt;=3</ac:parameter>
      <ac:parameter ac:name="fieldName">There are already 3 items of B value</ac:parameter>
      <ac:parameter ac:name="action">Validation rule dataset</ac:parameter>
      <ac:parameter ac:name="actionFieldName">myddfield</ac:parameter>
    </ac:structured-macro>
    <p> <ac:structured-macro ac:macro-id="639bf3c1-fa34-43c7-8dce-e8ab9f483f76" ac:name="confiform-entry-register" ac:schema-version="1">
        <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter>
        <ac:rich-text-body>
          <p> </p>
        </ac:rich-text-body>
      </ac:structured-macro> </p>
    <p> </p>
  </ac:rich-text-body>
</ac:structured-macro>
Info

Of course you can have as many validation rules as you want/need, with different conditions (which span across many fields if necessary)