mirror of
https://shylinux.com/x/ContextOS
synced 2025-04-25 16:58:06 +08:00
mod web.componet.share
This commit is contained in:
parent
29f3442ac0
commit
454babbcf2
@ -680,6 +680,15 @@ var Index = &ctx.Context{Name: "aaa", Help: "认证中心",
|
||||
"username": kit.Select("", arg, 2),
|
||||
"count": kit.Select("1", arg, 3),
|
||||
})
|
||||
case "count":
|
||||
if len(arg) == 1 {
|
||||
m.Cmdy("aaa.auth", "relay")
|
||||
return
|
||||
}
|
||||
m.Conf("auth", []string{arg[1], "data", "count"}, kit.Select("1", arg, 2))
|
||||
m.Cmdy("ctx.config", "auth", arg[1])
|
||||
default:
|
||||
m.Cmdy("ctx.config", "auth", arg[0])
|
||||
}
|
||||
return
|
||||
}},
|
||||
@ -746,8 +755,8 @@ var Index = &ctx.Context{Name: "aaa", Help: "认证中心",
|
||||
|
||||
// 生成证书
|
||||
template := x509.Certificate{
|
||||
SerialNumber: big.NewInt(1),
|
||||
IsCA: true,
|
||||
SerialNumber: big.NewInt(1),
|
||||
IsCA: true,
|
||||
BasicConstraintsValid: true,
|
||||
KeyUsage: x509.KeyUsageCertSign,
|
||||
Subject: pkix.Name{CommonName: kit.Format(common)},
|
||||
|
@ -860,7 +860,7 @@ var Index = &ctx.Context{Name: "web", Help: "应用中心",
|
||||
"componet": &ctx.Command{Name: "componet [group [order [arg...]]]", Help: "添加组件, group: 组件分组, arg...: 组件参数", Hand: func(m *ctx.Message, c *ctx.Context, key string, arg ...string) (e error) {
|
||||
if len(arg) > 0 && arg[0] == "share" {
|
||||
m.Cmd("aaa.role", arg[1], "componet", arg[2], "command", arg[3:])
|
||||
m.Echo("%s/?componet_group=%s&relay=%s", m.Conf("serve", "site"), arg[2], m.Cmdx("aaa.relay", "share", arg[1]))
|
||||
m.Echo("%s%s?componet_group=%s&relay=%s", m.Conf("serve", "site"), m.Option("index_path"), arg[2], m.Cmdx("aaa.relay", "share", arg[1], "temp"))
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user