huangjiajun пре 3 месеци
родитељ
комит
8415a1e76a
12 измењених фајлова са 1998 додато и 302 уклоњено
  1. +4
    -4
      app/hdl/hdl_agent_qualification.go
  2. +5
    -4
      app/hdl/hdl_medium_qualification.go
  3. +1
    -1
      app/hdl/hdl_role.go
  4. +6
    -0
      app/md/comm.go
  5. +74
    -3
      app/md/md_agent_qualification.go
  6. +74
    -3
      app/md/md_medium_qualification.go
  7. +98
    -99
      app/svc/svc_agent_qualification.go
  8. +99
    -99
      app/svc/svc_medium_qualification.go
  9. +601
    -29
      docs/docs.go
  10. +601
    -29
      docs/swagger.json
  11. +432
    -30
      docs/swagger.yaml
  12. +3
    -1
      go.mod

+ 4
- 4
app/hdl/hdl_agent_qualification.go Прегледај датотеку

@@ -16,7 +16,7 @@ import (
// @Accept json
// @Produce json
// @Param args body md.AgentQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.AgentQualificationEnterpriseRes "具体看返回内容 这是data里面的数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/agentQualification/enterprise [POST]
func AgentQualificationEnterprise(c *gin.Context) {
@@ -70,7 +70,7 @@ func AgentQualificationEnterpriseAudit(c *gin.Context) {
// @Accept json
// @Produce json
// @Param args body md.AgentQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.AgentQualificationBankRes "具体看返回内容 这是data里面的数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/agentQualification/bank [POST]
func AgentQualificationBank(c *gin.Context) {
@@ -124,7 +124,7 @@ func AgentQualificationBankAudit(c *gin.Context) {
// @Accept json
// @Produce json
// @Param args body md.AgentQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.AgentQualificationContactRes "具体看返回内容 这是data里面的数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/agentQualification/contact [POST]
func AgentQualificationContactInfo(c *gin.Context) {
@@ -151,7 +151,7 @@ func AgentQualificationContactInfo(c *gin.Context) {
// @Param args body md.AgentQualificationEnterpriseAuditReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/agentQualification/enterprise/audit [POST]
// @Router /api/agentQualification/contact/audit [POST]
func AgentQualificationContactInfoAudit(c *gin.Context) {
var req md.AgentQualificationEnterpriseAuditReq
err := c.ShouldBindJSON(&req)


+ 5
- 4
app/hdl/hdl_medium_qualification.go Прегледај датотеку

@@ -16,7 +16,7 @@ import (
// @Accept json
// @Produce json
// @Param args body md.MediumQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.MediumQualificationEnterpriseRes "具体看返回内容 这是data里面的数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/mediumQualification/enterprise [POST]
func MediumQualificationEnterprise(c *gin.Context) {
@@ -70,7 +70,8 @@ func MediumQualificationEnterpriseAudit(c *gin.Context) {
// @Accept json
// @Produce json
// @Param args body md.MediumQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.MediumQualificationBankRes "具体看返回内容 这是data里面的数据"

// @Failure 400 {object} md.Response "具体错误"
// @Router /api/mediumQualification/bank [POST]
func MediumQualificationBank(c *gin.Context) {
@@ -124,7 +125,7 @@ func MediumQualificationBankAudit(c *gin.Context) {
// @Accept json
// @Produce json
// @Param args body md.MediumQualificationEnterpriseReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Success 200 {object} md.MediumQualificationContactRes "具体看返回内容 这是data里面的数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/mediumQualification/contact [POST]
func MediumQualificationContactInfo(c *gin.Context) {
@@ -151,7 +152,7 @@ func MediumQualificationContactInfo(c *gin.Context) {
// @Param args body md.MediumQualificationEnterpriseAuditReq true "请求参数"
// @Success 200 {string} "具体看返回内容"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/mediumQualification/enterprise/audit [POST]
// @Router /api/mediumQualification/contact/audit [POST]
func MediumQualificationContactInfoAudit(c *gin.Context) {
var req md.MediumQualificationEnterpriseAuditReq
err := c.ShouldBindJSON(&req)


+ 1
- 1
app/hdl/hdl_role.go Прегледај датотеку

@@ -280,7 +280,7 @@ func RoleBindPermissionGroup(c *gin.Context) {
// @Param args body md.UpdateRoleStateReq true "请求参数"
// @Success 200 {string} "success"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/role/updateRole [POST]
// @Router /api/role/updateRoleState [POST]
func UpdateRoleState(c *gin.Context) {
var req md.UpdateRoleStateReq
err := c.ShouldBindJSON(&req)


+ 6
- 0
app/md/comm.go Прегледај датотеку

@@ -0,0 +1,6 @@
package md

type SelectData struct {
Name string `json:"name" example:"名称"`
Value string `json:"value" example:"值"`
}

+ 74
- 3
app/md/md_agent_qualification.go Прегледај датотеку

@@ -1,13 +1,84 @@
package md

type AgentQualificationEnterpriseReq struct {
Limit int `json:"limit"`
Page int `json:"page" `
Limit string `json:"limit"`
Page string `json:"page" `
Name string `json:"name"`
State string `json:"state"`
}
type AgentQualificationEnterpriseAuditReq struct {
AgentId int `json:"agent_id"`
AgentId string `json:"agent_id"`
State string `json:"state"`
Memo string `json:"memo"`
}

type AgentQualificationEnterpriseRes struct {
List []AgentQualificationEnterpriseData `json:"list" `
State []SelectData `json:"state" `
Type []SelectData `json:"type" `
Total int64 `json:"total"`
}

type AgentQualificationEnterpriseData struct {
Id string `json:"id" example:"状态选择"`
Uuid string `json:"uuid" example:"站长id"`
AgentId string `json:"agent_id" example:"代理id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
CertificateType string `json:"certificate_type" example:"证件类型 2级类目id"`
CertificateFirstType string `json:"certificate_first_type" example:"证件类型 1级类目id"`
CountryRegionId string `json:"country_region_id" example:"国家地区id"`
RegisteredAddressCountryId string `json:"registered_address_country_id" example:"注册地址-国家id"`
RegisteredAddressProvinceId string `json:"registered_address_province_id" example:"册地址-省份id"`
RegisteredAddressCityId string `json:"registered_address_city_id" example:"注册地址-市id"`
RegisteredAddressCountyId string `json:"registered_address_county_id" example:"注册地址-县/区id"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
CompanyName string `json:"company_name" example:"公司名称"`
CompanyAbbreviation string `json:"company_abbreviation" example:"公司简称"`
UnifiedSocialCreditCode string `json:"unified_social_credit_code" example:"统一社会信用代码"`
BusinessLicenseImgUrl string `json:"business_license_img_url" example:"营业执照照片"`
LegalRepresentative string `json:"legal_representative" example:"法定代表人"`
CountryRegion string `json:"country_region" example:"国家地区"`
RegisteredAddress string `json:"registered_address" example:"注册地址"`
BusinessLicenseAddress string `json:"business_license_address" example:"营业执照地址"`
CertificateValidity string `json:"certificate_validity" example:"证件有效期"`
Memo string `json:"memo" example:"备注 审核时填写的"`
}
type AgentQualificationBankRes struct {
State []SelectData `json:"state" `
Type []SelectData `json:"type" `
CurrencyConf []SelectData `json:"currency_conf"`
List []AgentQualificationBankData `json:"list"`
Total int64 `json:"total"`
}
type AgentQualificationBankData struct {
AgentId string `json:"agent_id" example:"代理id"`
Bank string `json:"bank" example:"开户银行"`
BankBranch string `json:"bank_branch" example:"开户银行分行"`
BankNo string `json:"bank_no" example:"银行卡号"`
CompanyName string `json:"company_name" example:"公司名称"`
CurrencyConf string `json:"currency_conf" example:"结算币种 0人民币"`
Id string `json:"id" example:"id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
Licence string `json:"licence" example:"开户许可证"`
Memo string `json:"memo" example:"备注 审核时填写的"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
UnifiedSocialCreditCode string `json:"unified_social_credit_code" example:"统一社会信用代码"`
}

type AgentQualificationContactRes struct {
State []SelectData `json:"state" `
List []AgentQualificationContactData `json:"list"`
Total int64 `json:"total"`
}
type AgentQualificationContactData struct {
Address string `json:"address" example:"联系地址"`
AgentId string `json:"agent_id" example:"代理id"`
CompanyName string `json:"company_name" example:"公司名称"`
Email string `json:"email" example:"邮箱地址"`
Id string `json:"id" example:"id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
Memo string `json:"memo" example:"备注 审核时填写的"`
Name string `json:"name" example:"联系人"`
Phone string `json:"phone" example:"联系电话"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
}

+ 74
- 3
app/md/md_medium_qualification.go Прегледај датотеку

@@ -1,13 +1,84 @@
package md

type MediumQualificationEnterpriseReq struct {
Limit int `json:"limit"`
Page int `json:"page" `
Limit string `json:"limit"`
Page string `json:"page" `
Name string `json:"name"`
State string `json:"state"`
}
type MediumQualificationEnterpriseAuditReq struct {
MediumId int `json:"medium_id"`
MediumId string `json:"medium_id"`
State string `json:"state"`
Memo string `json:"memo"`
}

type MediumQualificationEnterpriseRes struct {
List []MediumQualificationEnterpriseData `json:"list" `
State []SelectData `json:"state" `
Type []SelectData `json:"type" `
Total int64 `json:"total"`
}

type MediumQualificationEnterpriseData struct {
Id string `json:"id" example:"状态选择"`
Uuid string `json:"uuid" example:"站长id"`
MediumId string `json:"medium_id" example:"代理id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
CertificateType string `json:"certificate_type" example:"证件类型 2级类目id"`
CertificateFirstType string `json:"certificate_first_type" example:"证件类型 1级类目id"`
CountryRegionId string `json:"country_region_id" example:"国家地区id"`
RegisteredAddressCountryId string `json:"registered_address_country_id" example:"注册地址-国家id"`
RegisteredAddressProvinceId string `json:"registered_address_province_id" example:"册地址-省份id"`
RegisteredAddressCityId string `json:"registered_address_city_id" example:"注册地址-市id"`
RegisteredAddressCountyId string `json:"registered_address_county_id" example:"注册地址-县/区id"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
CompanyName string `json:"company_name" example:"公司名称"`
CompanyAbbreviation string `json:"company_abbreviation" example:"公司简称"`
UnifiedSocialCreditCode string `json:"unified_social_credit_code" example:"统一社会信用代码"`
BusinessLicenseImgUrl string `json:"business_license_img_url" example:"营业执照照片"`
LegalRepresentative string `json:"legal_representative" example:"法定代表人"`
CountryRegion string `json:"country_region" example:"国家地区"`
RegisteredAddress string `json:"registered_address" example:"注册地址"`
BusinessLicenseAddress string `json:"business_license_address" example:"营业执照地址"`
CertificateValidity string `json:"certificate_validity" example:"证件有效期"`
Memo string `json:"memo" example:"备注 审核时填写的"`
}
type MediumQualificationBankRes struct {
State []SelectData `json:"state" `
Type []SelectData `json:"type" `
CurrencyConf []SelectData `json:"currency_conf"`
List []MediumQualificationBankData `json:"list"`
Total int64 `json:"total"`
}
type MediumQualificationBankData struct {
MediumId string `json:"medium_id" example:"代理id"`
Bank string `json:"bank" example:"开户银行"`
BankBranch string `json:"bank_branch" example:"开户银行分行"`
BankNo string `json:"bank_no" example:"银行卡号"`
CompanyName string `json:"company_name" example:"公司名称"`
CurrencyConf string `json:"currency_conf" example:"结算币种 0人民币"`
Id string `json:"id" example:"id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
Licence string `json:"licence" example:"开户许可证"`
Memo string `json:"memo" example:"备注 审核时填写的"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
UnifiedSocialCreditCode string `json:"unified_social_credit_code" example:"统一社会信用代码"`
}

type MediumQualificationContactRes struct {
State []SelectData `json:"state" `
List []MediumQualificationContactData `json:"list"`
Total int64 `json:"total"`
}
type MediumQualificationContactData struct {
Address string `json:"address" example:"联系地址"`
MediumId string `json:"medium_id" example:"代理id"`
CompanyName string `json:"company_name" example:"公司名称"`
Email string `json:"email" example:"邮箱地址"`
Id string `json:"id" example:"id"`
Kind string `json:"kind" example:"类型(1:企业 2:个人)"`
Memo string `json:"memo" example:"备注 审核时填写的"`
Name string `json:"name" example:"联系人"`
Phone string `json:"phone" example:"联系电话"`
State string `json:"state" example:"状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"`
}

+ 98
- 99
app/svc/svc_agent_qualification.go Прегледај датотеку

@@ -7,49 +7,60 @@ import (
"applet/app/utils"
db "code.fnuoos.com/zhimeng/model.git/src"
"code.fnuoos.com/zhimeng/model.git/src/super/implement"
"code.fnuoos.com/zhimeng/model.git/src/super/model"
"github.com/gin-gonic/gin"
"github.com/jinzhu/copier"
)

func AgentQualificationEnterprise(c *gin.Context, req md.AgentQualificationEnterpriseReq) map[string]interface{} {
if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
func AgentQualificationEnterprise(c *gin.Context, req md.AgentQualificationEnterpriseReq) md.AgentQualificationEnterpriseRes {

engine := db.Db
agentListDb := implement.NewAgentListDb(engine)
agentList, total, _ := agentListDb.FindAgentList(req.Name, req.State, req.Page, req.Limit)

if len(agentList) == 0 {
agentList = make([]model.AgentList, 0)
agentList, total, _ := agentListDb.FindAgentList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))
data := make([]md.AgentQualificationEnterpriseData, 0)
if len(agentList) > 0 {
for _, v := range agentList {
var tmp md.AgentQualificationEnterpriseData
copier.Copy(&tmp, &v)
tmp.Id = utils.IntToStr(v.Id)
tmp.Uuid = utils.IntToStr(v.Uuid)
tmp.AgentId = utils.IntToStr(v.AgentId)
tmp.Kind = utils.IntToStr(v.Kind)
tmp.CertificateType = utils.IntToStr(v.CertificateType)
tmp.CertificateFirstType = utils.IntToStr(v.CertificateFirstType)
tmp.CountryRegionId = utils.IntToStr(v.CountryRegionId)
tmp.RegisteredAddressCountryId = utils.IntToStr(v.RegisteredAddressCountryId)
tmp.RegisteredAddressProvinceId = utils.IntToStr(v.RegisteredAddressProvinceId)
tmp.RegisteredAddressCityId = utils.IntToStr(v.RegisteredAddressCityId)
tmp.RegisteredAddressCountyId = utils.IntToStr(v.RegisteredAddressCountyId)
tmp.State = utils.IntToStr(v.State)
data = append(data, tmp)
}
}
res := map[string]interface{}{
"list": agentList,
"total": total,
"state": []map[string]interface{}{
res := md.AgentQualificationEnterpriseRes{
List: data,
Total: total,
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
"type": []map[string]interface{}{
Type: []md.SelectData{
{
"name": enum.QualificationType(enum.QualificationTypeCompany).String(),
"value": enum.QualificationTypeCompany,
Name: enum.QualificationType(enum.QualificationTypeCompany).String(),
Value: utils.IntToStr(enum.QualificationTypeCompany),
},
{
"name": enum.QualificationType(enum.QualificationTypeOwn).String(),
"value": enum.QualificationTypeOwn,
Name: enum.QualificationType(enum.QualificationTypeOwn).String(),
Value: utils.IntToStr(enum.QualificationTypeOwn),
},
},
}
@@ -59,7 +70,7 @@ func AgentQualificationEnterprise(c *gin.Context, req md.AgentQualificationEnter
func AgentQualificationEnterpriseAudit(c *gin.Context, req md.AgentQualificationEnterpriseAuditReq) error {
engine := db.Db
agentListDb := implement.NewAgentListDb(engine)
data, _ := agentListDb.GetAgentList(req.AgentId)
data, _ := agentListDb.GetAgentList(utils.StrToInt(req.AgentId))
if data == nil {
return e.NewErr(400, "记录不存在")
}
@@ -72,67 +83,61 @@ func AgentQualificationEnterpriseAudit(c *gin.Context, req md.AgentQualification
return nil
}

func AgentQualificationBank(c *gin.Context, req md.AgentQualificationEnterpriseReq) map[string]interface{} {
if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
func AgentQualificationBank(c *gin.Context, req md.AgentQualificationEnterpriseReq) md.AgentQualificationBankRes {
engine := db.Db
agentListDb := implement.NewAgentBankInfoDb(engine)
agentList, total, _ := agentListDb.FindAgentBankInfoList(req.Name, req.State, req.Page, req.Limit)
agentList, total, _ := agentListDb.FindAgentBankInfoList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))

list := make([]map[string]string, 0)
list := make([]md.AgentQualificationBankData, 0)
if agentList != nil {
for _, v := range agentList {
tmp := map[string]string{
"id": utils.IntToStr(v.AgentBankInfo.Id),
"agent_id": utils.IntToStr(v.AgentBankInfo.AgentId),
"company_name": v.CompanyName,
"unified_social_credit_code": v.UnifiedSocialCreditCode,
"kind": utils.IntToStr(v.Kind),
"state": utils.IntToStr(v.AgentBankInfo.State),
"memo": v.AgentBankInfo.Memo,
"currency_conf": utils.IntToStr(v.CurrencyConf),
"bank": v.Bank,
"bank_branch": v.BankBranch,
"bank_no": v.BankNo,
"licence": v.Licence,
tmp := md.AgentQualificationBankData{
Id: utils.IntToStr(v.AgentBankInfo.Id),
AgentId: utils.IntToStr(v.AgentBankInfo.AgentId),
CompanyName: v.CompanyName,
UnifiedSocialCreditCode: v.UnifiedSocialCreditCode,
Kind: utils.IntToStr(v.Kind),
State: utils.IntToStr(v.AgentBankInfo.State),
Memo: v.AgentBankInfo.Memo,
CurrencyConf: utils.IntToStr(v.CurrencyConf),
Bank: v.Bank,
BankBranch: v.BankBranch,
BankNo: v.BankNo,
Licence: v.Licence,
}
list = append(list, tmp)
}
}
res := map[string]interface{}{
"list": list,
"total": total,
"currency_conf": []map[string]interface{}{
res := md.AgentQualificationBankRes{
List: list,
Total: total,
CurrencyConf: []md.SelectData{
{
"id": "1", "name": "人民币",
Value: "0", Name: "人民币",
},
},
"state": []map[string]interface{}{
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
"type": []map[string]interface{}{
Type: []md.SelectData{
{
"name": enum.QualificationType(enum.QualificationTypeCompany).String(),
"value": enum.QualificationTypeCompany,
Name: enum.QualificationType(enum.QualificationTypeCompany).String(),
Value: utils.IntToStr(enum.QualificationTypeCompany),
},
{
"name": enum.QualificationType(enum.QualificationTypeOwn).String(),
"value": enum.QualificationTypeOwn,
Name: enum.QualificationType(enum.QualificationTypeOwn).String(),
Value: utils.IntToStr(enum.QualificationTypeOwn),
},
},
}
@@ -141,7 +146,7 @@ func AgentQualificationBank(c *gin.Context, req md.AgentQualificationEnterpriseR
func AgentQualificationBankAudit(c *gin.Context, req md.AgentQualificationEnterpriseAuditReq) error {
engine := db.Db
agentListDb := implement.NewAgentBankInfoDb(engine)
data, _ := agentListDb.GetAgentBankInfoList(req.AgentId)
data, _ := agentListDb.GetAgentBankInfoList(utils.StrToInt(req.AgentId))
if data == nil {
return e.NewErr(400, "记录不存在")
}
@@ -154,50 +159,44 @@ func AgentQualificationBankAudit(c *gin.Context, req md.AgentQualificationEnterp
return nil
}

func AgentQualificationContactInfo(c *gin.Context, req md.AgentQualificationEnterpriseReq) map[string]interface{} {
if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
func AgentQualificationContactInfo(c *gin.Context, req md.AgentQualificationEnterpriseReq) md.AgentQualificationContactRes {
engine := db.Db
agentListDb := implement.NewAgentContactInfoDb(engine)
agentList, total, _ := agentListDb.FindAgentContactInfoList(req.Name, req.State, req.Page, req.Limit)
agentList, total, _ := agentListDb.FindAgentContactInfoList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))

list := make([]map[string]string, 0)
list := make([]md.AgentQualificationContactData, 0)
if agentList != nil {
for _, v := range agentList {
tmp := map[string]string{
"id": utils.IntToStr(v.AgentContactInfo.Id),
"agent_id": utils.IntToStr(v.AgentContactInfo.AgentId),
"company_name": v.CompanyName,
"kind": utils.IntToStr(v.Kind),
"state": utils.IntToStr(v.AgentContactInfo.State),
"memo": v.AgentContactInfo.Memo,
"name": v.AgentContactInfo.Name,
"email": v.AgentContactInfo.Email,
"phone": v.AgentContactInfo.Phone,
"address": v.AgentContactInfo.Address,
tmp := md.AgentQualificationContactData{
Id: utils.IntToStr(v.AgentContactInfo.Id),
AgentId: utils.IntToStr(v.AgentContactInfo.AgentId),
CompanyName: v.CompanyName,
Kind: utils.IntToStr(v.Kind),
State: utils.IntToStr(v.AgentContactInfo.State),
Memo: v.AgentContactInfo.Memo,
Name: v.AgentContactInfo.Name,
Email: v.AgentContactInfo.Email,
Phone: v.AgentContactInfo.Phone,
Address: v.AgentContactInfo.Address,
}
list = append(list, tmp)
}
}
res := map[string]interface{}{
"list": list,
"total": total,
"state": []map[string]interface{}{
res := md.AgentQualificationContactRes{
List: list,
Total: total,
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
}
@@ -206,7 +205,7 @@ func AgentQualificationContactInfo(c *gin.Context, req md.AgentQualificationEnte
func AgentQualificationContactInfoAudit(c *gin.Context, req md.AgentQualificationEnterpriseAuditReq) error {
engine := db.Db
agentListDb := implement.NewAgentContactInfoDb(engine)
data, _ := agentListDb.GetAgentContactInfoList(req.AgentId)
data, _ := agentListDb.GetAgentContactInfoList(utils.StrToInt(req.AgentId))
if data == nil {
return e.NewErr(400, "记录不存在")
}


+ 99
- 99
app/svc/svc_medium_qualification.go Прегледај датотеку

@@ -7,49 +7,60 @@ import (
"applet/app/utils"
db "code.fnuoos.com/zhimeng/model.git/src"
"code.fnuoos.com/zhimeng/model.git/src/super/implement"
"code.fnuoos.com/zhimeng/model.git/src/super/model"
"github.com/gin-gonic/gin"
"github.com/jinzhu/copier"
)

func MediumQualificationEnterprise(c *gin.Context, req md.MediumQualificationEnterpriseReq) map[string]interface{} {
func MediumQualificationEnterprise(c *gin.Context, req md.MediumQualificationEnterpriseReq) md.MediumQualificationEnterpriseRes {

if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
engine := db.Db
MediumListDb := implement.NewMediumListDb(engine)
MediumList, total, _ := MediumListDb.FindMediumList(req.Name, req.State, req.Page, req.Limit)
if len(MediumList) == 0 {
MediumList = make([]model.MediumList, 0)
MediumList, total, _ := MediumListDb.FindMediumList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))
data := make([]md.MediumQualificationEnterpriseData, 0)
if len(MediumList) > 0 {
for _, v := range MediumList {
var tmp md.MediumQualificationEnterpriseData
copier.Copy(&tmp, &v)
tmp.Id = utils.IntToStr(v.Id)
tmp.Uuid = utils.IntToStr(v.Uuid)
tmp.MediumId = utils.IntToStr(v.MediumId)
tmp.Kind = utils.IntToStr(v.Kind)
tmp.CertificateType = utils.IntToStr(v.CertificateType)
tmp.CertificateFirstType = utils.IntToStr(v.CertificateFirstType)
tmp.CountryRegionId = utils.IntToStr(v.CountryRegionId)
tmp.RegisteredAddressCountryId = utils.IntToStr(v.RegisteredAddressCountryId)
tmp.RegisteredAddressProvinceId = utils.IntToStr(v.RegisteredAddressProvinceId)
tmp.RegisteredAddressCityId = utils.IntToStr(v.RegisteredAddressCityId)
tmp.RegisteredAddressCountyId = utils.IntToStr(v.RegisteredAddressCountyId)
tmp.State = utils.IntToStr(v.State)
data = append(data, tmp)
}
}
res := map[string]interface{}{
"list": MediumList,
"total": total,
"state": []map[string]interface{}{
res := md.MediumQualificationEnterpriseRes{
List: data,
Total: total,
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
"type": []map[string]interface{}{
Type: []md.SelectData{
{
"name": enum.QualificationType(enum.QualificationTypeCompany).String(),
"value": enum.QualificationTypeCompany,
Name: enum.QualificationType(enum.QualificationTypeCompany).String(),
Value: utils.IntToStr(enum.QualificationTypeCompany),
},
{
"name": enum.QualificationType(enum.QualificationTypeOwn).String(),
"value": enum.QualificationTypeOwn,
Name: enum.QualificationType(enum.QualificationTypeOwn).String(),
Value: utils.IntToStr(enum.QualificationTypeOwn),
},
},
}
@@ -59,7 +70,7 @@ func MediumQualificationEnterprise(c *gin.Context, req md.MediumQualificationEnt
func MediumQualificationEnterpriseAudit(c *gin.Context, req md.MediumQualificationEnterpriseAuditReq) error {
engine := db.Db
MediumListDb := implement.NewMediumListDb(engine)
data, _ := MediumListDb.GetMediumList(req.MediumId)
data, _ := MediumListDb.GetMediumList(utils.StrToInt(req.MediumId))
if data == nil {
return e.NewErr(400, "记录不存在")
}
@@ -68,71 +79,65 @@ func MediumQualificationEnterpriseAudit(c *gin.Context, req md.MediumQualificati
}
data.State = utils.StrToInt(req.State)
data.Memo = req.Memo
engine.Where("agent_id=?", data.MediumId).Cols("state,memo").Update(data)
engine.Where("medium_id=?", data.MediumId).Cols("state,memo").Update(data)
return nil
}

func MediumQualificationBank(c *gin.Context, req md.MediumQualificationEnterpriseReq) map[string]interface{} {
if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
func MediumQualificationBank(c *gin.Context, req md.MediumQualificationEnterpriseReq) md.MediumQualificationBankRes {
engine := db.Db
MediumListDb := implement.NewMediumBankInfoDb(engine)
MediumList, total, _ := MediumListDb.FindMediumBankInfoList(req.Name, req.State, req.Page, req.Limit)
MediumList, total, _ := MediumListDb.FindMediumBankInfoList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))

list := make([]map[string]string, 0)
list := make([]md.MediumQualificationBankData, 0)
if MediumList != nil {
for _, v := range MediumList {
tmp := map[string]string{
"id": utils.IntToStr(v.MediumBankInfo.Id),
"medium_id": utils.IntToStr(v.MediumBankInfo.MediumId),
"company_name": v.CompanyName,
"unified_social_credit_code": v.UnifiedSocialCreditCode,
"kind": utils.IntToStr(v.Kind),
"state": utils.IntToStr(v.MediumBankInfo.State),
"memo": v.MediumBankInfo.Memo,
"currency_conf": utils.IntToStr(v.CurrencyConf),
"bank": v.Bank,
"bank_branch": v.BankBranch,
"bank_no": v.BankNo,
"licence": v.Licence,
tmp := md.MediumQualificationBankData{
Id: utils.IntToStr(v.MediumBankInfo.Id),
MediumId: utils.IntToStr(v.MediumBankInfo.MediumId),
CompanyName: v.CompanyName,
UnifiedSocialCreditCode: v.UnifiedSocialCreditCode,
Kind: utils.IntToStr(v.Kind),
State: utils.IntToStr(v.MediumBankInfo.State),
Memo: v.MediumBankInfo.Memo,
CurrencyConf: utils.IntToStr(v.CurrencyConf),
Bank: v.Bank,
BankBranch: v.BankBranch,
BankNo: v.BankNo,
Licence: v.Licence,
}
list = append(list, tmp)
}
}
res := map[string]interface{}{
"list": list,
"total": total,
"currency_conf": []map[string]interface{}{
res := md.MediumQualificationBankRes{
List: list,
Total: total,
CurrencyConf: []md.SelectData{
{
"id": "1", "name": "人民币",
Value: "0", Name: "人民币",
},
},
"state": []map[string]interface{}{
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
"type": []map[string]interface{}{
Type: []md.SelectData{
{
"name": enum.QualificationType(enum.QualificationTypeCompany).String(),
"value": enum.QualificationTypeCompany,
Name: enum.QualificationType(enum.QualificationTypeCompany).String(),
Value: utils.IntToStr(enum.QualificationTypeCompany),
},
{
"name": enum.QualificationType(enum.QualificationTypeOwn).String(),
"value": enum.QualificationTypeOwn,
Name: enum.QualificationType(enum.QualificationTypeOwn).String(),
Value: utils.IntToStr(enum.QualificationTypeOwn),
},
},
}
@@ -141,7 +146,7 @@ func MediumQualificationBank(c *gin.Context, req md.MediumQualificationEnterpris
func MediumQualificationBankAudit(c *gin.Context, req md.MediumQualificationEnterpriseAuditReq) error {
engine := db.Db
MediumListDb := implement.NewMediumBankInfoDb(engine)
data, _ := MediumListDb.GetMediumBankInfoList(req.MediumId)
data, _ := MediumListDb.GetMediumBankInfoList(utils.StrToInt(req.MediumId))
if data == nil {
return e.NewErr(400, "记录不存在")
}
@@ -154,50 +159,45 @@ func MediumQualificationBankAudit(c *gin.Context, req md.MediumQualificationEnte
return nil
}

func MediumQualificationContactInfo(c *gin.Context, req md.MediumQualificationEnterpriseReq) map[string]interface{} {
if req.Limit == 0 {
req.Limit = 10
}
if req.Page == 0 {
req.Page = 1
}
func MediumQualificationContactInfo(c *gin.Context, req md.MediumQualificationEnterpriseReq) md.MediumQualificationContactRes {

engine := db.Db
MediumListDb := implement.NewMediumContactInfoDb(engine)
MediumList, total, _ := MediumListDb.FindMediumContactInfoList(req.Name, req.State, req.Page, req.Limit)
MediumList, total, _ := MediumListDb.FindMediumContactInfoList(req.Name, req.State, utils.StrToInt(req.Page), utils.StrToInt(req.Limit))

list := make([]map[string]string, 0)
list := make([]md.MediumQualificationContactData, 0)
if MediumList != nil {
for _, v := range MediumList {
tmp := map[string]string{
"id": utils.IntToStr(v.MediumContactInfo.Id),
"medium_id": utils.IntToStr(v.MediumContactInfo.MediumId),
"company_name": v.CompanyName,
"kind": utils.IntToStr(v.Kind),
"state": utils.IntToStr(v.MediumContactInfo.State),
"memo": v.MediumContactInfo.Memo,
"name": v.MediumContactInfo.Name,
"email": v.MediumContactInfo.Email,
"phone": v.MediumContactInfo.Phone,
"address": v.MediumContactInfo.Address,
tmp := md.MediumQualificationContactData{
Id: utils.IntToStr(v.MediumContactInfo.Id),
MediumId: utils.IntToStr(v.MediumContactInfo.MediumId),
CompanyName: v.CompanyName,
Kind: utils.IntToStr(v.Kind),
State: utils.IntToStr(v.MediumContactInfo.State),
Memo: v.MediumContactInfo.Memo,
Name: v.MediumContactInfo.Name,
Email: v.MediumContactInfo.Email,
Phone: v.MediumContactInfo.Phone,
Address: v.MediumContactInfo.Address,
}
list = append(list, tmp)
}
}
res := map[string]interface{}{
"list": list,
"total": total,
"state": []map[string]interface{}{
res := md.MediumQualificationContactRes{
List: list,
Total: total,
State: []md.SelectData{
{
"name": enum.QualificationState(enum.QualificationStateForWait).String(),
"value": enum.QualificationStateForWait,
Name: enum.QualificationState(enum.QualificationStateForWait).String(),
Value: utils.IntToStr(enum.QualificationStateForWait),
},
{
"name": enum.QualificationState(enum.QualificationStateForNormal).String(),
"value": enum.QualificationStateForNormal,
Name: enum.QualificationState(enum.QualificationStateForNormal).String(),
Value: utils.IntToStr(enum.QualificationStateForNormal),
},
{
"name": enum.QualificationState(enum.QualificationStateForFail).String(),
"value": enum.QualificationStateForFail,
Name: enum.QualificationState(enum.QualificationStateForFail).String(),
Value: utils.IntToStr(enum.QualificationStateForFail),
},
},
}
@@ -206,7 +206,7 @@ func MediumQualificationContactInfo(c *gin.Context, req md.MediumQualificationEn
func MediumQualificationContactInfoAudit(c *gin.Context, req md.MediumQualificationEnterpriseAuditReq) error {
engine := db.Db
MediumListDb := implement.NewMediumContactInfoDb(engine)
data, _ := MediumListDb.GetMediumContactInfoList(req.MediumId)
data, _ := MediumListDb.GetMediumContactInfoList(utils.StrToInt(req.MediumId))
if data == nil {
return e.NewErr(400, "记录不存在")
}


+ 601
- 29
docs/docs.go Прегледај датотеку

@@ -58,9 +58,9 @@ const docTemplate = `{
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.AgentQualificationBankRes"
}
},
"400": {
@@ -150,6 +150,53 @@ const docTemplate = `{
}
}
],
"responses": {
"200": {
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"$ref": "#/definitions/md.AgentQualificationContactRes"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/agentQualification/contact/audit": {
"post": {
"description": "渠道资质-联系方式审核",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"渠道资质------嘉俊"
],
"summary": "联系方式审核",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "请求参数",
"name": "args",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.AgentQualificationEnterpriseAuditReq"
}
}
],
"responses": {
"200": {
"description": "具体看返回内容",
@@ -199,9 +246,9 @@ const docTemplate = `{
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.AgentQualificationEnterpriseRes"
}
},
"400": {
@@ -215,7 +262,7 @@ const docTemplate = `{
},
"/api/agentQualification/enterprise/audit": {
"post": {
"description": "渠道资质-联系方式审核",
"description": "渠道资质-主体资质审核",
"consumes": [
"application/json"
],
@@ -225,7 +272,7 @@ const docTemplate = `{
"tags": [
"渠道资质------嘉俊"
],
"summary": "联系方式审核",
"summary": "主体资质审核",
"parameters": [
{
"type": "string",
@@ -302,7 +349,19 @@ const docTemplate = `{
},
"/api/mediumQualification/bank": {
"post": {
"description": "媒体资质-银行资质",
"responses": {
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/mediumQualification/bank/audit": {
"post": {
"description": "媒体资质-银行资质审核",
"consumes": [
"application/json"
],
@@ -312,7 +371,7 @@ const docTemplate = `{
"tags": [
"媒体资质------嘉俊"
],
"summary": "银行资质",
"summary": "银行资质审核",
"parameters": [
{
"type": "string",
@@ -327,7 +386,7 @@ const docTemplate = `{
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
}
}
],
@@ -347,9 +406,9 @@ const docTemplate = `{
}
}
},
"/api/mediumQualification/bank/audit": {
"/api/mediumQualification/contact": {
"post": {
"description": "媒体资质-银行资质审核",
"description": "媒体资质-联系方式",
"consumes": [
"application/json"
],
@@ -359,7 +418,7 @@ const docTemplate = `{
"tags": [
"媒体资质------嘉俊"
],
"summary": "银行资质审核",
"summary": "联系方式",
"parameters": [
{
"type": "string",
@@ -374,15 +433,15 @@ const docTemplate = `{
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
}
}
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.MediumQualificationContactRes"
}
},
"400": {
@@ -394,9 +453,9 @@ const docTemplate = `{
}
}
},
"/api/mediumQualification/contact": {
"/api/mediumQualification/contact/audit": {
"post": {
"description": "媒体资质-联系方式",
"description": "媒体资质-联系方式审核",
"consumes": [
"application/json"
],
@@ -406,7 +465,7 @@ const docTemplate = `{
"tags": [
"媒体资质------嘉俊"
],
"summary": "联系方式",
"summary": "联系方式审核",
"parameters": [
{
"type": "string",
@@ -421,7 +480,7 @@ const docTemplate = `{
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
}
}
],
@@ -474,9 +533,9 @@ const docTemplate = `{
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.MediumQualificationEnterpriseRes"
}
},
"400": {
@@ -490,7 +549,7 @@ const docTemplate = `{
},
"/api/mediumQualification/enterprise/audit": {
"post": {
"description": "媒体资质-联系方式审核",
"description": "媒体资质-主体资质审核",
"consumes": [
"application/json"
],
@@ -500,7 +559,7 @@ const docTemplate = `{
"tags": [
"媒体资质------嘉俊"
],
"summary": "联系方式审核",
"summary": "主体资质审核",
"parameters": [
{
"type": "string",
@@ -1113,6 +1172,53 @@ const docTemplate = `{
}
},
"/api/role/updateRole": {
"post": {
"description": "权限管理-修改角色",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"权限管理"
],
"summary": "修改角色",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "请求参数",
"name": "args",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.UpdateRoleReq"
}
}
],
"responses": {
"200": {
"description": "success",
"schema": {
"type": "string"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/role/updateRoleState": {
"post": {
"description": "权限管理-修改角色状态",
"consumes": [
@@ -1256,11 +1362,161 @@ const docTemplate = `{
}
}
},
"md.AgentQualificationEnterpriseAuditReq": {
"md.AgentQualificationBankData": {
"type": "object",
"properties": {
"agent_id": {
"type": "string",
"example": "代理id"
},
"bank": {
"type": "string",
"example": "开户银行"
},
"bank_branch": {
"type": "string",
"example": "开户银行分行"
},
"bank_no": {
"type": "string",
"example": "银行卡号"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"currency_conf": {
"type": "string",
"example": "结算币种 0人民币"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"licence": {
"type": "string",
"example": "开户许可证"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
}
}
},
"md.AgentQualificationBankRes": {
"type": "object",
"properties": {
"currency_conf": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationBankData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.AgentQualificationContactData": {
"type": "object",
"properties": {
"address": {
"type": "string",
"example": "联系地址"
},
"agent_id": {
"type": "string",
"example": "代理id"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"email": {
"type": "string",
"example": "邮箱地址"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"name": {
"type": "string",
"example": "联系人"
},
"phone": {
"type": "string",
"example": "联系电话"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
}
}
},
"md.AgentQualificationContactRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationContactData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
}
}
},
"md.AgentQualificationEnterpriseAuditReq": {
"type": "object",
"properties": {
"agent_id": {
"type": "string"
},
"memo": {
"type": "string"
@@ -1270,23 +1526,142 @@ const docTemplate = `{
}
}
},
"md.AgentQualificationEnterpriseData": {
"type": "object",
"properties": {
"agent_id": {
"type": "string",
"example": "代理id"
},
"business_license_address": {
"type": "string",
"example": "营业执照地址"
},
"business_license_img_url": {
"type": "string",
"example": "营业执照照片"
},
"certificate_first_type": {
"type": "string",
"example": "证件类型 1级类目id"
},
"certificate_type": {
"type": "string",
"example": "证件类型 2级类目id"
},
"certificate_validity": {
"type": "string",
"example": "证件有效期"
},
"company_abbreviation": {
"type": "string",
"example": "公司简称"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"country_region": {
"type": "string",
"example": "国家地区"
},
"country_region_id": {
"type": "string",
"example": "国家地区id"
},
"id": {
"type": "string",
"example": "状态选择"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"legal_representative": {
"type": "string",
"example": "法定代表人"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"registered_address": {
"type": "string",
"example": "注册地址"
},
"registered_address_city_id": {
"type": "string",
"example": "注册地址-市id"
},
"registered_address_country_id": {
"type": "string",
"example": "注册地址-国家id"
},
"registered_address_county_id": {
"type": "string",
"example": "注册地址-县/区id"
},
"registered_address_province_id": {
"type": "string",
"example": "册地址-省份id"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
},
"uuid": {
"type": "string",
"example": "站长id"
}
}
},
"md.AgentQualificationEnterpriseReq": {
"type": "object",
"properties": {
"limit": {
"type": "integer"
"type": "string"
},
"name": {
"type": "string"
},
"page": {
"type": "integer"
"type": "string"
},
"state": {
"type": "string"
}
}
},
"md.AgentQualificationEnterpriseRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationEnterpriseData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.BindAdminRoleReq": {
"type": "object",
"required": [
@@ -1333,11 +1708,76 @@ const docTemplate = `{
}
}
},
"md.MediumQualificationEnterpriseAuditReq": {
"md.MediumQualificationContactData": {
"type": "object",
"properties": {
"address": {
"type": "string",
"example": "联系地址"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"email": {
"type": "string",
"example": "邮箱地址"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"medium_id": {
"type": "string",
"example": "代理id"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"name": {
"type": "string",
"example": "联系人"
},
"phone": {
"type": "string",
"example": "联系电话"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
}
}
},
"md.MediumQualificationContactRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.MediumQualificationContactData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
}
}
},
"md.MediumQualificationEnterpriseAuditReq": {
"type": "object",
"properties": {
"medium_id": {
"type": "string"
},
"memo": {
"type": "string"
@@ -1347,23 +1787,142 @@ const docTemplate = `{
}
}
},
"md.MediumQualificationEnterpriseData": {
"type": "object",
"properties": {
"business_license_address": {
"type": "string",
"example": "营业执照地址"
},
"business_license_img_url": {
"type": "string",
"example": "营业执照照片"
},
"certificate_first_type": {
"type": "string",
"example": "证件类型 1级类目id"
},
"certificate_type": {
"type": "string",
"example": "证件类型 2级类目id"
},
"certificate_validity": {
"type": "string",
"example": "证件有效期"
},
"company_abbreviation": {
"type": "string",
"example": "公司简称"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"country_region": {
"type": "string",
"example": "国家地区"
},
"country_region_id": {
"type": "string",
"example": "国家地区id"
},
"id": {
"type": "string",
"example": "状态选择"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"legal_representative": {
"type": "string",
"example": "法定代表人"
},
"medium_id": {
"type": "string",
"example": "代理id"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"registered_address": {
"type": "string",
"example": "注册地址"
},
"registered_address_city_id": {
"type": "string",
"example": "注册地址-市id"
},
"registered_address_country_id": {
"type": "string",
"example": "注册地址-国家id"
},
"registered_address_county_id": {
"type": "string",
"example": "注册地址-县/区id"
},
"registered_address_province_id": {
"type": "string",
"example": "册地址-省份id"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
},
"uuid": {
"type": "string",
"example": "站长id"
}
}
},
"md.MediumQualificationEnterpriseReq": {
"type": "object",
"properties": {
"limit": {
"type": "integer"
"type": "string"
},
"name": {
"type": "string"
},
"page": {
"type": "integer"
"type": "string"
},
"state": {
"type": "string"
}
}
},
"md.MediumQualificationEnterpriseRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.RegisterForAgentReq": {
"type": "object",
"required": [
@@ -1439,6 +1998,19 @@ const docTemplate = `{
}
}
},
"md.SelectData": {
"type": "object",
"properties": {
"name": {
"type": "string",
"example": "名称"
},
"value": {
"type": "string",
"example": "值"
}
}
},
"md.UpdateAdminReq": {
"type": "object",
"required": [


+ 601
- 29
docs/swagger.json Прегледај датотеку

@@ -50,9 +50,9 @@
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.AgentQualificationBankRes"
}
},
"400": {
@@ -142,6 +142,53 @@
}
}
],
"responses": {
"200": {
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"$ref": "#/definitions/md.AgentQualificationContactRes"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/agentQualification/contact/audit": {
"post": {
"description": "渠道资质-联系方式审核",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"渠道资质------嘉俊"
],
"summary": "联系方式审核",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "请求参数",
"name": "args",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.AgentQualificationEnterpriseAuditReq"
}
}
],
"responses": {
"200": {
"description": "具体看返回内容",
@@ -191,9 +238,9 @@
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.AgentQualificationEnterpriseRes"
}
},
"400": {
@@ -207,7 +254,7 @@
},
"/api/agentQualification/enterprise/audit": {
"post": {
"description": "渠道资质-联系方式审核",
"description": "渠道资质-主体资质审核",
"consumes": [
"application/json"
],
@@ -217,7 +264,7 @@
"tags": [
"渠道资质------嘉俊"
],
"summary": "联系方式审核",
"summary": "主体资质审核",
"parameters": [
{
"type": "string",
@@ -294,7 +341,19 @@
},
"/api/mediumQualification/bank": {
"post": {
"description": "媒体资质-银行资质",
"responses": {
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/mediumQualification/bank/audit": {
"post": {
"description": "媒体资质-银行资质审核",
"consumes": [
"application/json"
],
@@ -304,7 +363,7 @@
"tags": [
"媒体资质------嘉俊"
],
"summary": "银行资质",
"summary": "银行资质审核",
"parameters": [
{
"type": "string",
@@ -319,7 +378,7 @@
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
}
}
],
@@ -339,9 +398,9 @@
}
}
},
"/api/mediumQualification/bank/audit": {
"/api/mediumQualification/contact": {
"post": {
"description": "媒体资质-银行资质审核",
"description": "媒体资质-联系方式",
"consumes": [
"application/json"
],
@@ -351,7 +410,7 @@
"tags": [
"媒体资质------嘉俊"
],
"summary": "银行资质审核",
"summary": "联系方式",
"parameters": [
{
"type": "string",
@@ -366,15 +425,15 @@
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
}
}
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.MediumQualificationContactRes"
}
},
"400": {
@@ -386,9 +445,9 @@
}
}
},
"/api/mediumQualification/contact": {
"/api/mediumQualification/contact/audit": {
"post": {
"description": "媒体资质-联系方式",
"description": "媒体资质-联系方式审核",
"consumes": [
"application/json"
],
@@ -398,7 +457,7 @@
"tags": [
"媒体资质------嘉俊"
],
"summary": "联系方式",
"summary": "联系方式审核",
"parameters": [
{
"type": "string",
@@ -413,7 +472,7 @@
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseReq"
"$ref": "#/definitions/md.MediumQualificationEnterpriseAuditReq"
}
}
],
@@ -466,9 +525,9 @@
],
"responses": {
"200": {
"description": "具体看返回内容",
"description": "具体看返回内容 这是data里面的数据",
"schema": {
"type": "string"
"$ref": "#/definitions/md.MediumQualificationEnterpriseRes"
}
},
"400": {
@@ -482,7 +541,7 @@
},
"/api/mediumQualification/enterprise/audit": {
"post": {
"description": "媒体资质-联系方式审核",
"description": "媒体资质-主体资质审核",
"consumes": [
"application/json"
],
@@ -492,7 +551,7 @@
"tags": [
"媒体资质------嘉俊"
],
"summary": "联系方式审核",
"summary": "主体资质审核",
"parameters": [
{
"type": "string",
@@ -1105,6 +1164,53 @@
}
},
"/api/role/updateRole": {
"post": {
"description": "权限管理-修改角色",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"权限管理"
],
"summary": "修改角色",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "请求参数",
"name": "args",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.UpdateRoleReq"
}
}
],
"responses": {
"200": {
"description": "success",
"schema": {
"type": "string"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/role/updateRoleState": {
"post": {
"description": "权限管理-修改角色状态",
"consumes": [
@@ -1248,11 +1354,161 @@
}
}
},
"md.AgentQualificationEnterpriseAuditReq": {
"md.AgentQualificationBankData": {
"type": "object",
"properties": {
"agent_id": {
"type": "string",
"example": "代理id"
},
"bank": {
"type": "string",
"example": "开户银行"
},
"bank_branch": {
"type": "string",
"example": "开户银行分行"
},
"bank_no": {
"type": "string",
"example": "银行卡号"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"currency_conf": {
"type": "string",
"example": "结算币种 0人民币"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"licence": {
"type": "string",
"example": "开户许可证"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
}
}
},
"md.AgentQualificationBankRes": {
"type": "object",
"properties": {
"currency_conf": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationBankData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.AgentQualificationContactData": {
"type": "object",
"properties": {
"address": {
"type": "string",
"example": "联系地址"
},
"agent_id": {
"type": "string",
"example": "代理id"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"email": {
"type": "string",
"example": "邮箱地址"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"name": {
"type": "string",
"example": "联系人"
},
"phone": {
"type": "string",
"example": "联系电话"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
}
}
},
"md.AgentQualificationContactRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationContactData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
}
}
},
"md.AgentQualificationEnterpriseAuditReq": {
"type": "object",
"properties": {
"agent_id": {
"type": "string"
},
"memo": {
"type": "string"
@@ -1262,23 +1518,142 @@
}
}
},
"md.AgentQualificationEnterpriseData": {
"type": "object",
"properties": {
"agent_id": {
"type": "string",
"example": "代理id"
},
"business_license_address": {
"type": "string",
"example": "营业执照地址"
},
"business_license_img_url": {
"type": "string",
"example": "营业执照照片"
},
"certificate_first_type": {
"type": "string",
"example": "证件类型 1级类目id"
},
"certificate_type": {
"type": "string",
"example": "证件类型 2级类目id"
},
"certificate_validity": {
"type": "string",
"example": "证件有效期"
},
"company_abbreviation": {
"type": "string",
"example": "公司简称"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"country_region": {
"type": "string",
"example": "国家地区"
},
"country_region_id": {
"type": "string",
"example": "国家地区id"
},
"id": {
"type": "string",
"example": "状态选择"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"legal_representative": {
"type": "string",
"example": "法定代表人"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"registered_address": {
"type": "string",
"example": "注册地址"
},
"registered_address_city_id": {
"type": "string",
"example": "注册地址-市id"
},
"registered_address_country_id": {
"type": "string",
"example": "注册地址-国家id"
},
"registered_address_county_id": {
"type": "string",
"example": "注册地址-县/区id"
},
"registered_address_province_id": {
"type": "string",
"example": "册地址-省份id"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
},
"uuid": {
"type": "string",
"example": "站长id"
}
}
},
"md.AgentQualificationEnterpriseReq": {
"type": "object",
"properties": {
"limit": {
"type": "integer"
"type": "string"
},
"name": {
"type": "string"
},
"page": {
"type": "integer"
"type": "string"
},
"state": {
"type": "string"
}
}
},
"md.AgentQualificationEnterpriseRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.AgentQualificationEnterpriseData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.BindAdminRoleReq": {
"type": "object",
"required": [
@@ -1325,11 +1700,76 @@
}
}
},
"md.MediumQualificationEnterpriseAuditReq": {
"md.MediumQualificationContactData": {
"type": "object",
"properties": {
"address": {
"type": "string",
"example": "联系地址"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"email": {
"type": "string",
"example": "邮箱地址"
},
"id": {
"type": "string",
"example": "id"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"medium_id": {
"type": "string",
"example": "代理id"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"name": {
"type": "string",
"example": "联系人"
},
"phone": {
"type": "string",
"example": "联系电话"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
}
}
},
"md.MediumQualificationContactRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.MediumQualificationContactData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
}
}
},
"md.MediumQualificationEnterpriseAuditReq": {
"type": "object",
"properties": {
"medium_id": {
"type": "string"
},
"memo": {
"type": "string"
@@ -1339,23 +1779,142 @@
}
}
},
"md.MediumQualificationEnterpriseData": {
"type": "object",
"properties": {
"business_license_address": {
"type": "string",
"example": "营业执照地址"
},
"business_license_img_url": {
"type": "string",
"example": "营业执照照片"
},
"certificate_first_type": {
"type": "string",
"example": "证件类型 1级类目id"
},
"certificate_type": {
"type": "string",
"example": "证件类型 2级类目id"
},
"certificate_validity": {
"type": "string",
"example": "证件有效期"
},
"company_abbreviation": {
"type": "string",
"example": "公司简称"
},
"company_name": {
"type": "string",
"example": "公司名称"
},
"country_region": {
"type": "string",
"example": "国家地区"
},
"country_region_id": {
"type": "string",
"example": "国家地区id"
},
"id": {
"type": "string",
"example": "状态选择"
},
"kind": {
"type": "string",
"example": "类型(1:企业 2:个人)"
},
"legal_representative": {
"type": "string",
"example": "法定代表人"
},
"medium_id": {
"type": "string",
"example": "代理id"
},
"memo": {
"type": "string",
"example": "备注 审核时填写的"
},
"registered_address": {
"type": "string",
"example": "注册地址"
},
"registered_address_city_id": {
"type": "string",
"example": "注册地址-市id"
},
"registered_address_country_id": {
"type": "string",
"example": "注册地址-国家id"
},
"registered_address_county_id": {
"type": "string",
"example": "注册地址-县/区id"
},
"registered_address_province_id": {
"type": "string",
"example": "册地址-省份id"
},
"state": {
"type": "string",
"example": "状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)"
},
"unified_social_credit_code": {
"type": "string",
"example": "统一社会信用代码"
},
"uuid": {
"type": "string",
"example": "站长id"
}
}
},
"md.MediumQualificationEnterpriseReq": {
"type": "object",
"properties": {
"limit": {
"type": "integer"
"type": "string"
},
"name": {
"type": "string"
},
"page": {
"type": "integer"
"type": "string"
},
"state": {
"type": "string"
}
}
},
"md.MediumQualificationEnterpriseRes": {
"type": "object",
"properties": {
"list": {
"type": "array",
"items": {
"$ref": "#/definitions/md.MediumQualificationEnterpriseData"
}
},
"state": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
},
"total": {
"type": "integer"
},
"type": {
"type": "array",
"items": {
"$ref": "#/definitions/md.SelectData"
}
}
}
},
"md.RegisterForAgentReq": {
"type": "object",
"required": [
@@ -1431,6 +1990,19 @@
}
}
},
"md.SelectData": {
"type": "object",
"properties": {
"name": {
"type": "string",
"example": "名称"
},
"value": {
"type": "string",
"example": "值"
}
}
},
"md.UpdateAdminReq": {
"type": "object",
"required": [


+ 432
- 30
docs/swagger.yaml Прегледај датотеку

@@ -32,26 +32,218 @@ definitions:
username:
type: string
type: object
md.AgentQualificationEnterpriseAuditReq:
md.AgentQualificationBankData:
properties:
agent_id:
example: 代理id
type: string
bank:
example: 开户银行
type: string
bank_branch:
example: 开户银行分行
type: string
bank_no:
example: 银行卡号
type: string
company_name:
example: 公司名称
type: string
currency_conf:
example: 结算币种 0人民币
type: string
id:
example: id
type: string
kind:
example: 类型(1:企业 2:个人)
type: string
licence:
example: 开户许可证
type: string
memo:
example: 备注 审核时填写的
type: string
state:
example: 状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)
type: string
unified_social_credit_code:
example: 统一社会信用代码
type: string
type: object
md.AgentQualificationBankRes:
properties:
currency_conf:
items:
$ref: '#/definitions/md.SelectData'
type: array
list:
items:
$ref: '#/definitions/md.AgentQualificationBankData'
type: array
state:
items:
$ref: '#/definitions/md.SelectData'
type: array
total:
type: integer
type:
items:
$ref: '#/definitions/md.SelectData'
type: array
type: object
md.AgentQualificationContactData:
properties:
address:
example: 联系地址
type: string
agent_id:
example: 代理id
type: string
company_name:
example: 公司名称
type: string
email:
example: 邮箱地址
type: string
id:
example: id
type: string
kind:
example: 类型(1:企业 2:个人)
type: string
memo:
example: 备注 审核时填写的
type: string
name:
example: 联系人
type: string
phone:
example: 联系电话
type: string
state:
example: 状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)
type: string
type: object
md.AgentQualificationContactRes:
properties:
list:
items:
$ref: '#/definitions/md.AgentQualificationContactData'
type: array
state:
items:
$ref: '#/definitions/md.SelectData'
type: array
total:
type: integer
type: object
md.AgentQualificationEnterpriseAuditReq:
properties:
agent_id:
type: string
memo:
type: string
state:
type: string
type: object
md.AgentQualificationEnterpriseData:
properties:
agent_id:
example: 代理id
type: string
business_license_address:
example: 营业执照地址
type: string
business_license_img_url:
example: 营业执照照片
type: string
certificate_first_type:
example: 证件类型 1级类目id
type: string
certificate_type:
example: 证件类型 2级类目id
type: string
certificate_validity:
example: 证件有效期
type: string
company_abbreviation:
example: 公司简称
type: string
company_name:
example: 公司名称
type: string
country_region:
example: 国家地区
type: string
country_region_id:
example: 国家地区id
type: string
id:
example: 状态选择
type: string
kind:
example: 类型(1:企业 2:个人)
type: string
legal_representative:
example: 法定代表人
type: string
memo:
example: 备注 审核时填写的
type: string
registered_address:
example: 注册地址
type: string
registered_address_city_id:
example: 注册地址-市id
type: string
registered_address_country_id:
example: 注册地址-国家id
type: string
registered_address_county_id:
example: 注册地址-县/区id
type: string
registered_address_province_id:
example: 册地址-省份id
type: string
state:
example: 状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)
type: string
unified_social_credit_code:
example: 统一社会信用代码
type: string
uuid:
example: 站长id
type: string
type: object
md.AgentQualificationEnterpriseReq:
properties:
limit:
type: integer
type: string
name:
type: string
page:
type: integer
type: string
state:
type: string
type: object
md.AgentQualificationEnterpriseRes:
properties:
list:
items:
$ref: '#/definitions/md.AgentQualificationEnterpriseData'
type: array
state:
items:
$ref: '#/definitions/md.SelectData'
type: array
total:
type: integer
type:
items:
$ref: '#/definitions/md.SelectData'
type: array
type: object
md.BindAdminRoleReq:
properties:
adm_id:
@@ -83,26 +275,158 @@ definitions:
token:
type: string
type: object
md.MediumQualificationEnterpriseAuditReq:
md.MediumQualificationContactData:
properties:
address:
example: 联系地址
type: string
company_name:
example: 公司名称
type: string
email:
example: 邮箱地址
type: string
id:
example: id
type: string
kind:
example: 类型(1:企业 2:个人)
type: string
medium_id:
example: 代理id
type: string
memo:
example: 备注 审核时填写的
type: string
name:
example: 联系人
type: string
phone:
example: 联系电话
type: string
state:
example: 状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)
type: string
type: object
md.MediumQualificationContactRes:
properties:
list:
items:
$ref: '#/definitions/md.MediumQualificationContactData'
type: array
state:
items:
$ref: '#/definitions/md.SelectData'
type: array
total:
type: integer
type: object
md.MediumQualificationEnterpriseAuditReq:
properties:
medium_id:
type: string
memo:
type: string
state:
type: string
type: object
md.MediumQualificationEnterpriseData:
properties:
business_license_address:
example: 营业执照地址
type: string
business_license_img_url:
example: 营业执照照片
type: string
certificate_first_type:
example: 证件类型 1级类目id
type: string
certificate_type:
example: 证件类型 2级类目id
type: string
certificate_validity:
example: 证件有效期
type: string
company_abbreviation:
example: 公司简称
type: string
company_name:
example: 公司名称
type: string
country_region:
example: 国家地区
type: string
country_region_id:
example: 国家地区id
type: string
id:
example: 状态选择
type: string
kind:
example: 类型(1:企业 2:个人)
type: string
legal_representative:
example: 法定代表人
type: string
medium_id:
example: 代理id
type: string
memo:
example: 备注 审核时填写的
type: string
registered_address:
example: 注册地址
type: string
registered_address_city_id:
example: 注册地址-市id
type: string
registered_address_country_id:
example: 注册地址-国家id
type: string
registered_address_county_id:
example: 注册地址-县/区id
type: string
registered_address_province_id:
example: 册地址-省份id
type: string
state:
example: 状态(0:待提交 1:待审核 2:审核通过 3:审核拒绝)
type: string
unified_social_credit_code:
example: 统一社会信用代码
type: string
uuid:
example: 站长id
type: string
type: object
md.MediumQualificationEnterpriseReq:
properties:
limit:
type: integer
type: string
name:
type: string
page:
type: integer
type: string
state:
type: string
type: object
md.MediumQualificationEnterpriseRes:
properties:
list:
items:
$ref: '#/definitions/md.MediumQualificationEnterpriseData'
type: array
state:
items:
$ref: '#/definitions/md.SelectData'
type: array
total:
type: integer
type:
items:
$ref: '#/definitions/md.SelectData'
type: array
type: object
md.RegisterForAgentReq:
properties:
code:
@@ -155,6 +479,15 @@ definitions:
required:
- role_id
type: object
md.SelectData:
properties:
name:
example: 名称
type: string
value:
example: 值
type: string
type: object
md.UpdateAdminReq:
properties:
adm_id:
@@ -238,9 +571,9 @@ paths:
- application/json
responses:
"200":
description: 具体看返回内容
description: 具体看返回内容 这是data里面的数据
schema:
type: string
$ref: '#/definitions/md.AgentQualificationBankRes'
"400":
description: 具体错误
schema:
@@ -298,6 +631,37 @@ paths:
$ref: '#/definitions/md.AgentQualificationEnterpriseReq'
produces:
- application/json
responses:
"200":
description: 具体看返回内容 这是data里面的数据
schema:
$ref: '#/definitions/md.AgentQualificationContactRes'
"400":
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 联系方式
tags:
- 渠道资质------嘉俊
/api/agentQualification/contact/audit:
post:
consumes:
- application/json
description: 渠道资质-联系方式审核
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
name: Authorization
required: true
type: string
- description: 请求参数
in: body
name: args
required: true
schema:
$ref: '#/definitions/md.AgentQualificationEnterpriseAuditReq'
produces:
- application/json
responses:
"200":
description: 具体看返回内容
@@ -307,7 +671,7 @@ paths:
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 联系方式
summary: 联系方式审核
tags:
- 渠道资质------嘉俊
/api/agentQualification/enterprise:
@@ -331,9 +695,9 @@ paths:
- application/json
responses:
"200":
description: 具体看返回内容
description: 具体看返回内容 这是data里面的数据
schema:
type: string
$ref: '#/definitions/md.AgentQualificationEnterpriseRes'
"400":
description: 具体错误
schema:
@@ -345,7 +709,7 @@ paths:
post:
consumes:
- application/json
description: 渠道资质-联系方式审核
description: 渠道资质-主体资质审核
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
@@ -369,7 +733,7 @@ paths:
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 联系方式审核
summary: 主体资质审核
tags:
- 渠道资质------嘉俊
/api/login:
@@ -399,10 +763,17 @@ paths:
tags:
- 登录
/api/mediumQualification/bank:
post:
responses:
"400":
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
/api/mediumQualification/bank/audit:
post:
consumes:
- application/json
description: 媒体资质-银行资质
description: 媒体资质-银行资质审核
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
@@ -414,7 +785,7 @@ paths:
name: args
required: true
schema:
$ref: '#/definitions/md.MediumQualificationEnterpriseReq'
$ref: '#/definitions/md.MediumQualificationEnterpriseAuditReq'
produces:
- application/json
responses:
@@ -426,14 +797,14 @@ paths:
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 银行资质
summary: 银行资质审核
tags:
- 媒体资质------嘉俊
/api/mediumQualification/bank/audit:
/api/mediumQualification/contact:
post:
consumes:
- application/json
description: 媒体资质-银行资质审核
description: 媒体资质-联系方式
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
@@ -445,26 +816,26 @@ paths:
name: args
required: true
schema:
$ref: '#/definitions/md.MediumQualificationEnterpriseAuditReq'
$ref: '#/definitions/md.MediumQualificationEnterpriseReq'
produces:
- application/json
responses:
"200":
description: 具体看返回内容
description: 具体看返回内容 这是data里面的数据
schema:
type: string
$ref: '#/definitions/md.MediumQualificationContactRes'
"400":
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 银行资质审核
summary: 联系方式
tags:
- 媒体资质------嘉俊
/api/mediumQualification/contact:
/api/mediumQualification/contact/audit:
post:
consumes:
- application/json
description: 媒体资质-联系方式
description: 媒体资质-联系方式审核
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
@@ -476,7 +847,7 @@ paths:
name: args
required: true
schema:
$ref: '#/definitions/md.MediumQualificationEnterpriseReq'
$ref: '#/definitions/md.MediumQualificationEnterpriseAuditReq'
produces:
- application/json
responses:
@@ -488,7 +859,7 @@ paths:
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 联系方式
summary: 联系方式审核
tags:
- 媒体资质------嘉俊
/api/mediumQualification/enterprise:
@@ -512,9 +883,9 @@ paths:
- application/json
responses:
"200":
description: 具体看返回内容
description: 具体看返回内容 这是data里面的数据
schema:
type: string
$ref: '#/definitions/md.MediumQualificationEnterpriseRes'
"400":
description: 具体错误
schema:
@@ -526,7 +897,7 @@ paths:
post:
consumes:
- application/json
description: 媒体资质-联系方式审核
description: 媒体资质-主体资质审核
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
@@ -550,7 +921,7 @@ paths:
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 联系方式审核
summary: 主体资质审核
tags:
- 媒体资质------嘉俊
/api/registerForAgent:
@@ -934,6 +1305,37 @@ paths:
tags:
- 权限管理
/api/role/updateRole:
post:
consumes:
- application/json
description: 权限管理-修改角色
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
name: Authorization
required: true
type: string
- description: 请求参数
in: body
name: args
required: true
schema:
$ref: '#/definitions/md.UpdateRoleReq'
produces:
- application/json
responses:
"200":
description: success
schema:
type: string
"400":
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 修改角色
tags:
- 权限管理
/api/role/updateRoleState:
post:
consumes:
- application/json


+ 3
- 1
go.mod Прегледај датотеку

@@ -5,7 +5,7 @@ go 1.18
//replace code.fnuoos.com/zhimeng/model.git => E:/company/ad/models

require (
code.fnuoos.com/zhimeng/model.git v0.0.3-0.20240820095544-a6a05bde8f67
code.fnuoos.com/zhimeng/model.git v0.0.3-0.20240820125928-6ce4c06dda24
github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5
github.com/boombuler/barcode v1.0.1
github.com/dchest/uniuri v0.0.0-20200228104902-7aecb25e1fe5
@@ -33,6 +33,8 @@ require (
xorm.io/xorm v1.3.1
)

require github.com/jinzhu/copier v0.4.0

require (
filippo.io/edwards25519 v1.1.0 // indirect
github.com/KyleBanks/depth v1.2.1 // indirect


Loading…
Откажи
Сачувај