添加功能

This commit is contained in:
李鹏宇
2025-11-01 16:22:16 +08:00
parent a54958651d
commit 9724397439
3 changed files with 13 additions and 20 deletions
@@ -35,11 +35,11 @@
<!-- <button name="get_hr_attendance_time" type="object" string="手动计算" display="always"/>-->
<!-- </header>-->
<field name="employee_id"/>
<field name="company_id" optional="hide"/>
<field name="department_id"/>
<field name="source"/>
<field name="attendance_iot_id"/>
<field name="checkin_time"/>
<field name="source"/>
<field name="attendance_iot_id"/>
<field name="department_id"/>
<field name="company_id"/>
<!-- <field name="sch_checkin_time"/>-->
</tree>
</field>
@@ -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):
@@ -367,8 +367,14 @@
<button name="action_copy_record1" type="object" string="拆分" class="btn-primary"/>
<button name="unlink" string="删除" type="object" icon="fa-trash" groups="base.group_system" confirm="确定要删除选中的记录吗?"/>
</header>
<field name="contact_state" widget="badge"
decoration-info="contact_state == 'to'"
decoration-success="contact_state == 'ing'"
decoration-danger="contact_state == 'terminate'"
decoration-warning="contact_state == 'complete'"
decoration-muted="contact_state == 'early_termination'"/>
<field name="contract_code" decoration-danger="is_equal"/>
<field name="property_name"/>
<field name="contract_code" decoration-danger="is_equal"/>
<field name="lessee_id"/>
<field name="tenure_type"/>
<field name="contract_sort" column_invisible="1"/>
@@ -397,12 +403,6 @@
<field name="deposit_status" column_invisible="1"/>
<!-- <field name="lessor_id" string="公司"/>-->
<field name="admin_id" string="负责人"/>
<field name="contact_state" widget="badge"
decoration-info="contact_state == 'to'"
decoration-success="contact_state == 'ing'"
decoration-danger="contact_state == 'terminate'"
decoration-warning="contact_state == 'complete'"
decoration-muted="contact_state == 'early_termination'"/>
<button name="contract_signature" type="object" class="btn-primary" string="合同签订" invisible="contract_date"/>
<button name="put_evaluation_plan" type="object" class="btn-primary" string="评估推送"
invisible="contact_state == 'ing'"/>
@@ -760,7 +760,7 @@
</page>
<page string="电表信息" invisible="not is_electricity">
<field name="electricity_fee_ids" string=" ">
<tree editable="bottom">archives
<tree editable="bottom">
<field name="contract_id" column_invisible="1"/>
<field name="property_meter_archives_id" options="{'no_open': True}"/>
<field name="rate"/>