Hide FormatId from format tab of data object in simplified profiles
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Fri, 26 Aug 2016 11:11:18 +0200
changeset 1564 eea6033bc0cf
parent 1563 575a462dd815
child 1565 9e26a3fac4e9
Hide FormatId from format tab of data object in simplified profiles
views/dataobject.py
--- a/views/dataobject.py	Fri Aug 26 10:54:10 2016 +0200
+++ b/views/dataobject.py	Fri Aug 26 11:11:18 2016 +0200
@@ -187,6 +187,14 @@
     rsection, display_ctrl = rtags_from_xsd_element('SEDABinaryDataObject', 'FormatIdentification')
 
 
+class SimplifiedBinaryDataObjectFormatIdentificationTab(BinaryDataObjectFormatIdentificationTab):
+
+    __select__ = BinaryDataObjectFormatIdentificationTab.__select__ & simplified_profile()
+
+    rsection, display_ctrl = rtags_from_xsd_element('SEDABinaryDataObject', 'FormatIdentification')
+    rsection.tag_object_of(('*', 'seda_format_id_from', 'SEDABinaryDataObject'), 'hidden')
+
+
 class BinaryDataObjectFileInfoTab(tabs.PrimaryTab):
     """Display file information of a binary data object"""