From 785de8aa86f4e4fd438b63a6931685ccc34da2c1 Mon Sep 17 00:00:00 2001 From: zhou <123@> Date: Mon, 14 Apr 2025 20:32:25 +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 --- ro_wechat_redirect/controllers/controllers.py | 2 +- yuthon_will_task/models/yuthon_will_task.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ro_wechat_redirect/controllers/controllers.py b/ro_wechat_redirect/controllers/controllers.py index 9c1af1b80..11151b5f6 100644 --- a/ro_wechat_redirect/controllers/controllers.py +++ b/ro_wechat_redirect/controllers/controllers.py @@ -11,7 +11,7 @@ class HomeExtend(Home): oauth_access_token = http.request.params.get('oauth_access_token') if oauth_access_token: oauth_uid = kw.get('oauth_uid') - login = request.env['res.users'].sudo().search([('oauth_uid','=',oauth_uid)]).login + login = request.env['res.users'].sudo().search([('oauth_uid','=',oauth_uid)])[0].login if login != False: uid = request.session.authenticate(request.session.db, login, oauth_access_token) request.params['login_success'] = True diff --git a/yuthon_will_task/models/yuthon_will_task.py b/yuthon_will_task/models/yuthon_will_task.py index ce7634daf..aa676e1a0 100644 --- a/yuthon_will_task/models/yuthon_will_task.py +++ b/yuthon_will_task/models/yuthon_will_task.py @@ -105,9 +105,9 @@ class YuthonWillTask(models.Model): self.sudo().env["wecom.apps"].sync_send_message_textcard(category='task', user_id=employee_id.wecom_userid, title="日程事项提醒", description=data, url=url, btntxt="详细信息") - for record in self: - partner_ids = record.employee_ids.user_id.partner_id.ids - record.with_context(lang=record.env.lang)._message_auto_subscribe_notify(partner_ids,'yuthon_will_task.mail_action_yuthon_will_task_add_comment') + # for record in self: + # partner_ids = record.employee_ids.user_id.partner_id.ids + # record.with_context(lang=record.env.lang)._message_auto_subscribe_notify(partner_ids,'yuthon_will_task.mail_action_yuthon_will_task_add_comment') def button_add_comment(self): self.add_comment()