[15.0][ADD] subscription_oca

This commit is contained in:
Carlos
2023-09-20 21:49:04 +02:00
committed by Ilyas
parent 69117ccbf2
commit 1ba6fe33a2
34 changed files with 2636 additions and 0 deletions

View File

@@ -0,0 +1,17 @@
# Copyright 2023 Domatix - Carlos Martínez
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import models
class SaleOrderLine(models.Model):
_inherit = "sale.order.line"
def get_subscription_line_values(self):
return {
"product_id": self.product_id.id,
"name": self.product_id.name,
"product_uom_qty": self.product_uom_qty,
"price_unit": self.price_unit,
"discount": self.discount,
"price_subtotal": self.price_subtotal,
}