Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mailinabox
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
mailinabox
Commits
1e3e34f1
Commit
1e3e34f1
authored
Jul 27, 2015
by
Leo Koppelkamm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make backup API RESTful
parent
96fb0f78
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
daemon.py
management/daemon.py
+2
-2
system-backup.html
management/templates/system-backup.html
+2
-2
No files found.
management/daemon.py
View file @
1e3e34f1
...
...
@@ -402,13 +402,13 @@ def backup_status():
from
backup
import
backup_status
return
json_response
(
backup_status
(
env
))
@
app
.
route
(
'/system/backup/
get-custom'
)
@
app
.
route
(
'/system/backup/
config'
,
methods
=
[
"GET"
]
)
@
authorized_personnel_only
def
backup_get_custom
():
from
backup
import
get_backup_config
return
json_response
(
get_backup_config
())
@
app
.
route
(
'/system/backup/
set-custom
'
,
methods
=
[
"POST"
])
@
app
.
route
(
'/system/backup/
config
'
,
methods
=
[
"POST"
])
@
authorized_personnel_only
def
backup_set_custom
():
from
backup
import
backup_set_custom
...
...
management/templates/system-backup.html
View file @
1e3e34f1
...
...
@@ -138,7 +138,7 @@ function show_system_backup() {
function
show_custom_backup
()
{
api
(
"
/system/backup/
get-
custom
"
,
"
/system/backup/custom
"
,
"
GET
"
,
{
},
function
(
r
)
{
...
...
@@ -158,7 +158,7 @@ function set_custom_backup() {
var
target_pass
=
$
(
"
#target-pass
"
).
val
();
var
max_age
=
$
(
"
#max-age
"
).
val
();
api
(
"
/system/backup/
set-
custom
"
,
"
/system/backup/custom
"
,
"
POST
"
,
{
target
:
target
,
...
...
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