--- a/src/pyams_workflow/zmi/workflow.py Thu Oct 08 11:36:22 2015 +0200
+++ b/src/pyams_workflow/zmi/workflow.py Thu Oct 08 11:37:30 2015 +0200
@@ -16,9 +16,10 @@
# import standard library
# import interfaces
+from pyams_skin.interfaces.viewlet import IToolbarViewletManager
from pyams_i18n.interfaces import II18n
-from pyams_skin.interfaces.viewlet import IToolbarViewletManager
from pyams_skin.layer import IPyAMSLayer
+from pyams_utils.interfaces import VIEW_SYSTEM_PERMISSION
from pyams_workflow.interfaces import IWorkflow, IWorkflowInfo, IWorkflowVersion, IWorkflowManagedContent, \
IWorkflowVersions, IWorkflowState
from pyams_workflow.zmi.interfaces import IWorkflowMenu
@@ -56,8 +57,8 @@
self.modal_target = True
-@viewlet_config(name='workflow.menu', view=Interface, layer=IAdminLayer, context=IWorkflowVersion,
- manager=IToolbarViewletManager, weight=800)
+@viewlet_config(name='workflow.menu', context=IWorkflowVersion, layer=IAdminLayer,
+ view=Interface, manager=IToolbarViewletManager, weight=800)
@viewletmanager_config(name='workflow.menu', layer=IAdminLayer, provides=IWorkflowMenu)
@implementer(IWorkflowMenu)
class WorkflowMenu(ToolbarMenu):
@@ -115,7 +116,7 @@
@view_config(name='get-old-versions.html', context=IContainer, request_type=IPyAMSLayer,
- permission='system.view', xhr=True)
+ permission=VIEW_SYSTEM_PERMISSION, xhr=True)
def get_old_versions(request):
"""Get old_versions of template"""
container = request.context