Zum Inhalt springen
Menü
Sie müssen registriert sein, um mit der Community zu interagieren.
Diese Frage wurde gekennzeichnet
1 Antworten
3176 Ansichten

Is there a way of making the invoice date the same as the sales order date?


I've found this question previously asked for Odoo v8 - https://www.odoo.com/forum/help-1/invoice-date-same-as-sales-order-date-110292, however I can't figure out how todo this in Odoo 14 on odoo.sh.


Avatar
Verwerfen
Beste Antwort

Hi,

Since you are using odoo 14 in sh, it support the custom modules.So you can add the following code in your existing custom module if any or you can create new custom module for this and you can deploy on odoo.sh.

class SaleOrder(models.Model):
_inherit = 'sale.order'

def _prepare_invoice(self):
res = super(SaleOrder, self)._prepare_invoice()
res['invoice_date'] = self.date_order
return res

Hope it helps

Avatar
Verwerfen
Verknüpfte Beiträge Antworten Ansichten Aktivität
0
Juli 21
3058
1
Aug. 24
3446
1
Apr. 24
2171
3
Okt. 23
8464
1
März 23
3117