diff --git a/base/web/dream.go b/base/web/dream.go index 7cc2e655..556993b6 100644 --- a/base/web/dream.go +++ b/base/web/dream.go @@ -423,6 +423,15 @@ func init() { m.Cmd(SPACE, m.Option(mdb.NAME), SPIDE, DEV_CREATE_TOKEN, ice.Maps{CLIENT_NAME: ice.DEV, TOKEN: token}) }}, OPEN: {Role: aaa.VOID, Hand: func(m *ice.Message, arg ...string) { + if kit.IsIn(m.Option(mdb.NAME), "20240724-community") || kit.HasPrefixList(arg, ctx.RUN) { + if !kit.HasPrefixList(arg, ctx.RUN) { + defer m.Push(TITLE, m.Option(mdb.NAME)) + defer m.Push("_width", "390") + defer m.Push("_height", "844") + } + ctx.ProcessFloat(m, CHAT_IFRAME, S(m.Option(mdb.NAME)), arg...) + return + } if m.Option(mdb.TYPE) == ORIGIN { m.ProcessOpen(SpideOrigin(m, m.Option(mdb.NAME))) } else if p := ProxyDomain(m, m.Option(mdb.NAME)); p != "" { diff --git a/base/web/serve.go b/base/web/serve.go index 23d63d31..05f3c97e 100644 --- a/base/web/serve.go +++ b/base/web/serve.go @@ -108,7 +108,7 @@ func _serve_static(msg *ice.Message, w http.ResponseWriter, r *http.Request) boo return false } p := path.Join(strings.TrimPrefix(r.URL.Path, nfs.P)) - if pp := path.Join(nfs.USR_LOCAL_WORK, msg.Option(ice.POD)); ispod && nfs.Exists(msg, pp) { + if pp := path.Join(nfs.USR_LOCAL_WORK, msg.Option(ice.POD)); ispod && nfs.Exists(msg, pp) && !strings.HasPrefix(p, "require/") { if kit.HasPrefix(p, "var/", "usr/local/") { return false } diff --git a/base/web/space.go b/base/web/space.go index fc8013bb..3d7e57bb 100644 --- a/base/web/space.go +++ b/base/web/space.go @@ -304,6 +304,10 @@ const SPACE = "space" func init() { Index.MergeCommands(ice.Commands{ "p": {Help: "资源", Actions: ApiWhiteAction(), Hand: func(m *ice.Message, arg ...string) { + if arg[0] == "require" { + m.Cmdy("/require/", arg[1:]) + return + } if kit.IsIn(arg[0], ice.SRC, ice.USR) { ShareLocalFile(m, arg...) } else { diff --git a/base/web/store.go b/base/web/store.go index 4b394159..ff821eb6 100644 --- a/base/web/store.go +++ b/base/web/store.go @@ -98,9 +98,9 @@ func init() { list := m.Spawn(ice.Maps{ice.MSG_FIELDS: ""}).CmdMap(SPACE, mdb.NAME) m.SetAppend().Spawn().SplitIndex(m.Cmdx(SPIDE, arg[0], dream, kit.Dict(mdb.ConfigSimple(m, CLIENT_TIMEOUT)))).Table(func(value ice.Maps) { stat[value[mdb.TYPE]]++ - if value[nfs.BINARY] == "" { - value[nfs.BINARY] = origin + S(value[mdb.NAME]) - } + // if value[nfs.BINARY] == "" { + value[nfs.BINARY] = origin + S(value[mdb.NAME]) + // } m.Push("", value, kit.Split("time,type,name,icons,repos,binary,module,version")) if _, ok := list[value[mdb.NAME]]; ok { m.Push("exists", ice.TRUE)