mirror of
https://shylinux.com/x/icebergs
synced 2025-04-25 17:18:05 +08:00
opt draw.js
This commit is contained in:
parent
f0b3a57395
commit
06dc70c4fe
@ -12,11 +12,9 @@ const DRAW = "draw"
|
||||
|
||||
func init() {
|
||||
Index.Merge(&ice.Context{Configs: map[string]*ice.Config{
|
||||
DRAW: {Name: DRAW, Help: "思维导图", Value: kit.Data(
|
||||
kit.MDB_PATH, "", kit.MDB_REGEXP, ".*\\.svg",
|
||||
)},
|
||||
DRAW: {Name: DRAW, Help: "思维导图", Value: kit.Data(kit.MDB_REGEXP, ".*\\.svg")},
|
||||
}, Commands: map[string]*ice.Command{
|
||||
DRAW: {Name: "draw path=src/main.svg refresh:button=auto 编辑 save 项目 参数", Help: "思维导图", Meta: kit.Dict(
|
||||
DRAW: {Name: "draw path=src/main.svg refresh:button=auto edit save project actions", Help: "思维导图", Meta: kit.Dict(
|
||||
ice.Display("/plugin/local/wiki/draw.js"),
|
||||
), Action: map[string]*ice.Action{
|
||||
nfs.SAVE: {Name: "save path", Help: "保存", Hand: func(m *ice.Message, arg ...string) {
|
||||
|
@ -27,15 +27,15 @@ func init() {
|
||||
}, Commands: map[string]*ice.Command{
|
||||
TOTAL: {Name: "total name auto pie", Help: "统计量", Action: map[string]*ice.Action{
|
||||
"pie": {Name: "pie", Help: "饼图", Hand: func(m *ice.Message, arg ...string) {
|
||||
defer m.Display("/plugin/story/pie.js")
|
||||
m.Cmd(TOTAL).Table(func(index int, value map[string]string, head []string) {
|
||||
if value["name"] == "total" {
|
||||
m.StatusTimeCount("name", "total", "value", "1", "total", value["rest"])
|
||||
return
|
||||
}
|
||||
m.Push("name", value["name"])
|
||||
m.Push("value", value["rest"])
|
||||
})
|
||||
m.Display("/plugin/story/pie.js")
|
||||
m.StatusTimeCount("name", "total", "value", "1")
|
||||
}},
|
||||
}, Hand: func(m *ice.Message, c *ice.Context, cmd string, arg ...string) {
|
||||
if len(arg) > 0 { // 提交详情
|
||||
|
Loading…
x
Reference in New Issue
Block a user