[FIX] web: ignored readonly attribute on image widget

This commit is contained in:
Sébastien BEAU
2014-08-19 15:27:36 +02:00
committed by Martin Trigaux
parent 6164f52ca3
commit 3b901f0aa0
+11 -9
View File
@@ -1202,16 +1202,18 @@
</t>
<t t-name="FieldBinaryImage">
<span class="oe_form_field oe_form_field_image" t-att-style="widget.node.attrs.style">
<div class="oe_form_field_image_controls oe_edit_only">
<t t-call="HiddenInputFile">
<t t-set="fileupload_id" t-value="widget.fileupload_id"/>
Edit
</t>
<div class="oe_form_binary_progress" style="display: none">
<img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16"/>
<b>Uploading ...</b>
<t t-if="!widget.get('effective_readonly')">
<div class="oe_form_field_image_controls oe_edit_only">
<t t-call="HiddenInputFile">
<t t-set="fileupload_id" t-value="widget.fileupload_id"/>
Edit
</t>
<div class="oe_form_binary_progress" style="display: none">
<img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16"/>
<b>Uploading ...</b>
</div>
</div>
</div>
</t>
</span>
</t>
<t t-name="FieldBinaryImage-img">