瀏覽代碼

update

add_mode
DengBiao 1 年之前
父節點
當前提交
00f5dce7a6
共有 5 個文件被更改,包括 73 次插入0 次删除
  1. +30
    -0
      app/admin/hdl/enterprise_manage/hdl_self_support_for_school.go
  2. +6
    -0
      app/admin/md/md_enterprise_manage.go
  3. +6
    -0
      app/customer/md/md_curl_smart_pay.go
  4. +30
    -0
      app/customer/svc/svc_curl_smart_pay.go
  5. +1
    -0
      app/router/admin_router.go

+ 30
- 0
app/admin/hdl/enterprise_manage/hdl_self_support_for_school.go 查看文件

@@ -813,6 +813,36 @@ func SelfSupportForSchoolArrearsOrdList(c *gin.Context) {
return
}

func SelfSupportForSchoolBlackList(c *gin.Context) {
var req md.SelfSupportForSchoolBlackListReq
err := c.ShouldBindJSON(&req)
if err != nil {
err = validate.HandleValidateErr(err)
err1 := err.(e.E)
e.OutErr(c, err1.Code, err1.Error())
return
}

selfSupportForSchoolInfoDb := db.SelfSupportForSchoolInfoDb{}
selfSupportForSchoolInfoDb.Set(req.EnterpriseId)
info, err := selfSupportForSchoolInfoDb.GetSelfSupportForSchoolInfo()
if err != nil {
e.OutErr(c, e.ERR_DB_ORM, err.Error())
return
}
err, resp := svc.CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList(md2.CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList{
SchoolCode: info.SchoolCode,
PageNo: req.Page,
PageSize: req.Limit,
})
if err != nil {
e.OutErr(c, e.ERR, err.Error())
return
}
e.OutSuc(c, resp, nil)
return
}

func SelfSupportForSchoolArrearsOrdDebtRepay(c *gin.Context) {
var req md.SelfSupportForSchoolArrearsOrdDebtRepayReq
err := c.ShouldBindJSON(&req)


+ 6
- 0
app/admin/md/md_enterprise_manage.go 查看文件

@@ -461,6 +461,12 @@ type SelfSupportForSchoolArrearsOrdListReq struct {
IsTeacher int `json:"is_teacher" label:"是否教师"`
}

type SelfSupportForSchoolBlackListReq struct {
EnterpriseId int `json:"enterprise_id" label:"企业id"`
Limit int `json:"limit" binding:"required"`
Page int `json:"page" binding:"required"`
}

type SelfSupportForSchoolArrearsOrdDebtRepayReq struct {
UserIdentityId int `json:"user_identity_id" label:"用户身份id"`
OutOrderNo string `json:"out_order_no"`


+ 6
- 0
app/customer/md/md_curl_smart_pay.go 查看文件

@@ -131,6 +131,12 @@ type CurlAlipayPlanetEcocampusApiDebtPageQueryDebtInfo struct {
PageSize int `json:"page_size"`
}

type CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList struct {
SchoolCode string `json:"school_code" label:"学校内标"`
PageNo int `json:"page_no"`
PageSize int `json:"page_size"`
}

type CurlSelfSupportForSchoolOrderDebtRepay struct {
OutOrderNo string `json:"out_order_no" label:"外部订单号"`
MerchantCode string `json:"merchant_code" label:"商户编号"`


+ 30
- 0
app/customer/svc/svc_curl_smart_pay.go 查看文件

@@ -628,6 +628,36 @@ func CurlAlipayPlanetEcocampusApiDebtPageQueryDebtInfo(args md.CurlAlipayPlanetE
return nil, result.Data
}

func CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList(args md.CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList) (err error, resp interface{}) {
url := cfg.SmartCanteenPay + "/alipay/bPass/alipayPlanetEcocampusApiRosterPageQueryBlackList"
utils.FilePutContents("CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList", utils.SerializeStr(map[string]interface{}{
"args": args,
}))
bytes, err := utils.CurlPost(url, utils.Serialize(args), nil)
if err != nil {
return
}
var result struct {
Code int `json:"code"`
Msg string `json:"msg"`
Data interface{} `json:"data"`
}
utils.FilePutContents("CurlAlipayPlanetEcocampusApiRosterPageQueryBlackList", utils.SerializeStr(result))
err = json.Unmarshal(bytes, &result)
if err != nil {
return
}
if result.Code != 0 {
if result.Msg != "" {
err = errors.New(result.Msg)
return
}
err = errors.New("请求智慧餐厅支付 异常/失败")
return
}
return nil, result.Data
}

func CurlAlipayPlanetEcocampusApiDebtCancel(args md.CurlAlipayPlanetEcocampusApiDebtCancel) (err error, resp interface{}) {
url := cfg.SmartCanteenPay + "/alipay/bPass/alipayPlanetEcocampusApiDebtCancel"
utils.FilePutContents("CurlAlipayPlanetEcocampusApiDebtCancel", utils.SerializeStr(map[string]interface{}{


+ 1
- 0
app/router/admin_router.go 查看文件

@@ -208,6 +208,7 @@ func rEnterpriseManage(r *gin.RouterGroup) {
r.GET("/selfSupportForSchool/downloadTemplateExcel", hdl.SelfSupportForSchoolDownloadTemplateExcel) //"自营-学校"下载表格模板
r.POST("/selfSupportForSchool/ordList", hdl.SelfSupportForSchoolOrdList) //"自营-学校"订单列表
r.POST("/selfSupportForSchool/arrearsOrdList", hdl.SelfSupportForSchoolArrearsOrdList) //"自营-学校"订单欠费列表
r.POST("/selfSupportForSchool/blackList", hdl.SelfSupportForSchoolBlackList) //"自营-学校"黑名单列表
r.POST("/selfSupportForSchool/arrearsOrdDebtRepay", hdl.SelfSupportForSchoolArrearsOrdDebtRepay) //"自营-学校"订单欠费催缴
r.POST("/selfSupportForSchool/arrearsOrdDebtCancel", hdl.SelfSupportForSchoolArrearsOrdDebtCancel) //"自营-学校"撤销欠款
r.GET("/selfSupportForSchool/educateSceneKidsClose", hdl.SelfSupportForSchoolEducateSceneKidsClose) //"自营-学校"人脸识别关闭


Loading…
取消
儲存