ソースを参照

remove useless returned objects + add required ones (current user + list of allowed nodes)

Damien Accorsi 11 年 前
コミット
f4f9c56226
共有1 個のファイルを変更した2 個の追加5 個の削除を含む
  1. 2 5
      pboard/pboard/controllers/root.py

+ 2 - 5
pboard/pboard/controllers/root.py ファイルの表示

141
         except Exception as e:
141
         except Exception as e:
142
           flash(_('Document not found'), 'error')
142
           flash(_('Document not found'), 'error')
143
 
143
 
144
-        # FIXME - D.A - 2013-11-07 - Currently, the code build a new item if no item found for current user
145
-        # the correct behavior should be to redirect to setup page
146
-        loMenuItems = loApiController.buildTreeListForMenu(loCurrentNode, pbmd.PBNodeStatus.getVisibleIdsList(), llAccessibleNodes)
147
-
148
         return dict(
144
         return dict(
149
-            menu_node_list=loMenuItems,
145
+            current_user=loCurrentUser,
150
             current_node=loCurrentNode,
146
             current_node=loCurrentNode,
147
+            allowed_nodes=llAccessibleNodes,
151
             node_status_list = loNodeStatusList,
148
             node_status_list = loNodeStatusList,
152
             keywords = highlight,
149
             keywords = highlight,
153
             user_specific_group_rights = pld.PODStaticController.getUserDedicatedGroupRightsOnNode(node_id),
150
             user_specific_group_rights = pld.PODStaticController.getUserDedicatedGroupRightsOnNode(node_id),