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

I want to make invoice date field editable for admins

아바타
취소
베스트 답변

Hello Jain,

Hope you are doing well.

This field is read only in account_invoice file of account module. So, if you want to edit this field after validating invoice, then you have to inherit account.invoice model and override date_invoice field.

from odoo import models, fields, API

class Account Invoice(models.Model):
_inherit = "account.invoice"

date_invoice = fields.Date(string='Invoice Date', index=True,
help="Keep empty to use the current date", copy=False)

Thanks & Regards,

Email: odoo@aktivsoftware.com

Skype: kalpeshmaheshwari

아바타
취소
관련 게시물 답글 화면 활동
2
11월 22
6311
1
6월 22
8282
0
8월 21
95
0
7월 21
172
0
5월 21
1787