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

I am trying to upgrade a custom module from odoo 13 to 14 , while installing it , this error is showing up : 
AssertionError: account.payment.payment_difference_handling: selection_add=[('reconcile_multi_deduct', 'Mark invoice as fully paid (multi deduct)')] on non-list selection None

아바타
취소
베스트 답변

Hi,

In Odoo 13, the field payment_difference_handling is defined within the account.payment model, but while coming to Odoo 14, it is defined in the account.payment.register model.
So you have to change the model in which you are inheriting the field and adding new values into the selection list.


class AccountPaymentRegister(models.TransientModel):
_inherit = 'account.payment.register'
payment_difference_handling = usage = fields.Selection(selection_add=[('reconcile_multi_deduct', 'Mark invoice as fully paid (multi deduct)')],ondelete={'reconcile_multi_deduct': 'cascade'})

Hope it helps

아바타
취소
관련 게시물 답글 화면 활동
3
9월 25
3278
0
8월 25
813
1
8월 25
3042
2
7월 25
8683
2
7월 25
5047