mirror of
https://shylinux.com/x/volcanos
synced 2025-04-25 16:58:06 +08:00
add some
This commit is contained in:
parent
e70b727c94
commit
3a3def6e96
@ -333,7 +333,13 @@ Volcanos("user", {
|
|||||||
begin: function() { begin = new Date(), can.user.toastProcess(can, "upload")
|
begin: function() { begin = new Date(), can.user.toastProcess(can, "upload")
|
||||||
var upload = can.page.Select(can, ui.action, html.INPUT_FILE)[0]; if (upload.files.length == 0) { return upload.focus() }
|
var upload = can.page.Select(can, ui.action, html.INPUT_FILE)[0]; if (upload.files.length == 0) { return upload.focus() }
|
||||||
var msg = can.request(event, can.Option(), {_handle: ice.TRUE}); msg._upload = upload.files[0], msg._progress = action.show
|
var msg = can.request(event, can.Option(), {_handle: ice.TRUE}); msg._upload = upload.files[0], msg._progress = action.show
|
||||||
can.runAction(event, html.UPLOAD, [], function(msg) { can.base.isFunc(cb)? cb(msg): can.Update(), action.close(), can.user.toastSuccess(can, "upload") })
|
can.runAction(event, html.UPLOAD, [], function(msg) {
|
||||||
|
if (msg.IsErr()) {
|
||||||
|
action.close(), can.user.toastFailure(can, msg.Result())
|
||||||
|
return
|
||||||
|
}
|
||||||
|
can.base.isFunc(cb)? cb(msg): can.Update(), action.close(), can.user.toastSuccess(can, "upload")
|
||||||
|
})
|
||||||
}, close: function(event) { can.page.Remove(can, ui._target) },
|
}, close: function(event) { can.page.Remove(can, ui._target) },
|
||||||
show: function (event, value, total, loaded) {
|
show: function (event, value, total, loaded) {
|
||||||
ui.cost.innerHTML = can.base.Duration(new Date() - begin)
|
ui.cost.innerHTML = can.base.Duration(new Date() - begin)
|
||||||
|
@ -83,6 +83,12 @@ tr.line>td.text { white-space:pre; line-height:var(--code-line-height); padding-
|
|||||||
tr.line:hover { background-color:var(--hover-bg-color); }
|
tr.line:hover { background-color:var(--hover-bg-color); }
|
||||||
tr.line.delete { background-color:#3c2626; }
|
tr.line.delete { background-color:#3c2626; }
|
||||||
tr.line.insert { background-color:#283e2d; }
|
tr.line.insert { background-color:#283e2d; }
|
||||||
|
body div.input.inner.find.float div.action>div.item {
|
||||||
|
float:left;
|
||||||
|
}
|
||||||
|
body div.input.inner.find.float div.action>div.item>input {
|
||||||
|
min-width:unset;
|
||||||
|
}
|
||||||
body.light tr.line.delete { background-color:#ffeef0; }
|
body.light tr.line.delete { background-color:#ffeef0; }
|
||||||
body.light tr.line.insert { background-color:#e6ffed; }
|
body.light tr.line.insert { background-color:#e6ffed; }
|
||||||
body.white tr.line.delete { background-color:#e6ffed; }
|
body.white tr.line.delete { background-color:#e6ffed; }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user