跳至內容
選單
此問題已被標幟
1 回覆
6483 瀏覽次數

In a website view we used the attribute t-field to print the value of one field to format the value (so we won't use t-esc or something else). For example:

 <span t-field="o.somefloatvalue" />

If you click at the top on edit and change this value then the value is changed in the webpage/view and also in the record itself (which we don't want!!!).

Is it possible to disable the editing of such values in the frontend editor?

頭像
捨棄
最佳答案

Give attribute contentEditable = "False" to element. for example : <span contentEditable="False" t-field="o.somefloatvalue"/>, now your field cannot be edited.

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
3
7月 23
30501
1
11月 23
3124
1
4月 22
6937
0
7月 15
4162
1
11月 15
10137