1
0
mirror of https://shylinux.com/x/volcanos synced 2025-04-25 16:58:06 +08:00
This commit is contained in:
shaoying 2020-07-03 08:44:14 +08:00
parent e1cae0104a
commit e88d504f5c
5 changed files with 13 additions and 17 deletions

View File

@ -76,7 +76,7 @@ fieldset>form.option>div.item.textarea {
} }
fieldset>div.action { fieldset>div.action {
clear:both; clear:none;
} }
fieldset>div.action>div.item { fieldset>div.action>div.item {
float:left; float:left;
@ -85,7 +85,7 @@ fieldset>div.action>div.item {
fieldset>div.action>div.item>select { fieldset>div.action>div.item>select {
color:cyan; color:cyan;
background:black; background:black;
margin:3px 0; /* margin:3px 0; */
} }
fieldset>div.action>div.item>input { fieldset>div.action>div.item>input {
color:cyan; color:cyan;

View File

@ -100,13 +100,12 @@ Volcanos("onexport", {help: "导出数据", list: [], _init: function(can, msg,
}, },
}]} }]}
})); }));
if (location.protocol == "chrome-extension:") { if (location.protocol == "chrome-extension:") {
ui.River.click() ui.River.click()
} else { } else if (can.user.Search(can, "pod")) {
// ui.River.click(), ui.Footer.click(), ui.Storm.click() ui.River.click(), ui.Footer.click(), ui.Storm.click()
// ui.River.click(), ui.Footer.click() } else if (can.user.isMobile) {
}
if (can.user.isMobile) {
ui.River.click(), ui.Footer.click(), ui.Storm.click() ui.River.click(), ui.Footer.click(), ui.Storm.click()
} }

View File

@ -1,4 +1,5 @@
fieldset.input.date { fieldset.input.date {
position:fixed;
background-color:black; background-color:black;
z-index:100; z-index:100;
} }

View File

@ -3,8 +3,7 @@ Volcanos("onfigure", {help: "控件详情", list: [], _merge: function(can, sub)
}); return true }, }); return true },
date: {onclick: function(event, can, item, target) { date: {onclick: function(event, can, item, target) {
can._figure && can.page.Remove(can, can._figure.fieldset)
can._figure = can.onappend.field(can, can._target, "input date", {})
// 设置输入 // 设置输入
function set(now) { function set(now) {
target.value = can.base.Time(now); target.value = can.base.Time(now);
@ -12,11 +11,9 @@ Volcanos("onfigure", {help: "控件详情", list: [], _merge: function(can, sub)
} }
// 添加插件 // 添加插件
var figure = can._figure var figure = can.onappend.field(can, document.body, "input date", {})
figure.table = can.page.Append(can, figure.output, [{type: "table"}]).first figure.table = can.page.Append(can, figure.output, [{type: "table"}]).first
// can.page.Modify(can, figure.fieldset, {style: {top: target.offsetTop+20, left: target.offsetLeft}}) can.page.Modify(can, figure.fieldset, {style: {top: event.clientY+10, left: event.clientX}})
var offset = can.page.offset(can._target)
can.page.Modify(can, figure.fieldset, {style: {top: event.clientY-offset.Top+60, left: event.clientX-offset.Left+60}})
can.page.Remove(can, figure.legend) can.page.Remove(can, figure.legend)
// 添加控件 // 添加控件
@ -41,7 +38,7 @@ Volcanos("onfigure", {help: "控件详情", list: [], _merge: function(can, sub)
case "关闭": can.page.Remove(can, figure.fieldset); break; case "关闭": can.page.Remove(can, figure.fieldset); break;
case "今天": now = new Date(); set(show(now)); break; case "今天": now = new Date(); set(show(now)); break;
case "随机": now.setDate((Math.random() * 100 - 50) + now.getDate()); set(show(now)); break; case "随机": now.setDate((Math.random() * 100 - 50) + now.getDate()); set(show(now)); break;
case "关闭": can.page.Remove(can, figure.first); delete(can.figure); case "关闭": can.page.Remove(can, figure.first);
case "前一年": now.setFullYear(now.getFullYear()-1); show(now); break; case "前一年": now.setFullYear(now.getFullYear()-1); show(now); break;
case "后一年": now.setFullYear(now.getFullYear()+1); show(now); break; case "后一年": now.setFullYear(now.getFullYear()+1); show(now); break;
case "上一月": now.setMonth(now.getMonth()-1); show(now); break; case "上一月": now.setMonth(now.getMonth()-1); show(now); break;

View File

@ -208,13 +208,12 @@ Volcanos("onimport", {help: "导入数据", list: [], _init: function(can, msg,
}]).table }]).table
}, },
}, ["/plugin/local/team/plan.css"]) }, ["/plugin/local/team/plan.css"])
Volcanos("onaction", {help: "组件交互", list: ["统计", "添加", "详情", "", Volcanos("onaction", {help: "组件交互", list: ["导出", "导入", "统计", "详情", "",
["level", "all", "l1", "l2", "l3", "l4", "l5"], ["level", "all", "l1", "l2", "l3", "l4", "l5"],
["status", "all", "prepare", "process", "cancel", "finish"], ["status", "all", "prepare", "process", "cancel", "finish"],
["score", "all", "s1", "s2", "s3", "s4", "s5"], ["score", "all", "s1", "s2", "s3", "s4", "s5"],
["view", "", "name", "text", "level", "score"], ["view", "", "name", "text", "level", "score"],
"", "启动", "运行", "完成", "", "添加", "启动", "运行", "完成",
"", "导出", "导入",
], ],
insertTask: function(event, can, now) { now = now || new Date() insertTask: function(event, can, now) { now = now || new Date()
can.require([ can.require([