From 08b9224cefbd8324658fe67d25e64e129760e02f Mon Sep 17 00:00:00 2001 From: zhou <123@> Date: Mon, 17 Mar 2025 18:51:05 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yuthon_property/models/yuthon_property.py | 2 ++ .../models/yuthon_resource_mgmt_config.py | 16 ++++++++++ yuthon_property/security/ir.model.access.csv | 4 ++- yuthon_property/views/menuitem.xml | 4 +++ .../views/yuthon_property_views.xml | 12 +++++++ .../yuthon_resource_mgmt_config_views.xml | 31 +++++++++++++++++++ 6 files changed, 68 insertions(+), 1 deletion(-) diff --git a/yuthon_property/models/yuthon_property.py b/yuthon_property/models/yuthon_property.py index 364ccb931..77b40b9de 100644 --- a/yuthon_property/models/yuthon_property.py +++ b/yuthon_property/models/yuthon_property.py @@ -65,6 +65,8 @@ class YuthonProperty(models.Model): equity_area = fields.Float(string="产权面积", group_operator=None, digits=(16, 4)) decoration_type = fields.Selection([('blank', '毛坯'), ('hardcover', '精装'), ('brands', '简装'), ('rsz', '豪装')], string="装修类型") + feature_ids = fields.Many2many('feature.setting', string="特色") + major_ids = fields.One2many('major.event.setting', 'yuthon_property_id', string="重大事项明细行") water_meter_ids = fields.One2many('yuthon.property.water', 'yuthon_property_id', string='水表列表') energy_meter_ids = fields.One2many('yuthon.property.energy', 'yuthon_property_id', string='电表列表') title_information_ids = fields.One2many('title.information.line', 'yuthon_property_id', string='关联产权信息明细行') diff --git a/yuthon_property/models/yuthon_resource_mgmt_config.py b/yuthon_property/models/yuthon_resource_mgmt_config.py index 4c7754dcd..b422e4f4a 100644 --- a/yuthon_property/models/yuthon_resource_mgmt_config.py +++ b/yuthon_property/models/yuthon_resource_mgmt_config.py @@ -195,3 +195,19 @@ class RentFreeLine(models.Model): minimum_area = fields.Float(string="最小面积") maximum_area = fields.Float(string="最大面积") rent_fee_date = fields.Integer(string="免租期不超过") + +class FeatureSetting(models.Model): + _name = 'feature.setting' + _description = '特色配置' + + name = fields.Char(string="名称") + +class MajorEventSetting(models.Model): + _name = 'major.event.setting' + _description = '重大事项配置' + + yuthon_property_id = fields.Many2one('yuthon.property', string="关联物业") + name = fields.Char(string="名称") + inspector_html = fields.Html(string="内容") + documents_ids = fields.Many2many('ir.attachment', string="附件") + start_date = fields.Date(string="生效日期", default=fields.Date.today()) diff --git a/yuthon_property/security/ir.model.access.csv b/yuthon_property/security/ir.model.access.csv index 13f52c030..8d907349e 100644 --- a/yuthon_property/security/ir.model.access.csv +++ b/yuthon_property/security/ir.model.access.csv @@ -79,4 +79,6 @@ access_property_subject_form,property_subject_form,model_property_subject_form,b access_yuthon_premises_setting,yuthon_premises_setting,model_yuthon_premises_setting,base.group_user,1,1,1,1 access_rent_free_setting,rent_free_setting,model_rent_free_setting,base.group_user,1,1,1,1 access_yuthon_reference_conditions,yuthon_reference_conditions,model_yuthon_reference_conditions,base.group_user,1,1,1,1 -access_rent_free_line,rent_free_line,model_rent_free_line,base.group_user,1,1,1,1 \ No newline at end of file +access_rent_free_line,rent_free_line,model_rent_free_line,base.group_user,1,1,1,1 +access_feature_setting,feature_setting,model_feature_setting,base.group_user,1,1,1,1 +access_major_event_setting,major_event_setting,model_major_event_setting,base.group_user,1,1,1,1 \ No newline at end of file diff --git a/yuthon_property/views/menuitem.xml b/yuthon_property/views/menuitem.xml index c5c1ea804..c26553cb5 100644 --- a/yuthon_property/views/menuitem.xml +++ b/yuthon_property/views/menuitem.xml @@ -340,6 +340,10 @@ action="view_yuthon_property_produce_action" sequence="80"/> + + + @@ -200,6 +201,17 @@ + + + + + + + + + + + diff --git a/yuthon_property/views/yuthon_resource_mgmt_config_views.xml b/yuthon_property/views/yuthon_resource_mgmt_config_views.xml index b92e12fc0..2eedd0c44 100644 --- a/yuthon_property/views/yuthon_resource_mgmt_config_views.xml +++ b/yuthon_property/views/yuthon_resource_mgmt_config_views.xml @@ -337,4 +337,35 @@ rent.free.setting tree,form + + feature.setting.tree + feature.setting + + + + + + + + 特色配置 + feature.setting + tree + + + major.event.setting.tree + major.event.setting + + + + + + + + + + + 重大事项配置 + major.event.setting + tree +