[NEW] Addons creation - Account Quotation Sale Order Invoice Title
This commit is contained in:
committed by
Stéphan Sainléger
parent
e624c42a5d
commit
9f36a3c4b3
@@ -0,0 +1,4 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import account_move
|
||||
from . import sale
|
@@ -0,0 +1,9 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import models, fields
|
||||
|
||||
|
||||
class AccountMove(models.Model):
|
||||
_inherit = 'account.move'
|
||||
|
||||
move_title = fields.Char(string="Invoice Title")
|
14
account_quotation_sale_order_invoice_title/models/sale.py
Normal file
14
account_quotation_sale_order_invoice_title/models/sale.py
Normal file
@@ -0,0 +1,14 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import models, fields
|
||||
|
||||
|
||||
class SaleOrder(models.Model):
|
||||
_inherit = "sale.order"
|
||||
|
||||
so_title = fields.Char(string="Title")
|
||||
|
||||
def _prepare_invoice(self):
|
||||
res = super(SaleOrder, self)._prepare_invoice()
|
||||
res["move_title"] = self.so_title
|
||||
return res
|
Reference in New Issue
Block a user