diff options
| author | it-fixcomart <it@fixcomart.co.id> | 2025-01-24 09:15:14 +0700 |
|---|---|---|
| committer | it-fixcomart <it@fixcomart.co.id> | 2025-01-24 09:15:14 +0700 |
| commit | 64ef15502562e392ddeb011ced08239f9c6934f3 (patch) | |
| tree | 1dc3df0813d8933248c61379aaaa532190fc2dda | |
| parent | 9ab92b40a25ad0f677855780a903abc731b6f841 (diff) | |
<iman> update code
| -rw-r--r-- | indoteknik_custom/models/ir_actions_report.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/indoteknik_custom/models/ir_actions_report.py b/indoteknik_custom/models/ir_actions_report.py index 28adcf74..5b49a3ae 100644 --- a/indoteknik_custom/models/ir_actions_report.py +++ b/indoteknik_custom/models/ir_actions_report.py @@ -17,13 +17,13 @@ class IrActionsReport(models.Model): return # ci_vita 7751529082:AAE9XsZa_Pj2Pi2IN1grX98WkwTaIt32pbI & 5081411103 # iman 7094158106:AAHpWtYOMnA3Yqm_Fvrr3Vw7MrB45vLV9AY & 6592318498 - # bot_name_iman = '7094158106:AAHpWtYOMnA3Yqm_Fvrr3Vw7MrB45vLV9AY' - # chat_id_iman = '6592318498' + bot_name_iman = '7094158106:AAHpWtYOMnA3Yqm_Fvrr3Vw7MrB45vLV9AY' + chat_id_iman = '6592318498' bot_name_vita = '7751529082:AAE9XsZa_Pj2Pi2IN1grX98WkwTaIt32pbI' chat_id_vita = '5081411103' - apiURL = f'https://api.telegram.org/bot{bot_name_vita}/sendMessage' + apiURL = f'https://api.telegram.org/bot{bot_name_iman}/sendMessage' try: - requests.post(apiURL, json={'chat_id': chat_id_vita, 'text': sale_order.name + " senilai Rp" + self.format_currency(sale_order.amount_total) + ' untuk customer ' + sale_order.partner_id.name + ' telah dibuat oleh sales ' +sale_order.user_id.name}) + requests.post(apiURL, json={'chat_id': chat_id_iman, 'text': sale_order.name + " senilai Rp" + self.format_currency(sale_order.amount_total) + ' untuk customer ' + sale_order.partner_id.name + ' telah dibuat oleh sales ' +sale_order.user_id.name}) except Exception as e: print(e) |
