mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
[MIG] base_comment_template: Migration to 17.0
This commit is contained in:
committed by
Maksym Yankin
parent
efb2bbf843
commit
cf39e00f9c
@@ -33,7 +33,7 @@ class BaseCommentTemplatePreview(models.TransientModel):
|
||||
)
|
||||
res = self.env[model.model].search(domain, limit=1)
|
||||
if res:
|
||||
result["resource_ref"] = "%s,%s" % (model.model, res.id)
|
||||
result["resource_ref"] = f"{model.model},{res.id}"
|
||||
return result
|
||||
|
||||
base_comment_template_id = fields.Many2one(
|
||||
|
||||
@@ -28,12 +28,9 @@
|
||||
name="resource_ref"
|
||||
class="oe_inline"
|
||||
options="{'hide_model': True, 'no_create': True, 'no_edit': True, 'no_open': True}"
|
||||
attrs="{'invisible': [('no_record', '=', True)]}"
|
||||
invisible="no_record"
|
||||
/>
|
||||
<span
|
||||
class="text-warning"
|
||||
attrs="{'invisible': [('no_record', '=', False)]}"
|
||||
>No records
|
||||
<span class="text-warning" invisible="not no_record">No records
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user