添加功能

This commit is contained in:
李鹏宇
2025-11-17 11:08:07 +08:00
parent fcc3a2a620
commit 5e4624728c
+8 -9
View File
@@ -160,15 +160,14 @@ class WeComApps(models.Model):
},
}
result_data = self.sync_function_api("message_send", "MESSAGE_SEND", data, category)
if category == 'att':
employee_id = self.env["res.users"].search([("id", "=", user_id)], limit=1).employee_ids
self.env["attendance.message.log"].create({
"employee_id": employee_id.id,
"content": description,
"notice_type": 'attendance',
'update_date': fields.Datetime.now(),
"message_url": url,
})
employee_id = self.env["res.users"].search([("id", "=", user_id)], limit=1).employee_ids
self.env["attendance.message.log"].create({
"employee_id": employee_id.id,
"content": description,
"notice_type": 'attendance',
'update_date': fields.Datetime.now(),
"message_url": url,
})
if result_data.get("errcode", None) == 0:
return True, result_data
return False, result_data