# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import models, fields, api, exceptions, _ class PropertyOpenRent(models.Model): _name = 'property.open.rent' _description = '物业公开招租审批' _inherit = ['mail.thread.main.attachment', 'mail.activity.mixin', 'soong.workflow.mixin'] _rec_name = 'name' name = fields.Char(string='标题') code = fields.Char(string="编号", default=lambda self: self.env['ir.sequence'].next_by_code('property_open_rent_code')) property_documents_ids = fields.Many2many('documents.document', string="物业公开招租文件") rental_area = fields.Float(string="出租面积") upset = fields.Float(string="底价") # # # class PropertyOpenRentLine(models.Model): # _name = 'property.open.rent.line' # # property_open_rent_id = fields.Many2one('property.open.rent', string='关联审批') # product_id = fields.Many2one('product.product', string="物业") # property_note = fields.Text(string="物业描述")