Browse Source

多域名

master
huangjiajun 13 hours ago
parent
commit
33dc26ae2a
5 changed files with 14 additions and 2 deletions
  1. +4
    -1
      app/hdl/setCenter/web/hdl_basic.go
  2. +2
    -1
      app/md/setCenter/md_web.go
  3. +3
    -0
      docs/docs.go
  4. +3
    -0
      docs/swagger.json
  5. +2
    -0
      docs/swagger.yaml

+ 4
- 1
app/hdl/setCenter/web/hdl_basic.go View File

@@ -85,10 +85,12 @@ func SetBasic(c *gin.Context) {
// @Router /api/settCenter/web/getDownDomainBasic [get] // @Router /api/settCenter/web/getDownDomainBasic [get]
func GetDownDomainBasic(c *gin.Context) { func GetDownDomainBasic(c *gin.Context) {
domain := svc.GetSysCfgStr("down_web_domain") domain := svc.GetSysCfgStr("down_web_domain")
downWebOpen := svc.GetSysCfgStr("down_web_open")
var tmp = make([]string, 0) var tmp = make([]string, 0)
json.Unmarshal([]byte(domain), &tmp) json.Unmarshal([]byte(domain), &tmp)
resp := setCenter.WebDomainBasicReq{ resp := setCenter.WebDomainBasicReq{
WebDomain: tmp,
WebDomain: tmp,
DownWebOpen: downWebOpen,
} }
e.OutSuc(c, resp, nil) e.OutSuc(c, resp, nil)
} }
@@ -111,6 +113,7 @@ func SetDownDomainBasic(c *gin.Context) {
return return
} }
svc.SetSysCfgStr("down_web_domain", utils.SerializeStr(req.WebDomain)) svc.SetSysCfgStr("down_web_domain", utils.SerializeStr(req.WebDomain))
svc.SetSysCfgStr("down_web_open", req.DownWebOpen)
e.OutSuc(c, "success", nil) e.OutSuc(c, "success", nil)
return return
} }


+ 2
- 1
app/md/setCenter/md_web.go View File

@@ -25,5 +25,6 @@ type KuaizhanBasicReq struct {
KuaizhanUrl string `json:"kuaizhan_url"` KuaizhanUrl string `json:"kuaizhan_url"`
} }
type WebDomainBasicReq struct { type WebDomainBasicReq struct {
WebDomain []string `json:"web_domain"`
WebDomain []string `json:"web_domain"`
DownWebOpen string `json:"down_web_open"`
} }

+ 3
- 0
docs/docs.go View File

@@ -17574,6 +17574,9 @@ const docTemplate = `{
"setCenter.WebDomainBasicReq": { "setCenter.WebDomainBasicReq": {
"type": "object", "type": "object",
"properties": { "properties": {
"down_web_open": {
"type": "string"
},
"web_domain": { "web_domain": {
"type": "array", "type": "array",
"items": { "items": {


+ 3
- 0
docs/swagger.json View File

@@ -17566,6 +17566,9 @@
"setCenter.WebDomainBasicReq": { "setCenter.WebDomainBasicReq": {
"type": "object", "type": "object",
"properties": { "properties": {
"down_web_open": {
"type": "string"
},
"web_domain": { "web_domain": {
"type": "array", "type": "array",
"items": { "items": {


+ 2
- 0
docs/swagger.yaml View File

@@ -5473,6 +5473,8 @@ definitions:
type: object type: object
setCenter.WebDomainBasicReq: setCenter.WebDomainBasicReq:
properties: properties:
down_web_open:
type: string
web_domain: web_domain:
items: items:
type: string type: string


Loading…
Cancel
Save