fix: let checkbox widget show static text instead of Yes/No
probably needs further improvement..but this is progress
This commit is contained in:
parent
70950ae9b8
commit
58bf8b4bbb
1 changed files with 4 additions and 2 deletions
|
|
@ -1,11 +1,13 @@
|
|||
<div tal:omit-tag=""
|
||||
tal:define="name name|field.name;
|
||||
oid oid|field.oid;
|
||||
vmodel vmodel|'modelData.'+oid;">
|
||||
vmodel vmodel|'modelData.'+oid;
|
||||
static_text static_text|None;">
|
||||
<b-checkbox name="${name}"
|
||||
v-model="${vmodel}"
|
||||
native-value="true"
|
||||
tal:attributes="attributes|field.widget.attributes|{};">
|
||||
{{ ${vmodel} ? "Yes" : "No" }}
|
||||
<span tal:omit-tag="" tal:condition="static_text">${static_text}</span>
|
||||
<span tal:omit-tag="" tal:condition="not static_text">{{ ${vmodel} ? "Yes" : "No" }}</span>
|
||||
</b-checkbox>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue