Skip to Content
Menú
This question has been flagged
1 Respondre
3133 Vistes

I want to make invoice date field editable for admins

Avatar
Descartar
Best Answer

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

Avatar
Descartar
Related Posts Respostes Vistes Activitat
2
de nov. 22
6192
1
de juny 22
8208
0
d’ag. 21
95
0
de jul. 21
172
0
de maig 21
1697