mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
fix misc for ai
This commit is contained in:
@@ -7,7 +7,10 @@ from odoo.tools.safe_eval import safe_eval
|
||||
|
||||
class BlogPost(models.Model):
|
||||
_inherit = 'blog.post'
|
||||
|
||||
|
||||
# 不允许暴力删除
|
||||
blog_id = fields.Many2one('blog.blog', ondelete='restrict')
|
||||
|
||||
def write(self, vals):
|
||||
if vals.get('website_meta_og_img'):
|
||||
sync_blog_meta_background_img = self.env['ir.config_parameter'].sudo().get_param('app_website_blog_editor.sync_blog_meta_background_img')
|
||||
|
||||
Reference in New Issue
Block a user