Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
3029 Widoki

I want to make invoice date field editable for admins

Awatar
Odrzuć
Najlepsza odpowiedź

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

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
2
lis 22
6078
1
cze 22
8112
0
sie 21
95
0
lip 21
172
0
maj 21
1640