This commit is contained in:
李鹏宇
2026-04-10 11:19:24 +08:00
5 changed files with 14 additions and 10 deletions
@@ -6,7 +6,7 @@
<field name="arch" type="xml">
<tree editable="bottom">
<header>
<button name="action_init_device" string="初始化设备" type="object"/>
<button name="action_init_device" string="同步员工" type="object"/>
</header>
<field name="name"/>
<field name="attendance_address"/>
+3 -3
View File
@@ -149,7 +149,7 @@ class SoongWorkflowNode(models.Model):
"sequence": sequence + 1,
"action_type": "end",
"btn_hide": False,
"has_comment": False,
"has_comment": True,
"review_type": "end",
})
add_archive = (0, 0, {
@@ -158,7 +158,7 @@ class SoongWorkflowNode(models.Model):
"sequence": sequence + 2,
"action_type": "code",
"btn_hide": False,
"has_comment": False,
"has_comment": True,
})
record.button_ids = remove_commands + [add_end, add_archive]
@@ -184,7 +184,7 @@ class SoongWorkflowNode(models.Model):
"sequence": sequence + 1,
"action_type": "confirm",
"btn_hide": False, # 对所有人显示
"has_comment": False, # 对所有人显示
"has_comment": True, # 对所有人显示
"review_type": "confirm",
}),
]
+6 -6
View File
@@ -371,12 +371,12 @@ class HrAttendance(models.Model):
description='考勤异常请尽快处理',
exception_alerts = True,
url=url, btntxt="查看详情")
self.sudo().env["wecom.apps"].sync_send_message_textcard(category='att',
user_id='18562027762',
title='【考勤异常提醒】',
exception_alerts=True,
description='考勤异常请尽快处理',
url=url, btntxt="查看详情")
self.sudo().env["wecom.apps"].sync_send_message_textcard(category='att',
user_id='18562027762',
title='【考勤异常提醒】',
exception_alerts=True,
description='考勤异常请尽快处理',
url=url, btntxt="查看详情")
def missing_card_judgment(self):
today = fields.Date.today()
@@ -207,6 +207,9 @@ class YuthonOnboardApproval(models.Model):
})
# employee_id.send_wecom_employee()
employee_id.create_user()
iots = self.env['attendance.iot'].sudo().search([('company_id', '=', self.company_id.id)])
for iot in iots:
iot.action_init_device()
if self.job_id.name not in ['董事长', '总经理', '副总经理']:
applet_security = self.env['applet.security'].sudo().search([
('employee_id', '=', employee_id.id)
@@ -689,6 +689,7 @@
<xpath expr="//field[@name='bank_state']" position="after">
<button name="button_reconciliation" type="object" string="对账" class="btn btn-primary" invisible="bank_state == 'reconciled'"/>
<button name="binding_information" type="object" string="绑定信息" class="btn btn-primary" invisible="name_account == '广州产权交易所有限公司'"/>
<button name="write_off_details" type="object" class="btn btn-primary" string="核销详情" invisible="bank_state == 'not_reconciled'"/>
</xpath>
</field>
</record>