Changed admin view name to "admin" instead of "admin.html"
authorThierry Florac <thierry.florac@onf.fr>
Tue, 11 Oct 2016 16:00:27 +0200
changeset 57 23ee41f44161
parent 56 eecb9a1e87aa
child 58 17740c96ce40
Changed admin view name to "admin" instead of "admin.html"
src/pyams_content/shared/blog/zmi/__init__.py
src/pyams_content/shared/blog/zmi/manager.py
src/pyams_content/shared/common/review.py
src/pyams_content/shared/common/zmi/__init__.py
src/pyams_content/shared/common/zmi/dashboard.py
src/pyams_content/shared/common/zmi/header.py
src/pyams_content/shared/common/zmi/manager.py
src/pyams_content/shared/common/zmi/security.py
src/pyams_content/shared/common/zmi/summary.py
src/pyams_content/shared/common/zmi/templates/review-notification.pt
src/pyams_content/shared/common/zmi/workflow.py
src/pyams_content/zmi/viewlet/toplinks/__init__.py
--- a/src/pyams_content/shared/blog/zmi/__init__.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/blog/zmi/__init__.py	Tue Oct 11 16:00:27 2016 +0200
@@ -106,7 +106,7 @@
         if added:
             IWorkflowVersions(content).add_version(wf_content, None)
             IWorkflowInfo(wf_content).fire_transition('init')
-            self.content_url = absolute_url(wf_content, self.request, 'admin.html')
+            self.content_url = absolute_url(wf_content, self.request, 'admin')
 
     def nextURL(self):
         return self.content_url
--- a/src/pyams_content/shared/blog/zmi/manager.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/blog/zmi/manager.py	Tue Oct 11 16:00:27 2016 +0200
@@ -123,5 +123,5 @@
 class SiteTreeTableElementEditor(DefaultElementEditorAdapter):
     """Site tree table element editor"""
 
-    view_name = 'admin.html'
+    view_name = 'admin'
     modal_target = False
--- a/src/pyams_content/shared/common/review.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/review.py	Tue Oct 11 16:00:27 2016 +0200
@@ -203,7 +203,7 @@
                                     category='content.review',
                                     message=translate(_("A new comment was added on content « {0} »")).format(
                                         II18n(content).query_attribute('title', request=request)),
-                                    url=absolute_url(content, request, 'admin.html#review-comments.html'),
+                                    url=absolute_url(content, request, 'admin#review-comments.html'),
                                     comments=IReviewComments(content))
         notification.send()
 
--- a/src/pyams_content/shared/common/zmi/__init__.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/__init__.py	Tue Oct 11 16:00:27 2016 +0200
@@ -103,7 +103,7 @@
         IWorkflowInfo(wf_content).fire_transition('init')
 
     def nextURL(self):
-        return absolute_url(self.context, self.request, '{0}/++versions++/1/@@admin.html'.format(self.__uuid))
+        return absolute_url(self.context, self.request, '{0}/++versions++/1/admin'.format(self.__uuid))
 
 
 class SharedContentAJAXAddForm(AJAXAddForm):
@@ -205,7 +205,7 @@
     @property
     def back_url(self):
         shared_tool = get_parent(self.context, ISharedTool)
-        return absolute_url(shared_tool, self.request, 'admin.html#dashboard.html')
+        return absolute_url(shared_tool, self.request, 'admin#dashboard.html')
 
     back_target = None
     icon_class = 'fa fa-fw fa-edit'
@@ -215,7 +215,7 @@
 class WfSharedContentElementEditor(DefaultElementEditorAdapter):
     """Shared content element editor"""
 
-    view_name = 'admin.html'
+    view_name = 'admin'
     modal_target = False
 
 
@@ -314,7 +314,7 @@
 
     def get_ajax_output(self, changes):
         return {'status': 'redirect',
-                'location': absolute_url(changes, self.request, 'admin.html')}
+                'location': absolute_url(changes, self.request, 'admin')}
 
 
 @viewlet_config(name='wf-duplicate-message', context=IWfSharedContent, layer=IPyAMSLayer,
--- a/src/pyams_content/shared/common/zmi/dashboard.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/dashboard.py	Tue Oct 11 16:00:27 2016 +0200
@@ -252,7 +252,7 @@
 class SharedToolDashboardHeaderAdapter(DefaultPageHeaderAdapter):
     """Shared tool properties header adapter"""
 
-    back_url = '/admin.html#dashboard.html'
+    back_url = '/admin#dashboard.html'
     back_target = None
 
     icon_class = 'fa fa-fw fa-line-chart'
--- a/src/pyams_content/shared/common/zmi/header.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/header.py	Tue Oct 11 16:00:27 2016 +0200
@@ -113,7 +113,7 @@
                             key=lambda x: IWorkflowState(x).version_id)[-1]
             self.version_link = {
                 'css_class': 'text-danger',
-                'href': absolute_url(target, request, 'admin.html'),
+                'href': absolute_url(target, request, 'admin'),
                 'title': translate(_("access new version"))
             }
         elif state.state not in workflow.published_states and versions.has_version(workflow.published_states):
@@ -122,7 +122,7 @@
                             reverse=True)[-1]
             self.version_link = {
                 'css_class': 'text-danger',
-                'href': absolute_url(target, request, 'admin.html'),
+                'href': absolute_url(target, request, 'admin'),
                 'title': translate(_("access published version"))
             }
         else:
--- a/src/pyams_content/shared/common/zmi/manager.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/manager.py	Tue Oct 11 16:00:27 2016 +0200
@@ -134,7 +134,7 @@
 class SharedToolPropertiesHeaderAdapter(DefaultPageHeaderAdapter):
     """Shared tool properties header adapter"""
 
-    back_url = '/admin.html#properties.html'
+    back_url = '/admin#properties.html'
     back_target = None
 
     icon_class = 'fa fa-fw fa-edit'
--- a/src/pyams_content/shared/common/zmi/security.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/security.py	Tue Oct 11 16:00:27 2016 +0200
@@ -117,7 +117,7 @@
 class SharedToolManagersRestrictionsHeaderAdapter(DefaultPageHeaderAdapter):
     """Shared tool managers restrictions header adapter"""
 
-    back_url = 'admin.html#protected-object-roles.html'
+    back_url = 'admin#protected-object-roles.html'
     back_target = None
 
     icon_class = 'fa fa-fw fa-lock'
--- a/src/pyams_content/shared/common/zmi/summary.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/summary.py	Tue Oct 11 16:00:27 2016 +0200
@@ -61,7 +61,7 @@
     @property
     def back_url(self):
         tool = get_parent(self.context, ISharedTool)
-        return absolute_url(tool, self.request, 'admin.html')
+        return absolute_url(tool, self.request, 'admin')
 
 
 @adapter_config(name='dublincore-summary',
--- a/src/pyams_content/shared/common/zmi/templates/review-notification.pt	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/templates/review-notification.pt	Tue Oct 11 16:00:27 2016 +0200
@@ -19,7 +19,7 @@
 	<p i18n:translate="">Comment associated with this request is:</p>
 	<pre style="padding: 5px 20px;" tal:content="options['comment']">comment</pre>
 	<p i18n:translate="">To review and comment this publication, please use the following link: <a i18n:name="target"
-			tal:attributes="href extension:absolute_url(context, 'admin.html')"
+			tal:attributes="href extension:absolute_url(context, 'admin')"
 			tal:content="i18n:context.title"></a></p>
 	<br />
 	<pre tal:content="options['settings'].signature">signature</pre>
--- a/src/pyams_content/shared/common/zmi/workflow.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/shared/common/zmi/workflow.py	Tue Oct 11 16:00:27 2016 +0200
@@ -744,7 +744,7 @@
 
     def get_ajax_output(self, changes):
         return {'status': 'redirect',
-                'location': absolute_url(changes, self.request, 'admin.html#properties.html')}
+                'location': absolute_url(changes, self.request, 'admin#properties.html')}
 
 
 @viewlet_config(name='wf-clone-message', context=IWfSharedContent, layer=IPyAMSLayer,
@@ -811,7 +811,7 @@
 
     def get_ajax_output(self, changes):
         return {'status': 'redirect',
-                'location': absolute_url(self._SharedContentDeleteForm__target, self.request, 'admin.html')}
+                'location': absolute_url(self._SharedContentDeleteForm__target, self.request, 'admin')}
 
 
 @viewlet_config(name='wf-delete-message', context=IWfSharedContent, layer=IPyAMSLayer,
--- a/src/pyams_content/zmi/viewlet/toplinks/__init__.py	Mon Oct 10 15:24:45 2016 +0200
+++ b/src/pyams_content/zmi/viewlet/toplinks/__init__.py	Tue Oct 11 16:00:27 2016 +0200
@@ -52,7 +52,7 @@
         for name, site in registry.getUtilitiesFor(ISharedSite):
             menu = TopLinksMenu(self.context, self.request, self.__parent__, self)
             menu.label = II18n(site).query_attribute('title', request=self.request) or tool.__name__
-            menu.url = absolute_url(site, self.request, 'admin.html#dashboard.html')
+            menu.url = absolute_url(site, self.request, 'admin#dashboard.html')
             self.viewlets.append(menu)
 
 
@@ -72,7 +72,7 @@
                 continue
             menu = TopLinksMenu(self.context, self.request, self.__parent__, self)
             menu.label = II18n(tool).query_attribute('title', request=self.request) or tool.__name__
-            menu.url = absolute_url(tool, self.request, 'admin.html#dashboard.html')
+            menu.url = absolute_url(tool, self.request, 'admin#dashboard.html')
             self.viewlets.append(menu)
 
 
@@ -95,7 +95,7 @@
                            key=lambda x: II18n(x).query_attribute('title', request=self.request)):
             menu = TopLinksMenu(self.context, self.request, self.__parent__, self)
             menu.label = II18n(tool).query_attribute('title', request=self.request) or tool.__name__
-            menu.url = absolute_url(tool, self.request, 'admin.html#dashboard.html')
+            menu.url = absolute_url(tool, self.request, 'admin#dashboard.html')
             self.viewlets.append(menu)