Menu

#2225 iTop Lifecycle Mandatory Fields Order

3.1.0
closed
nobody
None
Solved
Extension
Cosmetic
2.7.9
defect
2024-01-31
2024-01-31
wnet2
No

This issue has bugged me quite a while and I was searching alle the code and could not find the reason.

In a lifecycle process, fields can be requested either suggested (must_prompt) or mandatory. Usually the sequence is following the form sequence.
For Example if you have
field1
field2
field3
and you request for a certain lifecycle action field2 and field3 as mandatory, there there will be the field2 and field3 in perfect order.
field2
field3

If i.e. field2 is an external key and has a depedency for, lets say field1, theses fields will be shown at last. In our case:
field3
field2

Code Example:
<field id="field2" xsi:type="AttributeExternalKey">
<filter><![CDATA[SELECT Subfield WHERE field1 = :this->field1]]>
</filter>
<dependencies>
<attribute id="field1">
</attribute></dependencies>
In the lifecycle section:</field>

          <state id="planned">
                    <highlight>
                        <code>planned</code>
                    </highlight>
                    <inherit_flags_from>new</inherit_flags_from>
        <flags>
          <attribute id="field1"><read_only/></attribute>
          <attribute id="field2"><must_prompt/><mandatory/></attribute>
          <attribute id="field3"><must_prompt/></attribute>

Is there any reason for this behavior or is there an bug in the code?
Since I do have only iTop 2.6 instances, I do have not testet this in version 3.x
For any further inqueries, please do not hesitate to contact me.
Thanks

Discussion

  • Vincent @ Combodo

    • status: new --> closed
    • Milestone: 2.7.11 --> 3.1.0
    • Resolution: --> Solved
     
  • Vincent @ Combodo

    Resolved in 3.1.0, the order in your example case will be
    field2
    field3

     

Log in to post a comment.