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

Under accounting -> Vendors -> Bills:


How do I ensure that for a given vendor bill, if someone creates a new Bill in the system with the same reference ('ref') string it should raise an exception. Vendor bills should have unique reference. 

https://imgur.com/EWrnS0S

After Inheriting the account.move, how can I get the context with constrains method where if a user tries to create a new bill with a reference which already exists in the system, it should raise an exception and not make a duplicate?


Thank you for your time. 

아바타
취소
베스트 답변

This is already checked in Odoo. 

See https://github.com/odoo/odoo/blob/13.0/addons/account/models/account_move.py#L1458

아바타
취소
관련 게시물 답글 화면 활동
2
12월 23
1466
1
9월 23
2164
0
9월 22
2899
1
8월 25
133
2
8월 25
90