# -*- coding: utf-8 -*- from odoo import models, fields, api from odoo.exceptions import UserError, ValidationError from psycopg2 import sql, DatabaseError from odoo.tools.safe_eval import safe_eval, datetime from werkzeug import utils class opendons_template_rf(models.Model): _name = 'opendons.template_rf' _description = 'manage rf html template' name=fields.Char('name') description=fields.Text('description') active=fields.Boolean('active') html_content=fields.Html('Html content') def action_update_receipts(self): rf=self.env['donation.tax.receipt'].search([('template_rf_id','=',int(self.id))]) for r in rf: r.html_content=self.html_content