mirror of
https://shylinux.com/x/icebergs
synced 2025-04-27 17:58:29 +08:00
opt some
This commit is contained in:
parent
c625ff88a3
commit
982483dc39
@ -17,16 +17,17 @@ import (
|
||||
|
||||
func _dream_list(m *ice.Message) *ice.Message {
|
||||
return m.Cmdy(nfs.DIR, m.Config(nfs.PATH), "time,size,name").Table(func(index int, value map[string]string, head []string) {
|
||||
if m.Richs(SPACE, nil, value[mdb.NAME], func(key string, value map[string]interface{}) {
|
||||
m.Push(mdb.TYPE, value[mdb.TYPE])
|
||||
if m.Richs(SPACE, nil, value[mdb.NAME], func(key string, val map[string]interface{}) {
|
||||
m.Push(mdb.TYPE, val[mdb.TYPE])
|
||||
m.Push(cli.STATUS, cli.START)
|
||||
m.PushButton(cli.STOP)
|
||||
m.PushAnchor(strings.Split(kit.MergePOD(m.Option(ice.MSG_USERWEB), value[mdb.NAME]), "?")[0])
|
||||
}) == nil {
|
||||
m.Push(mdb.TYPE, WORKER)
|
||||
m.Push(cli.STATUS, cli.STOP)
|
||||
m.PushButton(cli.START)
|
||||
m.PushAnchor("")
|
||||
}
|
||||
m.Push(mdb.LINK, strings.Split(kit.MergePOD(m.Option(ice.MSG_USERWEB), value[mdb.NAME]), "?")[0])
|
||||
})
|
||||
}
|
||||
func _dream_show(m *ice.Message, name string) {
|
||||
|
@ -144,7 +144,11 @@ func init() {
|
||||
})
|
||||
}},
|
||||
}, mdb.HashAction()), Hand: func(m *ice.Message, c *ice.Context, cmd string, arg ...string) {
|
||||
if mdb.HashSelect(m, arg...); len(arg) == 0 {
|
||||
mdb.HashSelect(m, arg...).Table(func(index int, value map[string]string, head []string) {
|
||||
m.PushAnchor(strings.Split(m.MergeURL2(value[nfs.PATH]), "?")[0])
|
||||
})
|
||||
|
||||
if len(arg) == 0 {
|
||||
dir := SRC_WEBSITE
|
||||
m.Cmd(nfs.DIR, dir, func(f os.FileInfo, p string) {
|
||||
m.Push("", kit.Dict(
|
||||
@ -155,11 +159,10 @@ func init() {
|
||||
mdb.TEXT, m.Cmdx(nfs.CAT, p),
|
||||
), kit.Split(m.Config(mdb.FIELD)))
|
||||
m.PushButton("")
|
||||
m.PushAnchor(strings.Split(m.MergeURL2(path.Join(CHAT_WEBSITE, p)), "?")[0])
|
||||
})
|
||||
}
|
||||
m.Table(func(index int, value map[string]string, head []string) {
|
||||
m.PushAnchor(strings.Split(m.MergeURL2(value[nfs.PATH]), "?")[0])
|
||||
})
|
||||
|
||||
if m.Length() == 0 && len(arg) > 0 {
|
||||
m.Push(mdb.TEXT, m.Cmdx(nfs.CAT, path.Join(SRC_WEBSITE, path.Join(arg...))))
|
||||
m.Push(nfs.PATH, path.Join(CHAT_WEBSITE, path.Join(arg...)))
|
||||
|
Loading…
x
Reference in New Issue
Block a user