send template bug fixed, security fixed

This commit is contained in:
mvivlad 2025-02-19 16:55:26 +03:00
parent ffcf283b6f
commit 86293a90f9
2 changed files with 3 additions and 3 deletions

View File

@ -47,7 +47,7 @@ class TelegramAPI(models.Model):
self.with_context(
lang=self.env.user.lang if self.env.user.lang else 'ru_RU',
tz=self.env.user.tz if self.env.user.tz else 'Europe/Moscow'
).render_template(template, data)
).render_template(template, obj, data)
))
def get_updates(self):

View File

@ -1,3 +1,3 @@
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_base_telegram_api,access_base_telegram_api,model_base_telegram_api,,1,1,1,1
access_wizard_create_notify_new_object,access_wizard_create_notify_new_object,model_wizard_create_notify_new_object,,1,1,1,1
access_base_telegram_api,access_base_telegram_api,model_base_telegram_api,"base.group_system",1,1,1,1
access_wizard_create_notify_new_object,access_wizard_create_notify_new_object,model_wizard_create_notify_new_object,"base.group_system",1,1,1,1

1 id name model_id:id group_id:id perm_read perm_write perm_create perm_unlink
2 access_base_telegram_api access_base_telegram_api model_base_telegram_api base.group_system 1 1 1 1
3 access_wizard_create_notify_new_object access_wizard_create_notify_new_object model_wizard_create_notify_new_object base.group_system 1 1 1 1