98 if 'description' in self.widgets: |
98 if 'description' in self.widgets: |
99 self.widgets['description'].widget_css_class = 'textarea' |
99 self.widgets['description'].widget_css_class = 'textarea' |
100 |
100 |
101 def get_ajax_output(self, changes): |
101 def get_ajax_output(self, changes): |
102 output = super(IllustrationPropertiesInnerEditForm, self).get_ajax_output(changes) |
102 output = super(IllustrationPropertiesInnerEditForm, self).get_ajax_output(changes) |
103 illustration_changes = changes.get(IIllustration, ()) |
103 updated = changes.get(IIllustration, ()) |
104 if ('data' in illustration_changes) or ('renderer' in illustration_changes): |
104 if ('data' in updated) or ('renderer' in updated): |
105 # we have to commit transaction to be able to handle blobs... |
105 if 'data' in updated: |
106 ITransactionManager(self.context).get().commit() |
106 # we have to commit transaction to be able to handle blobs... |
|
107 ITransactionManager(self.context).get().commit() |
107 form = IllustrationPropertiesInnerEditForm(self.context, self.request) |
108 form = IllustrationPropertiesInnerEditForm(self.context, self.request) |
108 form.update() |
109 form.update() |
109 illustration = form.getContent() |
110 illustration = form.getContent() |
110 output.setdefault('events', []).append({ |
111 output.setdefault('events', []).append({ |
111 'event': 'myams.refresh', |
112 'event': 'myams.refresh', |