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

Hi everyone,

I have a field elist_price in my cham module, I have inherit the crm.lead view and i want to readonly field upon state field. when we set attr like this:

<field name="elist_price" attrs="{'readonly':[('state','not in','['draft']') ] }"/>

so error in terminal

Cannot eval "{'readonly':[('state','not in','['draft']') ] }".

And state field is in 'crm.lead',

elist_price is in 'my_object1'

How we set read only this thing.please give a proper solution. thank's

아바타
취소
베스트 답변

Hi,

systax error ['draft'] and not '['draft']':

<field name="elist_price" attrs="{'readonly':[('state','not in',['draft']) ] }"/>

and not

<field name="elist_price" attrs="{'readonly':[('state','not in','['draft']') ] }"/>
아바타
취소
베스트 답변

Hi,

you should write like this

<field name="elist_price" attrs="{'readonly':[('state','not in','draft') ] }"/>
아바타
취소
관련 게시물 답글 화면 활동
2
11월 20
18067
1
9월 19
4176
1
1월 16
14924
0
3월 15
3327
2
5월 24
9326