src/pyams_content/component/paragraph/zmi/container.py
changeset 469 66563c8433cf
parent 373 d541df80c5a7
child 501 3407e6940f6a
--- a/src/pyams_content/component/paragraph/zmi/container.py	Mon Mar 12 16:14:50 2018 +0100
+++ b/src/pyams_content/component/paragraph/zmi/container.py	Mon Mar 12 16:45:23 2018 +0100
@@ -95,15 +95,16 @@
     @property
     def data_attributes(self):
         attributes = super(ParagraphContainerBaseTable, self).data_attributes
-        attributes['table'] = {'id': self.id,
-                               'data-ams-plugins': 'pyams_content',
-                               'data-ams-plugin-pyams_content-src':
-                                   get_resource_path(pyams_content),
-                               'data-ams-location': absolute_url(IParagraphContainer(self.context), self.request),
-                               'data-ams-pre-reload': 'PyAMS_content.paragraphs.preReload',
-                               'data-ams-post-reload': 'PyAMS_content.paragraphs.postReload',
-                               'data-ams-tablednd-drag-handle': 'td.sorter',
-                               'data-ams-tablednd-drop-target': 'set-paragraphs-order.json'}
+        attributes.setdefault('table', {}).update({
+            'id': self.id,
+            'data-ams-plugins': 'pyams_content',
+            'data-ams-plugin-pyams_content-src': get_resource_path(pyams_content),
+            'data-ams-location': absolute_url(IParagraphContainer(self.context), self.request),
+            'data-ams-pre-reload': 'PyAMS_content.paragraphs.preReload',
+            'data-ams-post-reload': 'PyAMS_content.paragraphs.postReload',
+            'data-ams-tablednd-drag-handle': 'td.sorter',
+            'data-ams-tablednd-drop-target': 'set-paragraphs-order.json'
+        })
         return attributes