diff --git a/mis_builder/models/mis_report_style.py b/mis_builder/models/mis_report_style.py index 7b124922..9c0541c8 100644 --- a/mis_builder/models/mis_report_style.py +++ b/mis_builder/models/mis_report_style.py @@ -15,7 +15,7 @@ class PropertyDict(dict): def __getattr__(self, name): return self.get(name) - def copy(self): # pylint: disable=copy-wo-api-one + def copy(self): # pylint: disable=copy-wo-api-one,method-required-super return PropertyDict(self) diff --git a/mis_builder/static/src/js/mis_builder.js b/mis_builder/static/src/js/mis_builder.js index 22277261..977786cf 100644 --- a/mis_builder/static/src/js/mis_builder.js +++ b/mis_builder/static/src/js/mis_builder.js @@ -34,7 +34,7 @@ var MisReport = form_common.FormWidget.extend({ var self = this; self.mis_report_instance_id = self.getParent().datarecord.id; if (self.mis_report_instance_id) { - self.getParent().dataset.context['no_destroy'] = true; + self.getParent().dataset.context.no_destroy = true; } }, @@ -42,9 +42,9 @@ var MisReport = form_common.FormWidget.extend({ var self = this; var context = {}; if (this.mis_report_instance_id){ - context['active_ids'] = [this.mis_report_instance_id]; + context.active_ids = [this.mis_report_instance_id]; } - return context + return context; }, print: function() { @@ -135,7 +135,7 @@ ActionManager.include({ var self = this; if (self.dialog_widget && self.dialog_widget.dataset && self.dialog_widget.dataset.context) { var context = self.dialog_widget.dataset.context; - if (!context['no_destroy']) { + if (!context.no_destroy) { this._super.apply(this, arguments); } } else {