1
0
mirror of https://shylinux.com/x/icebergs synced 2025-04-26 09:34:05 +08:00
This commit is contained in:
IT 老营长 @云轩领航-创始人 2024-01-17 19:30:28 +08:00
parent 5bc1e480fa
commit ac90f10b41
6 changed files with 13 additions and 15 deletions

View File

@ -152,11 +152,13 @@ func init() {
} }
}) })
}) })
for _, cmd := range kit.Reverse(kit.Split(mdb.Config(m, html.BUTTON))) { m.GoSleep("1s", func() {
m.Cmd(gdb.EVENT, gdb.LISTEN, gdb.EVENT, DREAM_TABLES, ice.CMD, cmd) for _, cmd := range kit.Reverse(kit.Split(mdb.Config(m, html.BUTTON))) {
m.Cmd(gdb.EVENT, gdb.LISTEN, gdb.EVENT, DREAM_ACTION, ice.CMD, cmd) m.Cmd(gdb.EVENT, gdb.LISTEN, gdb.EVENT, DREAM_TABLES, ice.CMD, cmd)
} m.Cmd(gdb.EVENT, gdb.LISTEN, gdb.EVENT, DREAM_ACTION, ice.CMD, cmd)
aaa.White(m, kit.Keys(m.PrefixKey(), ctx.ACTION, DREAM_ACTION, ctx.RUN)) }
aaa.White(m, kit.Keys(m.PrefixKey(), ctx.ACTION, DREAM_ACTION, ctx.RUN))
})
}}, }},
html.BUTTON: {Hand: func(m *ice.Message, arg ...string) { mdb.Config(m, html.BUTTON, kit.Join(arg)) }}, html.BUTTON: {Hand: func(m *ice.Message, arg ...string) { mdb.Config(m, html.BUTTON, kit.Join(arg)) }},
mdb.SEARCH: {Hand: func(m *ice.Message, arg ...string) { mdb.SEARCH: {Hand: func(m *ice.Message, arg ...string) {

View File

@ -10,6 +10,6 @@ const CHAT = "chat"
var Index = &ice.Context{Name: CHAT, Help: "聊天中心"} var Index = &ice.Context{Name: CHAT, Help: "聊天中心"}
func init() { web.Index.Register(Index, &web.Frame{}, HEADER, FAVOR) } func init() { web.Index.Register(Index, &web.Frame{}, HEADER, IFRAME, FAVOR) }
func Prefix(arg ...string) string { return web.Prefix(CHAT, kit.Keys(arg)) } func Prefix(arg ...string) string { return web.Prefix(CHAT, kit.Keys(arg)) }

View File

@ -112,7 +112,6 @@ func init() {
}}, }},
}, web.ApiAction(), mdb.ImportantHashAction(mdb.SHORT, mdb.NAME, mdb.FIELD, "time,name,icons,type,link,order,space,index,args")), Hand: func(m *ice.Message, arg ...string) { }, web.ApiAction(), mdb.ImportantHashAction(mdb.SHORT, mdb.NAME, mdb.FIELD, "time,name,icons,type,link,order,space,index,args")), Hand: func(m *ice.Message, arg ...string) {
kit.If(m.Option(ice.MSG_USERPOD), func(p string) { m.Option(ice.MSG_NODETYPE, m.Cmdx(web.SPACE, p, cli.RUNTIME, ice.MSG_NODETYPE)) }) kit.If(m.Option(ice.MSG_USERPOD), func(p string) { m.Option(ice.MSG_NODETYPE, m.Cmdx(web.SPACE, p, cli.RUNTIME, ice.MSG_NODETYPE)) })
m.Debug("what %v", m.Option(ice.MSG_NODETYPE))
m.Option("language.list", m.Cmd(nfs.DIR, nfs.TemplatePath(m, aaa.LANGUAGE)+nfs.PS, nfs.FILE).Appendv(nfs.FILE)) m.Option("language.list", m.Cmd(nfs.DIR, nfs.TemplatePath(m, aaa.LANGUAGE)+nfs.PS, nfs.FILE).Appendv(nfs.FILE))
m.Option("theme.list", m.Cmd(nfs.DIR, nfs.TemplatePath(m, aaa.THEME)+nfs.PS, nfs.FILE).Appendv(nfs.FILE)) m.Option("theme.list", m.Cmd(nfs.DIR, nfs.TemplatePath(m, aaa.THEME)+nfs.PS, nfs.FILE).Appendv(nfs.FILE))
m.Option(nfs.REPOS, m.Cmdv(web.SPIDE, nfs.REPOS, web.CLIENT_URL)) m.Option(nfs.REPOS, m.Cmdv(web.SPIDE, nfs.REPOS, web.CLIENT_URL))

View File

@ -94,7 +94,8 @@ func _autogen_git(m *ice.Message, arg ...string) ice.Map {
return kit.Dict(arg, aaa.USERNAME, m.Option(ice.MSG_USERNAME), tcp.HOSTNAME, ice.Info.Hostname, nfs.PATH, kit.Path("")+nfs.PS, mdb.TIME, m.Time(), return kit.Dict(arg, aaa.USERNAME, m.Option(ice.MSG_USERNAME), tcp.HOSTNAME, ice.Info.Hostname, nfs.PATH, kit.Path("")+nfs.PS, mdb.TIME, m.Time(),
GIT, GitVersion(m), GO, GoVersion(m), nfs.MODULE, _autogen_mod(m, ice.GO_MOD), GIT, GitVersion(m), GO, GoVersion(m), nfs.MODULE, _autogen_mod(m, ice.GO_MOD),
msg.AppendSimple("remote,branch,version,forword,author,email,hash,when,message"), msg.AppendSimple("remote,branch,version,forword,author,email,hash,when,message"),
web.DOMAIN, strings.ReplaceAll(tcp.PublishLocalhost(m, m.Option(ice.MSG_USERWEB)), "%2F", nfs.PS), // web.DOMAIN, strings.ReplaceAll(tcp.PublishLocalhost(m, m.Option(ice.MSG_USERWEB)), "%2F", nfs.PS),
web.DOMAIN, m.Spawn(kit.Dict(ice.MSG_USERWEB, m.Option(ice.MSG_USERHOST), ice.MSG_USERPOD, m.Option(ice.MSG_USERPOD))).MergePod(""),
cli.SYSTEM, ice.Info.System, cli.SYSTEM, ice.Info.System,
) )
} }

View File

@ -105,10 +105,8 @@ func init() {
m.Cmdy(INSTALL, web.DOWNLOAD, kit.Format("%s/go%s.%s-%s.%s", m.Option(SERVICE), m.Option(VERSION), runtime.GOOS, runtime.GOARCH, kit.Select("tar.gz", "zip", runtime.GOOS == cli.WINDOWS)), ice.USR_LOCAL) m.Cmdy(INSTALL, web.DOWNLOAD, kit.Format("%s/go%s.%s-%s.%s", m.Option(SERVICE), m.Option(VERSION), runtime.GOOS, runtime.GOARCH, kit.Select("tar.gz", "zip", runtime.GOOS == cli.WINDOWS)), ice.USR_LOCAL)
}}, }},
web.DREAM_TABLES: {Hand: func(m *ice.Message, arg ...string) { web.DREAM_TABLES: {Hand: func(m *ice.Message, arg ...string) {
kit.If(m.Option(mdb.TYPE) == web.WORKER, func() { kit.If(m.Option(mdb.TYPE) == web.WORKER && nfs.Exists(m, path.Join(ice.USR_LOCAL_WORK, m.Option(mdb.NAME), ice.SRC_MAIN_GO)), func() {
kit.If(nfs.Exists(m, path.Join(ice.USR_LOCAL_WORK, m.Option(mdb.NAME), ice.SRC_MAIN_GO)), func() { kit.If(cli.SystemFind(m, GO), func() { m.PushButton(kit.Dict(m.CommandKey(), "构建")) })
kit.If(cli.SystemFind(m, GO), func() { m.PushButton(kit.Dict(m.CommandKey(), "构建")) })
})
}) })
}}, }},
web.DREAM_ACTION: {Hand: func(m *ice.Message, arg ...string) { web.DreamProcess(m, nil, arg...) }}, web.DREAM_ACTION: {Hand: func(m *ice.Message, arg ...string) { web.DreamProcess(m, nil, arg...) }},

View File

@ -42,9 +42,7 @@ func init() {
m.Option(ice.EXIT, ice.TRUE) m.Option(ice.EXIT, ice.TRUE)
} }
uri := "/publish/" + kit.Format(value[nfs.FILE]) uri := "/publish/" + kit.Format(value[nfs.FILE])
kit.If(os.Getenv(cli.CTX_POD), func(p string) { kit.If(m.Spawn().ParseLink(ice.Info.Domain).Option(ice.MSG_USERPOD), func(p string) { uri = kit.MergeURL(uri, ice.POD, p) })
uri = kit.MergeURL2(os.Getenv(cli.CTX_DEV), web.S(p), cli.GOOS, runtime.GOOS, cli.GOARCH, runtime.GOARCH)
})
dir := path.Join(kit.Format(value[nfs.PATH]), kit.Format(value[nfs.FILE])) dir := path.Join(kit.Format(value[nfs.PATH]), kit.Format(value[nfs.FILE]))
web.GoToast(m, m.PrefixKey(), func(toast func(name string, count, total int)) []string { web.GoToast(m, m.PrefixKey(), func(toast func(name string, count, total int)) []string {
switch web.SpideSave(m, dir, uri, func(count, total, value int) { switch web.SpideSave(m, dir, uri, func(count, total, value int) {