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

I have a selection field as follows:


source = fields.Selection([
('one', 'First'),
('two', 'Second'),
('three', 'Third'),
('four', 'Fourth'),
('five', 'Fifth'),
], required=True, default='one')


How can I show but inactive some of these options?


at the moment these options are all visible and selectable but I want some to be visible but inactive so not being selectable.

아바타
취소
베스트 답변

Hello 

you can not inactive but based on your condition you can add and remove using fields_view_get method

아바타
취소
관련 게시물 답글 화면 활동
2
8월 17
7303
1
9월 23
4193
1
9월 23
3020
2
6월 18
5153
2
6월 23
5208