콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
3371 화면

Well, I have issue with the readonly option on a field which I creat like above

<field nam="nam_of_field" readonly="True"/> I fill this field from on_change() of an other one. But when I save my form, the value of my field(the readonly field) is lost. The field is empty. And an empty value is save. What can I do?

아바타
취소

can you please post your code along with your question and elaborate in clear?

Well, yeah, it's readonly. onchange functions don't store the change in the database, just in the user interface - which disallows changes.

Use fields.related instead of these it think it may be better than using onchange.