Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
3107 มุมมอง

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

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
พ.ย. 22
6178
1
มิ.ย. 22
8194
0
ส.ค. 21
95
0
ก.ค. 21
172
0
พ.ค. 21
1690