18 lines
663 B
Python
18 lines
663 B
Python
# -*- coding: utf-8 -*-
|
|
from odoo import api, fields, models, tools
|
|
from odoo.exceptions import ValidationError
|
|
|
|
|
|
class SaleOrder(models.Model):
|
|
_inherit = "sale.order"
|
|
_description = "租赁合同拓展"
|
|
|
|
contract_code = fields.Char(string="合同编号", default=lambda self: self.env['ir.sequence'].next_by_code('sale_order_code'))
|
|
res_partner_ids = fields.One2many('res.partner', 'sale_order_id', string='承租方明细')
|
|
contract_documents_ids = fields.Many2many('documents.document', string="附件")
|
|
contract_confirm_date = fields.Datetime(string="合同签定日期")
|
|
handover_date = fields.Datetime(string="交接日期")
|
|
|
|
|
|
|