diff --git a/yuthon_hr_attendance/views/hr_attendance_detail_wechat_views.xml b/yuthon_hr_attendance/views/hr_attendance_detail_wechat_views.xml index 8c0e0a9f7..41d471f30 100644 --- a/yuthon_hr_attendance/views/hr_attendance_detail_wechat_views.xml +++ b/yuthon_hr_attendance/views/hr_attendance_detail_wechat_views.xml @@ -35,11 +35,11 @@ - - - - + + + + diff --git a/yuthon_property_approval/models/inherit_yuthon_property.py b/yuthon_property_approval/models/inherit_yuthon_property.py index cf41c31f5..c2582055c 100644 --- a/yuthon_property_approval/models/inherit_yuthon_property.py +++ b/yuthon_property_approval/models/inherit_yuthon_property.py @@ -68,14 +68,7 @@ class MeterArchivesLine(models.Model): archives_ids = self.env["meter.archives.line"].browse( self._context.get('active_ids', self._context.get('active_id'))) for record in archives_ids: - if record.yuthon_property_ids: - contract_line = self.env['property.lease.contract.line'].search([ - ('address_id', '=', record.yuthon_property_ids[0].id), - ('lease_id.actual_start_time', '<=', record.meter_date), - ('lease_id.actual_end_time', '>=', record.meter_date) - ], limit=1) - if contract_line: - record.contract_id = contract_line.lease_id.id + record.lessee_id = record.contract_id.lessee_id.id class MeterWaterLine(models.Model): diff --git a/yuthon_property_approval/views/property_lease_contract.xml b/yuthon_property_approval/views/property_lease_contract.xml index 3154ff301..26f598a0c 100644 --- a/yuthon_property_approval/views/property_lease_contract.xml +++ b/yuthon_property_approval/views/property_lease_contract.xml @@ -367,8 +367,14 @@