mirror of
https://github.com/OCA/knowledge.git
synced 2025-12-19 03:42:19 -06:00
[MIG] document_page_approval: Finish migration
Changes done: - Squash administrative commits - Purge translations - Remove ir.model.access.csv file - Improve tests (change to setUpClass) - Replace name_get() to _compute_display_name() (document_page) - Remove readonly=1 (redudant, it already is) defined in approved_uid and approved_date fields in views - Restore readonly=1 to the state field - Remove duplicate Back to draft button TT51529
This commit is contained in:
committed by
Bhavesh Heliconia
parent
a4972a014d
commit
f606356ca0
@@ -2,9 +2,8 @@
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
|
||||
from ast import literal_eval
|
||||
|
||||
from odoo import api, fields, models
|
||||
from odoo.tools.safe_eval import safe_eval
|
||||
|
||||
|
||||
class DocumentPage(models.Model):
|
||||
@@ -138,7 +137,7 @@ class DocumentPage(models.Model):
|
||||
action = self.env["ir.actions.act_window"]._for_xml_id(
|
||||
"document_page_approval.action_change_requests"
|
||||
)
|
||||
context = literal_eval(action["context"])
|
||||
context = safe_eval(action["context"])
|
||||
context["search_default_page_id"] = self.id
|
||||
context["default_page_id"] = self.id
|
||||
action["context"] = context
|
||||
|
||||
Reference in New Issue
Block a user