Bladeren bron

update

add_mode
DengBiao 1 jaar geleden
bovenliggende
commit
5d451e31e6
3 gewijzigde bestanden met toevoegingen van 41 en 3 verwijderingen
  1. +1
    -0
      app/customer/hdl/hdl_user_identity.go
  2. +7
    -0
      app/customer/md/md_curl_smart_pay.go
  3. +33
    -3
      app/customer/svc/svc_curl_smart_pay.go

+ 1
- 0
app/customer/hdl/hdl_user_identity.go Bestand weergeven

@@ -44,6 +44,7 @@ func SaveCentralKitchenForSchoolUserIdentity(c *gin.Context) {
Uid: user.Id,
Name: req.Name,
IdNo: req.IdNo,
CertType: enum.UserIdentityCertTypeForIdCard,
Kind: enum.UserIdentityKindForCommon,
Identity: identity,
EnterpriseId: req.EnterpriseId,


+ 7
- 0
app/customer/md/md_curl_smart_pay.go Bestand weergeven

@@ -150,3 +150,10 @@ type CurlAlipayPlanetEcocampusApiDebtCancel struct {
OutOrderNo string `json:"out_order_no" label:"外部订单号"`
MerchantCode string `json:"merchant_code" label:"商户编号"`
}

type CurlAlipayPlanetEcocampusApiRosterConsumeLimit struct {
ConsumeLimitSyncInfo struct {
} `json:"school_code" label:"外部订单号"`
SchoolCode string `json:"school_code" label:"外部订单号"`
SchoolName string `json:"school_name" label:"商户编号"`
}

+ 33
- 3
app/customer/svc/svc_curl_smart_pay.go Bestand weergeven

@@ -183,7 +183,7 @@ func CurlEducateSceneTokenQuery(args md.CurlEducateSceneTokenReq, userIdentity *
"school_std_code": args.SchoolStdCode,
"student_name": args.StudentName,
"out_user_id": args.OutUserId,
"cert_type": "1",
"cert_type": args.CertType,
"sub_code": "SCHOOL_FACE_PASS_QUERY",
}), nil)
if err1 != nil {
@@ -422,7 +422,7 @@ func CurlEducateSceneTokenCreateForApplet(args md.CurlEducateSceneTokenReq) (err
"school_std_code": args.SchoolStdCode,
"student_name": args.StudentName,
"out_user_id": args.OutUserId,
"cert_type": "1",
"cert_type": args.CertType,
"sub_code": "SCHOOL_FACE_PASS_NAVIGATE",
}), nil)
if err != nil {
@@ -467,7 +467,7 @@ func CurlEducateSceneTokenCreateForConcentratedCollectApplet(args md.CurlEducate
"school_std_code": args.SchoolStdCode,
"student_name": args.StudentName,
"out_user_id": args.OutUserId,
"cert_type": "1",
"cert_type": args.CertType,
"sub_code": "SCHOOL_PAYMENT_REMOTE_OPEN_ACCOUNT",
"operator_user_id": args.OperatorUserId, //采集人员的支付宝会员标识。(当sub_code为SCHOOL_PAYMENT_REMOTE_OPEN_ACCOUNT时,当前参数必选)
}), nil)
@@ -703,3 +703,33 @@ func CurlAlipayPlanetEcocampusApiDebtCancel(args md.CurlAlipayPlanetEcocampusApi
}
return nil, result.Data
}

func CurlAlipayPlanetEcocampusApiRosterConsumeLimit(args md.CurlAlipayPlanetEcocampusApiRosterConsumeLimit) (err error, resp interface{}) {
url := cfg.SmartCanteenPay + "/alipay/bPass/alipayPlanetEcocampusApiRosterConsumeLimit"
utils.FilePutContents("CurlAlipayPlanetEcocampusApiRosterConsumeLimit", 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("CurlAlipayPlanetEcocampusApiRosterConsumeLimit", 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
}

Laden…
Annuleren
Opslaan