From b7e1f4b83df7bc1936439509632a2d2eee9f6efb Mon Sep 17 00:00:00 2001
From: zhou <123@>
Date: Mon, 30 Dec 2024 21:36:46 +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 | 39 +++++++----------
yuthon_property/security/ir.model.access.csv | 1 -
.../views/yuthon_property_views.xml | 12 +-----
.../models/property_lease_contract.py | 42 +++++++++++++++++--
.../views/property_lease_contract.xml | 6 +--
5 files changed, 57 insertions(+), 43 deletions(-)
diff --git a/yuthon_property/models/yuthon_property.py b/yuthon_property/models/yuthon_property.py
index 27444c4d1..24b97a279 100644
--- a/yuthon_property/models/yuthon_property.py
+++ b/yuthon_property/models/yuthon_property.py
@@ -82,7 +82,6 @@ class YuthonProperty(models.Model):
disassembly_information_ids = fields.One2many('disassembly.information.line', 'yuthon_property_id',
string='关联拆分信息明细行')
property_merge_approval_id = fields.Many2one('yuthon.property', string='关联物业信息')
- manage_fee_line_ids = fields.One2many('manage.information.fee.line', 'yuthon_property_id', string='关联管理费明细行')
@api.onchange('manage_information_ids')
def _onchange_information_ids(self):
@@ -268,41 +267,37 @@ class YuthonProperty(models.Model):
class YuthonPropertyWater(models.Model):
_name = 'yuthon.property.water'
_description = '水表'
- _rec_name = 'code'
- property_meter_water_id = fields.Many2one('property.meter.water', string="关联水表库")
- code = fields.Char(string='编码')
+ property_meter_water_id = fields.Many2one('property.meter.water', string="水表库")
rate = fields.Integer(string="倍率")
standard = fields.Integer(string="标准")
- installation_date = fields.Datetime(string="安装日期")
- demolition_date = fields.Datetime(string="拆除日期")
+ installation_date = fields.Date(string="安装日期")
+ demolition_date = fields.Date(string="拆除日期")
location = fields.Char(string="位置")
yuthon_property_id = fields.Many2one('yuthon.property', string="物业管理")
- @api.onchange('property_meter_water_id')
- def _onchange_water_meter_ids(self):
- for rec in self:
- rec.property_meter_water_id.write({'yuthon_property_id': rec.property_meter_water_id.id})
+ # @api.onchange('property_meter_water_id')
+ # def _onchange_water_meter_ids(self):
+ # for rec in self:
+ # rec.property_meter_water_id.write({'yuthon_property_id': rec.property_meter_water_id.id})
class YuthonPropertyEnergy(models.Model):
_name = 'yuthon.property.energy'
_description = '电表'
- _rec_name = 'code'
- property_meter_archives_id = fields.Many2one('property.meter.archives', string="关联电表库")
- code = fields.Char(string='编码')
+ property_meter_archives_id = fields.Many2one('property.meter.archives', string="电表库")
rate = fields.Integer(string="倍率")
standard = fields.Integer(string="标准")
- installation_date = fields.Datetime(string="安装日期")
- demolition_date = fields.Datetime(string="拆除日期")
+ installation_date = fields.Date(string="安装日期")
+ demolition_date = fields.Date(string="拆除日期")
location = fields.Char(string="位置")
yuthon_property_id = fields.Many2one('yuthon.property', string="物业管理")
- @api.onchange('property_meter_archives_id')
- def _onchange_water_meter_ids(self):
- for rec in self:
- rec.property_meter_archives_id.write({'yuthon_property_id': rec.property_meter_archives_id.id})
+ # @api.onchange('property_meter_archives_id')
+ # def _onchange_water_meter_ids(self):
+ # for rec in self:
+ # rec.property_meter_archives_id.write({'yuthon_property_id': rec.property_meter_archives_id.id})
class TitleInformationLine(models.Model):
@@ -344,10 +339,4 @@ class DisassemblyInformationLine(models.Model):
start_time = fields.Date(related='property_id.start_time',string="生效日期")
end_date = fields.Date(related='property_id.end_date',string="失效日期")
-class ManageInformationFeeLine(models.Model):
- _name = 'manage.information.fee.line'
- _description = '管理费用明细行'
-
- yuthon_property_id = fields.Many2one('yuthon.property', string="关联物业信息")
- manage_id = fields.Many2one('property.message.fee', string="管理费标准")
diff --git a/yuthon_property/security/ir.model.access.csv b/yuthon_property/security/ir.model.access.csv
index 4b59e43d5..d3d421be9 100644
--- a/yuthon_property/security/ir.model.access.csv
+++ b/yuthon_property/security/ir.model.access.csv
@@ -51,7 +51,6 @@ access_yuthon_property_lessee, yuthon_property_lessee,model_yuthon_property_less
access_yuthon_property_lessee,yuthon_property_lessee,model_yuthon_property_lessee,base.group_user,1,1,1,1
access_yuthon_electricity_setting,yuthon_electricity_setting,model_yuthon_electricity_setting,base.group_user,1,1,1,1
access_yuthon_water_setting,yuthon_water_setting,model_yuthon_water_setting,base.group_user,1,1,1,1
-access_manage_information_fee_line,manage.information.fee.line,model_manage_information_fee_line,base.group_user,1,1,1,1
access_yuthon_lot_setting,yuthon_lot_setting,model_yuthon_lot_setting,base.group_user,1,1,1,1
access_yuthon_property_wizard,yuthon_property_wizard,model_yuthon_property_wizard,base.group_user,1,1,1,1
access_yuthon_property_company,yuthon_property_company,model_yuthon_property_company,base.group_user,1,1,1,1
\ No newline at end of file
diff --git a/yuthon_property/views/yuthon_property_views.xml b/yuthon_property/views/yuthon_property_views.xml
index 90d7a604b..96f1cf4c3 100644
--- a/yuthon_property/views/yuthon_property_views.xml
+++ b/yuthon_property/views/yuthon_property_views.xml
@@ -171,8 +171,7 @@