Used named permissions
authorThierry Florac <thierry.florac@onf.fr>
Thu, 08 Oct 2015 09:17:34 +0200
changeset 30 0adccc351f22
parent 29 9ffccb764e97
child 31 725a69f6cd33
Used named permissions
src/pyams_form/search.py
--- a/src/pyams_form/search.py	Thu Oct 08 09:17:13 2015 +0200
+++ b/src/pyams_form/search.py	Thu Oct 08 09:17:34 2015 +0200
@@ -19,6 +19,7 @@
 from pyams_form.interfaces.form import IWidgetForm, ISearchForm
 from pyams_skin.interfaces import IContentSearch, IInnerPage, ISearchPage
 from pyams_skin.layer import IPyAMSLayer
+from pyams_utils.interfaces import VIEW_SYSTEM_PERMISSION
 from z3c.table.interfaces import IValues
 
 # import packages
@@ -61,7 +62,7 @@
 
     ajax_handler = 'search-results.html'
     form_target = '#search-results'
-    edit_permission = 'system.view'
+    edit_permission = VIEW_SYSTEM_PERMISSION
 
     def updateActions(self):
         super(SearchForm, self).updateActions()