Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
5db07830
Commit
5db07830
authored
Apr 03, 2007
by
Martijn Pieters
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use the requestmethod decorator generator (better documentation)
parent
217651d6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
lib/python/App/ApplicationManager.py
lib/python/App/ApplicationManager.py
+6
-6
No files found.
lib/python/App/ApplicationManager.py
View file @
5db07830
...
...
@@ -30,7 +30,7 @@ from Product import ProductFolder
from
version_txt
import
version_txt
from
cStringIO
import
StringIO
from
AccessControl
import
getSecurityManager
from
AccessControl.requestmethod
import
postonly
from
AccessControl.requestmethod
import
requestmethod
from
zExceptions
import
Redirect
from
Products.PageTemplates.PageTemplateFile
import
PageTemplateFile
from
cgi
import
escape
...
...
@@ -389,7 +389,7 @@ class ApplicationManager(Folder,CacheManager):
if
os
.
environ
.
has_key
(
'ZMANAGED'
):
manage_restartable
=
1
@
postonly
@
requestmethod
(
'POST'
)
def
manage_restart
(
self
,
URL1
,
REQUEST
=
None
):
"""Shut down the application"""
try
:
...
...
@@ -405,7 +405,7 @@ class ApplicationManager(Folder,CacheManager):
<body>Zope is restarting</body></html>
"""
%
escape
(
URL1
,
1
)
@
postonly
@
requestmethod
(
'POST'
)
def
manage_shutdown
(
self
,
REQUEST
=
None
):
"""Shut down the application"""
try
:
...
...
@@ -421,7 +421,7 @@ class ApplicationManager(Folder,CacheManager):
<body>Zope is shutting down</body></html>
"""
@
postonly
@
requestmethod
(
'POST'
)
def
manage_pack
(
self
,
days
=
0
,
REQUEST
=
None
):
"""Pack the database"""
...
...
@@ -476,7 +476,7 @@ class ApplicationManager(Folder,CacheManager):
r
.
append
({
'id'
:
v
})
return
r
@
postonly
@
requestmethod
(
'POST'
)
def
manage_saveVersions
(
self
,
versions
,
REQUEST
=
None
):
"Commit some versions"
db
=
self
.
_p_jar
.
db
()
...
...
@@ -485,7 +485,7 @@ class ApplicationManager(Folder,CacheManager):
if
REQUEST
is
not
None
:
REQUEST
[
'RESPONSE'
].
redirect
(
REQUEST
[
'URL1'
]
+
'/manage_main'
)
@
postonly
@
requestmethod
(
'POST'
)
def
manage_discardVersions
(
self
,
versions
,
REQUEST
=
None
):
"Discard some versions"
db
=
self
.
_p_jar
.
db
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment