diff options
| author | Mqdd <ahmadmiqdad27@gmail.com> | 2026-01-19 09:45:14 +0700 |
|---|---|---|
| committer | Mqdd <ahmadmiqdad27@gmail.com> | 2026-01-19 09:45:14 +0700 |
| commit | 8de3619bc698551e7d23b463d4bcf55f9ad8b62c (patch) | |
| tree | aecd438028f89ac65cf491e7b1cfeac669d9b494 | |
| parent | 1fe987dc8901f039e9a272214f26b15bfc7fa01a (diff) | |
<Miqdad> send private message
| -rw-r--r-- | indoteknik_custom/models/gudang_service.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/indoteknik_custom/models/gudang_service.py b/indoteknik_custom/models/gudang_service.py index 2a8b589d..5aeabb39 100644 --- a/indoteknik_custom/models/gudang_service.py +++ b/indoteknik_custom/models/gudang_service.py @@ -62,6 +62,11 @@ class GudangService(models.Model): ) % (rec.name, rec.date), 'date_deadline': fields.Date.today(), }) + channel = self.env['mail.channel'].channel_get([self.env.user.partner_id.id, user.partner_id.id]).get('id') + if not channel: + continue + res = self.env['mail.channel'].browse(channel) + res.message_post(body=_('Gudang Service <b>%s</b> masih <b>On Progress</b> sejak %s') % (rec.name, rec.date), message_type='comment', subtype_xmlid='mail.mt_comment') @api.model def cron_notify_onprogress_gudang_service(self): |
