merge stable
authorAurelien Campeas <aurelien.campeas@logilab.fr>
Wed, 27 May 2009 17:08:30 +0200
branchstable
changeset 1972 2d015f8fafae
parent 1971 5e6799e86088 (current diff)
parent 1969 f14f8465269d (diff)
child 1973 f60bb84b86cf
merge
--- a/web/formrenderers.py	Wed May 27 15:54:29 2009 +0200
+++ b/web/formrenderers.py	Wed May 27 17:08:30 2009 +0200
@@ -390,6 +390,8 @@
 
     def inline_entities_form(self, w, form):
         """create a form to edit entity's inlined relations"""
+        if not hasattr(form, 'inlined_relations'):
+            return
         entity = form.edited_entity
         __ = form.req.__
         for rschema, targettypes, role in form.inlined_relations():
--- a/web/views/autoform.py	Wed May 27 15:54:29 2009 +0200
+++ b/web/views/autoform.py	Wed May 27 17:08:30 2009 +0200
@@ -189,7 +189,8 @@
         """
         # we'll need an initialized varmaker if there are some inlined relation
         self.initialize_varmaker()
-        return self.erelations_by_category(self.edited_entity, True, 'add', self.rinlined)
+        return self.erelations_by_category(self.edited_entity, True, 'add',
+                                           self.rinlined)
 
     def srelations_by_category(self, categories=None, permission=None):
         """filter out result of relations_by_category(categories, permission) by
--- a/web/views/basecomponents.py	Wed May 27 15:54:29 2009 +0200
+++ b/web/views/basecomponents.py	Wed May 27 17:08:30 2009 +0200
@@ -20,7 +20,7 @@
                                       BoxLink)
 
 VISIBLE_PROP_DEF = {
-    _('visible'):  dict(type='Boolean', default=False,
+    _('visible'):  dict(type='Boolean', default=True,
                         help=_('display the component or not')),
     }
 
@@ -125,9 +125,8 @@
     """
     __select__ = yes()
     id = 'applmessages'
-    property_defs = VISIBLE_PROP_DEF
     # don't want user to hide this component using an cwproperty
-    site_wide = True
+    property_defs = {}
 
     def call(self):
         msgs = [msg for msg in (self.req.get_shared_data('sources_error', pop=True),