feat($task): 删除任务弹出确认提示

Close #28
pull/21/merge
ouqiang 2017-12-09 10:16:30 +08:00
parent e9b475a230
commit 3fd5b2ee55
2 changed files with 7 additions and 1 deletions

1
.gitignore vendored
View File

@ -23,6 +23,7 @@ _testmain.go
*.test *.test
*.prof *.prof
.DS_Store
.idea .idea
log/* log/*
data/* data/*

View File

@ -211,7 +211,12 @@
} }
function remove(id, stopReload) { function remove(id, stopReload) {
util.post('/task/remove/' + id, {}, function () { var url = '/task/remove/' + id;
if (stopReload === undefined) {
util.removeConfirm(url);
return;
}
util.post(url, {}, function () {
if (stopReload === undefined) { if (stopReload === undefined) {
location.reload(); location.reload();
} }