mirror of
https://shylinux.com/x/ContextOS
synced 2025-04-25 08:48:06 +08:00
add some
Change-Id: Ibb06a87e299b177b8221ea4ffe2f951fa3274e09
This commit is contained in:
parent
cc12c2595d
commit
e8a1693321
2
Makefile
2
Makefile
@ -7,7 +7,7 @@ install:
|
||||
@go get github.com/skip2/go-qrcode
|
||||
@go get github.com/gomarkdown/markdown
|
||||
@go get github.com/PuerkitoBio/goquery
|
||||
go install $(BENCH)
|
||||
GOPATH=$(PWD):$(GOPATH) go install $(BENCH)
|
||||
@date
|
||||
# bench web.code.counter nmake 1
|
||||
|
||||
|
@ -863,8 +863,9 @@ var Index = &ctx.Context{Name: "web", Help: "应用中心",
|
||||
if key == "" {
|
||||
key = m.Sess("aaa").Cmd("md5", m.Option("remote_addr"), create_time).Result(0)
|
||||
}
|
||||
|
||||
link := fmt.Sprintf("%s?bench=%s", m.Conf("site"), key)
|
||||
if _, ok := m.Confv("bench").(map[string]interface{}); !ok {
|
||||
if _, ok := m.Confv("bench", key).(map[string]interface{}); !ok {
|
||||
m.Log("info", "%s create bench %s", m.Option("username"), key)
|
||||
m.Confv("bench", key, map[string]interface{}{
|
||||
"remote_addr": m.Option("remote_addr"),
|
||||
@ -884,8 +885,8 @@ var Index = &ctx.Context{Name: "web", Help: "应用中心",
|
||||
return
|
||||
}
|
||||
|
||||
bench := m.Confv("bench").(map[string]interface{})
|
||||
if len(arg) > 0 && arg[0] == "check" { // 检查工作流
|
||||
bench := m.Confv("bench", m.Option("bench")).(map[string]interface{})
|
||||
if bench["creator"].(string) != arg[1] {
|
||||
switch bench["share"].(string) {
|
||||
case "private":
|
||||
@ -899,6 +900,7 @@ var Index = &ctx.Context{Name: "web", Help: "应用中心",
|
||||
return
|
||||
}
|
||||
|
||||
bench := m.Confv("bench").(map[string]interface{})
|
||||
if len(arg) > 0 && arg[0] == "delete" { // 删除工作流
|
||||
delete(bench, arg[1])
|
||||
arg = arg[2:]
|
||||
|
Loading…
x
Reference in New Issue
Block a user