blob: 5a09d00a53dd5e2d60777c382e4790e91e8553a1 [file] [log] [blame]
Copybara854996b2021-09-07 19:36:02 +00001[# Even though this field definition says it is single-valued, the issue might have
2 multiple values if the field definition was previously multi-valued. In such a situation
3 values other than the first value are shown read-only and must be explicitly removed
4 before the comment can be submitted. ]
5
6[# If the field has no explicit values, then show an empty form element.]
7[if-any fields.values][else]
8 <input type="text" name="custom_[fields.field_id][is arg2 ""][else]_[arg2][end]" id="[arg0]_custom_[fields.field_id]" value=""
9 [is arg0 "hidden"][else]
10 [if-any arg1]required="required"[end]
11 [end]
12 style="width:12em" class="multivalued userautocomplete customfield" autocomplete="off"
13 data-ac-type="owner" aria-labelledby="[fields.field_id]_label">
14[end]
15
16
17[for fields.values]
18 [if-index fields.values first]
19 <input type="text" name="custom_[fields.field_id][is arg2 ""][else]_[arg2][end]" value="[fields.values.val]"
20 [is arg0 "hidden"][else]
21 [if-any arg1]required="required"[end]
22 [end]
23 style="width:12em" class="multivalued userautocomplete customfield" autocomplete="off"
24 data-ac-type="owner" aria-labelledby="[fields.field_id]_label">
25 [else]
26 <span>
27 <input type="text" disabled="disabled" value="[fields.values.val]"
28 style="width:12em" class="multivalued userautocomplete customfield" autocomplete="off"
29 data-ac-type="owner" aria-labelledby="[fields.field_id]_label">
30 <a href="#" class="removeMultiFieldValueWidget">X</a>
31 </span>
32 [end]
33[end]
34
35[for fields.derived_values]
36 <input type="text" disabled="disabled" value="[fields.derived_values.val]"
37 style="font-style:italic; width:12em" class="multivalued"
38 data-ac-type="owner" aria-labelledby="[fields.field_id]_label">
39[end]