[primary view] don't need to pick arbitrary target, this is properly handled by the rtag stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Tue, 14 Sep 2010 15:35:42 +0200
branchstable
changeset 6234 ae97a8c818e5
parent 6233 612b7d947a4c
child 6235 d5f7bd102282
[primary view] don't need to pick arbitrary target, this is properly handled by the rtag
web/views/primary.py
--- a/web/views/primary.py	Tue Sep 14 15:33:28 2010 +0200
+++ b/web/views/primary.py	Tue Sep 14 15:35:42 2010 +0200
@@ -234,10 +234,7 @@
                 if section == where:
                     matchtschemas.append(tschema)
             if matchtschemas:
-                # XXX pick the latest dispctrl
-                dispctrl = self.display_ctrl.etype_get(eschema, rschema, role,
-                                                       matchtschemas[-1])
-
+                dispctrl = self.display_ctrl.etype_get(eschema, rschema, role, '*')
                 rdefs.append( (rschema, matchtschemas, role, dispctrl) )
         return sorted(rdefs, key=lambda x: x[-1]['order'])