Browse Source

git fix

master
dengbiao 1 day ago
parent
commit
13ec8ec694
14 changed files with 450 additions and 283 deletions
  1. +6
    -3
      app/hdl/hdl_callback_advertising.go
  2. +4
    -11
      app/hdl/hdl_demo.go
  3. +14
    -0
      app/hdl/hdl_user_real_name.go
  4. +50
    -16
      app/hdl/hdl_wallet.go
  5. +0
    -4
      app/md/md.wallet.go
  6. +7
    -6
      app/router/router.go
  7. +1
    -1
      app/svc/svc_advertising.go
  8. +47
    -0
      app/svc/svc_user_real_name.go
  9. +4
    -1
      app/utils/convert.go
  10. +24
    -0
      app/utils/rsa.go
  11. +111
    -91
      docs/docs.go
  12. +108
    -89
      docs/swagger.json
  13. +73
    -60
      docs/swagger.yaml
  14. +1
    -1
      go.mod

+ 6
- 3
app/hdl/hdl_callback_advertising.go View File

@@ -48,6 +48,7 @@ func CallbackChuanshanjia(c *gin.Context) {
sign := c.Query("sign")
extra := c.Query("extra")
id := gjson.Get(extra, "id").String()
uniqId := gjson.Get(extra, "uniqId").String()
phonePlatform := strings.ToLower(gjson.Get(extra, "platform").String())
platform := "chuanshanjia"
isEnd, spaceKey := comm(c, id, primeRit, platform, phonePlatform)
@@ -65,7 +66,7 @@ func CallbackChuanshanjia(c *gin.Context) {
c.String(200, "{\"is_verify\":true,\"reason\":50002}")
return
}
isEnds := commDoing(c, platform, transId, userId, extra, primeRit)
isEnds := commDoing(c, platform, transId, userId, extra, primeRit, uniqId)
if isEnds == 1 {
c.String(200, "{\"is_verify\":true,\"reason\":20000}")
return
@@ -81,6 +82,7 @@ func CallbackYoulianghui(c *gin.Context) {
sign := c.Query("sig")
extra := c.Query("extrainfo")
id := gjson.Get(extra, "id").String()
uniqId := gjson.Get(extra, "uniqId").String()
phonePlatform := strings.ToLower(gjson.Get(extra, "platform").String())
platform := "youlianghui"
isEnd, spaceKey := comm(c, id, primeRit, platform, phonePlatform)
@@ -98,7 +100,7 @@ func CallbackYoulianghui(c *gin.Context) {
c.String(200, "success")
return
}
isEnds := commDoing(c, platform, transId, userId, extra, primeRit)
isEnds := commDoing(c, platform, transId, userId, extra, primeRit, uniqId)
if isEnds == 1 {
c.String(200, "success")
return
@@ -108,7 +110,7 @@ func CallbackYoulianghui(c *gin.Context) {
}

// 公共处理
func commDoing(c *gin.Context, platform, transId, userId, extra, primeRit string) int {
func commDoing(c *gin.Context, platform, transId, userId, extra, primeRit, uniqId string) int {
types := gjson.Get(extra, "type").String()
exist, _ := db.Db.Where("platform=? and oid=?", platform, transId).Exist(&model.AdvertisingCallback{})
if exist {
@@ -121,6 +123,7 @@ func commDoing(c *gin.Context, platform, transId, userId, extra, primeRit string
Uid: utils.StrToInt(userId),
Extra: extra,
SpaceId: primeRit,
UniqId: uniqId,
CreateAt: time.Now(),
}
db.Db.Insert(&tmp)


+ 4
- 11
app/hdl/hdl_demo.go View File

@@ -4,11 +4,10 @@ import (
"applet/app/e"
"applet/app/lib/aes"
"applet/app/lib/aes/md"
md2 "applet/app/md"
"applet/app/svc"
"applet/app/utils"
"code.fnuoos.com/go_rely_warehouse/zyos_go_mq.git/rabbit"
"encoding/json"
"fmt"
"github.com/gin-gonic/gin"
"io/ioutil"
"strconv"
@@ -46,15 +45,9 @@ func Demo(c *gin.Context) {
return
}
func Demo1(c *gin.Context) {
ch, err := rabbit.Cfg.Pool.GetChannel()
if err == nil {
defer ch.Release()
}
arg := md2.AdvertisingWatch{Id: "3"}
err = ch.PublishV2(md2.EggAdvertisingQueueExchange, arg, md2.EggAdvertisingSmash)
if err != nil {
ch.PublishV2(md2.EggAdvertisingQueueExchange, arg, md2.EggAdvertisingSmash)
}
state, _, _, err := svc.GetCertifyQuery(c, "17")
fmt.Println(state)
fmt.Println(err)
}

func TestCreateSign(c *gin.Context) {


+ 14
- 0
app/hdl/hdl_user_real_name.go View File

@@ -19,6 +19,20 @@ func GetRealNameAuthBase(c *gin.Context) {
svc.GetRealNameAuthBase(c)
}

// GetRealNameAuthState
// @Summary 实名认证-基础信息
// @Tags 实名认证
// @Description 实名认证-分类
// @Accept json
// @Produce json
// @param Authorization header string true "验证参数Bearer和token空格拼接"
// @Success 200 {object} md.RealNameAuthBasicData "具体数据"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/v1/faceRealName/state [get]
func GetRealNameAuthState(c *gin.Context) {
svc.GetRealNameAuthState(c)
}

// RealNameSave
// @Summary 实名认证-保存
// @Tags 实名认证


+ 50
- 16
app/hdl/hdl_wallet.go View File

@@ -11,6 +11,7 @@ import (
"code.fnuoos.com/EggPlanet/egg_models.git/src/implement"
"code.fnuoos.com/EggPlanet/egg_models.git/src/model"
"code.fnuoos.com/EggPlanet/egg_system_rules.git/enum"
enum2 "code.fnuoos.com/EggPlanet/egg_system_rules.git/enum"
md2 "code.fnuoos.com/EggPlanet/egg_system_rules.git/md"
"code.fnuoos.com/EggPlanet/egg_system_rules.git/rule"
md3 "code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/md"
@@ -19,8 +20,8 @@ import (
"fmt"
"github.com/gin-gonic/gin"
"github.com/go-pay/gopay"
alipay2 "github.com/go-pay/gopay/alipay"
"github.com/jinzhu/copier"
"net/url"
"time"
)

@@ -399,34 +400,67 @@ func GetWithdrawCondition(c *gin.Context) {
// @Accept json
// @Produce json
// @param Authorization header string true "验证参数Bearer和token空格拼接"
// @Param req body md.LaunchBindAlipayAccountReq true "具体参数"
// @Success 200 {string} "Url"
// @Failure 400 {object} md.Response "具体错误"
// @Router /api/v1/wallet/withdraw/launchBindAlipay [POST]
// @Router /api/v1/wallet/withdraw/launchBindAlipay [GET]
func LaunchBindAlipayAccount(c *gin.Context) {
var req md.LaunchBindAlipayAccountReq
err := c.ShouldBindJSON(&req)
client, err := alipay.InitAlipay(nil)
if err != nil {
err = svc.HandleValidateErr(err)
err1 := err.(e.E)
e.OutErr(c, err1.Code, err1.Error())
e.OutErr(c, e.ERR, err.Error())
return
}
appId := client.AppId
scope := "auth_user"

client, err := alipay.InitAlipay(nil)
redisConn := cache.GetPool().Get()
sysCfgDb := implement.NewSysCfgDb(db.Db, redisConn)
sysCfgs, err := sysCfgDb.SysCfgGetAll()
if err != nil {
e.OutErr(c, e.ERR_DB_ORM, err.Error())
return
}
if sysCfgs == nil {
e.OutErr(c, e.ERR_CFG_CACHE, nil)
return
}

cfgMap := make(map[string]string, len(*sysCfgs))
for _, cfg := range *sysCfgs {
cfgMap[cfg.Key] = cfg.Val
}
targetId := utils.UUIDHexString()

alipayPrivateKey := cfgMap[enum2.AlipayPrivateKey]
pid := cfgMap[enum2.AlipayPid]
bm := make(gopay.BodyMap)
bm.Set("apiname", "com.alipay.account.auth")
bm.Set("app_id", appId)
bm.Set("app_name", "mc")
bm.Set("auth_type", "AUTHACCOUNT")
bm.Set("biz_type", "openservice")
bm.Set("pid", pid)
bm.Set("product_id", "APP_FAST_LOGIN")
bm.Set("scope", scope)
bm.Set("sign_type", "RSA2")
bm.Set("method", "alipay.open.auth.sdk.code.get")
bm.Set("target_id", targetId)
privateKey, err := utils.StringToPrivateKey(alipayPrivateKey)
if err != nil {
e.OutErr(c, e.ERR, err.Error())
return
}
sign, err := alipay2.GetRsaSign(bm, alipay2.RSA2, privateKey)
if err != nil {
e.OutErr(c, e.ERR, err.Error())
return
}
appId := client.AppId
redirectUri := req.RedirectUri
scope := "auth_user"

reqUrl := fmt.Sprintf("https://openauth.alipay.com/oauth2/publicAppAuthorize.htm?app_id=%s&scope=%s&redirect_uri=%s", appId, scope, redirectUri)
reqUrl = url.QueryEscape(reqUrl)
res := "alipays://platformapi/startapp?appId=20000067&url=" + reqUrl
resUrl := fmt.Sprintf("apiname=com.alipay.account.auth&app_id=%s&app_name=mc&"+
"auth_type=AUTHACCOUNT&biz_type=openservice&method=alipay.open.auth.sdk.code.get"+
"&pid=%s&product_id=APP_FAST_LOGIN&scosspe=%s&sign_type=RSA2&"+
"target_id=%s&sign=%s", appId, pid, scope, targetId, sign)

e.OutSuc(c, res, nil)
e.OutSuc(c, resUrl, nil)
}

// BindAlipayAccount


+ 0
- 4
app/md/md.wallet.go View File

@@ -40,10 +40,6 @@ type GetWithdrawConditionResp struct {
NotWithdrawReason string `json:"not_withdraw_reason"` // 不能提现原因
}

type LaunchBindAlipayAccountReq struct {
RedirectUri string `json:"redirect_uri"` // 回调页面,是经过转义的 URL 链接(url 必须以 HTTP 或者 HTTPS 开头)
}

type BindAlipayAccountReq struct {
AuthCode string `json:"auth_code"` // 支付宝回调的临时授权码
}


+ 7
- 6
app/router/router.go View File

@@ -133,11 +133,11 @@ func route(r *gin.RouterGroup) {
rWallet.GET("/amountFlow", hdl.GetAmountFlow) // 余额流水
rWithdraw := rWallet.Group("/withdraw")
{
rWithdraw.GET("/index", hdl.WithdrawGetAmount) // 查询余额
rWithdraw.POST("/apply", hdl.WithdrawApply) // 发起提现申请
rWithdraw.GET("/condition", hdl.GetWithdrawCondition) // 获取提现条件
rWithdraw.POST("/launchBindAlipay", hdl.LaunchBindAlipayAccount) // 支付宝发起绑定请求获得 url
rWithdraw.POST("/bindAlipay", hdl.BindAlipayAccount) // 绑定支付宝
rWithdraw.GET("/index", hdl.WithdrawGetAmount) // 查询余额
rWithdraw.POST("/apply", hdl.WithdrawApply) // 发起提现申请
rWithdraw.GET("/condition", hdl.GetWithdrawCondition) // 获取提现条件
rWithdraw.GET("/launchBindAlipay", hdl.LaunchBindAlipayAccount) // 支付宝发起绑定请求获得 url
rWithdraw.POST("/bindAlipay", hdl.BindAlipayAccount) // 绑定支付宝
rWithdraw.POST("/bindWxPay", hdl.BindWxPayAccount)
}
}
@@ -174,7 +174,8 @@ func route(r *gin.RouterGroup) {

rFaceRealName := r.Group("/faceRealName") // 实名认证
{
rFaceRealName.GET("/base", hdl.GetRealNameAuthBase) //实名认证基础
rFaceRealName.GET("/base", hdl.GetRealNameAuthBase) //实名认证基础
rFaceRealName.GET("/state", hdl.GetRealNameAuthState) //实名认证基础
rFaceRealName.POST("/save", hdl.RealNameSave)
}
}


+ 1
- 1
app/svc/svc_advertising.go View File

@@ -127,7 +127,7 @@ func AdvertisingState(c *gin.Context) {
}
isSuccess := "0"
var data model.AdvertisingCallback
db.Db.Where("oid=? ", req.Id).Get(&data)
db.Db.Where("uniq_id=? ", req.Id).Get(&data)
if data.Id > 0 {
isSuccess = "1"
}


+ 47
- 0
app/svc/svc_user_real_name.go View File

@@ -66,6 +66,53 @@ func GetRealNameAuthBase(c *gin.Context) {
e.OutSuc(c, res, nil)
return
}
func GetRealNameAuthState(c *gin.Context) {
var res = &md.RealNameAuthBasicData{
AuthState: "0",
IsNeedGetEnergy: "1",
TipStr: "请前往蛋蛋乐园获取能量",
}
res.AuthState = "0"
//判断审核状态
eg := db.Db
user := GetUser(c)
egg_system_rules.Init(cfg.RedisAddr)
amount := GetSysCfgStr("user_real_name_money")
_, can := egg_energy.CheckActivityCoinToAlipayRealName(db.Db, user.Id, amount)
if can {
res.IsNeedGetEnergy = "0"
}
NewUserRealNameAuthDb := implement.NewUserRealNameAuthDb(eg)
list, _ := NewUserRealNameAuthDb.GetRealNameAuthByUid(utils.Int64ToStr(user.Id))
if list != nil {
//如果是审核中的订单,判断是否人脸识别 调用人脸识别获取结果
if list.State != 1 && list.CertifyId != "" {
state, _, _, err := GetCertifyQuery(c, utils.Int64ToStr(user.Id))
if err == nil {
list.State = state
}
}
res.AuthState = utils.IntToStr(list.State)
if list.State == 0 { //人脸识别 支付了但是没扫脸的情况 设置成没审核状态
res.AuthState = "0"
}
if list.IsPay == 0 {
res.AuthState = "0"
}
if list.IsPay == 1 {
res.IsNeedGetEnergy = "0"
}
}
if res.AuthState == "1" {
res.IsNeedGetEnergy = "0"
if user.IsRealName == 0 {
user.IsRealName = 1
eg.Where("id=?", user.Id).Cols("is_real_name").Update(user)
}
}
e.OutSuc(c, res, nil)
return
}

func RealNameSave(c *gin.Context) {
var args md.RealNameAuthAddRequest


+ 4
- 1
app/utils/convert.go View File

@@ -271,7 +271,10 @@ func ByteToFloat64(bytes []byte) float64 {
}

func Float64ToStr(f float64) string {
return strconv.FormatFloat(f, 'f', 2, 64)
if f == float64(int64(f)) {
return strconv.FormatInt(int64(f), 10)
}
return fmt.Sprintf("%.2f", f)
}
func Float64ToStrPrec1(f float64) string {
return strconv.FormatFloat(f, 'f', 1, 64)


+ 24
- 0
app/utils/rsa.go View File

@@ -5,6 +5,7 @@ import (
"crypto/rand"
"crypto/rsa"
"crypto/x509"
"encoding/base64"
"encoding/pem"
"errors"
"fmt"
@@ -168,3 +169,26 @@ func OpensslPemGetPublic(pathOrString string) (interface{}, error) {
fmt.Printf("Got a %T, with remaining data: %q", pub, rest)
return pub, nil
}

// StringToPrivateKey 字符串变为私钥
func StringToPrivateKey(base64Str string) (*rsa.PrivateKey, error) {
// Base64解码以获取DER数据
derData, err := base64.StdEncoding.DecodeString(base64Str)
if err != nil {
return nil, fmt.Errorf("base64 decode failed: %v", err)
}

// 解析DER数据以获取私钥
privateKey, err := x509.ParsePKCS8PrivateKey(derData)
if err != nil {
return nil, fmt.Errorf("failed to parse private key: %v", err)
}

// 类型断言以确保privateKey是*rsa.PrivateKey类型
rsaPrivateKey, ok := privateKey.(*rsa.PrivateKey)
if !ok {
return nil, fmt.Errorf("private key is not of type *rsa.PrivateKey")
}

return rsaPrivateKey, nil
}

+ 111
- 91
docs/docs.go View File

@@ -1,5 +1,4 @@
// Code generated by swaggo/swag. DO NOT EDIT.

// Package docs Code generated by swaggo/swag. DO NOT EDIT
package docs

import "github.com/swaggo/swag"
@@ -945,6 +944,44 @@ const docTemplate = `{
}
}
},
"/api/v1/faceRealName/state": {
"get": {
"description": "实名认证-分类",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"实名认证"
],
"summary": "实名认证-基础信息",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
}
],
"responses": {
"200": {
"description": "具体数据",
"schema": {
"$ref": "#/definitions/md.RealNameAuthBasicData"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/v1/fastLogin": {
"post": {
"description": "一键登录",
@@ -1048,7 +1085,7 @@ const docTemplate = `{
},
{
"type": "string",
"description": "页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户)",
"description": "页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户 14实名认证)",
"name": "mod_name_value",
"in": "query",
"required": true
@@ -2305,9 +2342,7 @@ const docTemplate = `{
"name": "req",
"in": "body",
"required": true,
"schema": {
"type": "object"
}
"schema": {}
}
],
"responses": {
@@ -2917,7 +2952,7 @@ const docTemplate = `{
}
},
"/api/v1/wallet/withdraw/launchBindAlipay": {
"post": {
"get": {
"description": "发起绑定支付宝获得URL",
"consumes": [
"application/json"
@@ -2936,15 +2971,6 @@ const docTemplate = `{
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "具体参数",
"name": "req",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.LaunchBindAlipayAccountReq"
}
}
],
"responses": {
@@ -3022,68 +3048,6 @@ const docTemplate = `{
}
}
},
"code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd": {
"type": "object",
"properties": {
"amount": {
"type": "string"
},
"create_time": {
"type": "string"
},
"id": {
"type": "integer"
},
"im_data": {
"type": "string"
},
"im_uid": {
"type": "integer"
},
"ord_no": {
"type": "string"
},
"received_im_user_ids": {
"type": "string"
},
"received_times": {
"type": "string"
},
"received_user_amount": {
"type": "string"
},
"received_user_ids": {
"type": "string"
},
"red_packet_balance_amount": {
"type": "string"
},
"red_packet_balance_nums": {
"type": "integer"
},
"red_packet_nums": {
"type": "integer"
},
"red_packet_type": {
"type": "integer"
},
"state": {
"type": "integer"
},
"uid": {
"type": "integer"
},
"update_time": {
"type": "string"
},
"wait_draw_im_user_ids": {
"type": "string"
},
"wait_draw_user_ids": {
"type": "string"
}
}
},
"comm.AccessRecordsReq": {
"type": "object",
"properties": {
@@ -3834,9 +3798,7 @@ const docTemplate = `{
"type": "object",
"properties": {
"data": {
"description": "内容",
"type": "object",
"additionalProperties": true
"description": "内容"
},
"mod_name": {
"description": "模块名称",
@@ -4142,15 +4104,6 @@ const docTemplate = `{
}
}
},
"md.LaunchBindAlipayAccountReq": {
"type": "object",
"properties": {
"redirect_uri": {
"description": "回调页面,是经过转义的 URL 链接(url 必须以 HTTP 或者 HTTPS 开头)",
"type": "string"
}
}
},
"md.LoginReq": {
"type": "object",
"required": [
@@ -4385,6 +4338,9 @@ const docTemplate = `{
"is_need_get_energy": {
"type": "string",
"example": "0不需要获取能量 1弹窗提示 前往蛋蛋乐园获取能量"
},
"tip_str": {
"type": "string"
}
}
},
@@ -4427,7 +4383,7 @@ const docTemplate = `{
"description": "红包详情信息",
"allOf": [
{
"$ref": "#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd"
"$ref": "#/definitions/model.ImSendRedPackageOrd"
}
]
},
@@ -5052,6 +5008,68 @@ const docTemplate = `{
}
}
},
"model.ImSendRedPackageOrd": {
"type": "object",
"properties": {
"amount": {
"type": "string"
},
"create_time": {
"type": "string"
},
"id": {
"type": "integer"
},
"im_data": {
"type": "string"
},
"im_uid": {
"type": "integer"
},
"ord_no": {
"type": "string"
},
"received_im_user_ids": {
"type": "string"
},
"received_times": {
"type": "string"
},
"received_user_amount": {
"type": "string"
},
"received_user_ids": {
"type": "string"
},
"red_packet_balance_amount": {
"type": "string"
},
"red_packet_balance_nums": {
"type": "integer"
},
"red_packet_nums": {
"type": "integer"
},
"red_packet_type": {
"type": "integer"
},
"state": {
"type": "integer"
},
"uid": {
"type": "integer"
},
"update_time": {
"type": "string"
},
"wait_draw_im_user_ids": {
"type": "string"
},
"wait_draw_user_ids": {
"type": "string"
}
}
},
"pb.SendRedPacketResp": {
"type": "object",
"properties": {
@@ -5074,6 +5092,8 @@ var SwaggerInfo = &swag.Spec{
Description: "APP客户端-Api接口",
InfoInstanceName: "swagger",
SwaggerTemplate: docTemplate,
LeftDelim: "{{",
RightDelim: "}}",
}

func init() {


+ 108
- 89
docs/swagger.json View File

@@ -938,6 +938,44 @@
}
}
},
"/api/v1/faceRealName/state": {
"get": {
"description": "实名认证-分类",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"实名认证"
],
"summary": "实名认证-基础信息",
"parameters": [
{
"type": "string",
"description": "验证参数Bearer和token空格拼接",
"name": "Authorization",
"in": "header",
"required": true
}
],
"responses": {
"200": {
"description": "具体数据",
"schema": {
"$ref": "#/definitions/md.RealNameAuthBasicData"
}
},
"400": {
"description": "具体错误",
"schema": {
"$ref": "#/definitions/md.Response"
}
}
}
}
},
"/api/v1/fastLogin": {
"post": {
"description": "一键登录",
@@ -1041,7 +1079,7 @@
},
{
"type": "string",
"description": "页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户)",
"description": "页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户 14实名认证)",
"name": "mod_name_value",
"in": "query",
"required": true
@@ -2298,9 +2336,7 @@
"name": "req",
"in": "body",
"required": true,
"schema": {
"type": "object"
}
"schema": {}
}
],
"responses": {
@@ -2910,7 +2946,7 @@
}
},
"/api/v1/wallet/withdraw/launchBindAlipay": {
"post": {
"get": {
"description": "发起绑定支付宝获得URL",
"consumes": [
"application/json"
@@ -2929,15 +2965,6 @@
"name": "Authorization",
"in": "header",
"required": true
},
{
"description": "具体参数",
"name": "req",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/md.LaunchBindAlipayAccountReq"
}
}
],
"responses": {
@@ -3015,68 +3042,6 @@
}
}
},
"code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd": {
"type": "object",
"properties": {
"amount": {
"type": "string"
},
"create_time": {
"type": "string"
},
"id": {
"type": "integer"
},
"im_data": {
"type": "string"
},
"im_uid": {
"type": "integer"
},
"ord_no": {
"type": "string"
},
"received_im_user_ids": {
"type": "string"
},
"received_times": {
"type": "string"
},
"received_user_amount": {
"type": "string"
},
"received_user_ids": {
"type": "string"
},
"red_packet_balance_amount": {
"type": "string"
},
"red_packet_balance_nums": {
"type": "integer"
},
"red_packet_nums": {
"type": "integer"
},
"red_packet_type": {
"type": "integer"
},
"state": {
"type": "integer"
},
"uid": {
"type": "integer"
},
"update_time": {
"type": "string"
},
"wait_draw_im_user_ids": {
"type": "string"
},
"wait_draw_user_ids": {
"type": "string"
}
}
},
"comm.AccessRecordsReq": {
"type": "object",
"properties": {
@@ -3827,9 +3792,7 @@
"type": "object",
"properties": {
"data": {
"description": "内容",
"type": "object",
"additionalProperties": true
"description": "内容"
},
"mod_name": {
"description": "模块名称",
@@ -4135,15 +4098,6 @@
}
}
},
"md.LaunchBindAlipayAccountReq": {
"type": "object",
"properties": {
"redirect_uri": {
"description": "回调页面,是经过转义的 URL 链接(url 必须以 HTTP 或者 HTTPS 开头)",
"type": "string"
}
}
},
"md.LoginReq": {
"type": "object",
"required": [
@@ -4378,6 +4332,9 @@
"is_need_get_energy": {
"type": "string",
"example": "0不需要获取能量 1弹窗提示 前往蛋蛋乐园获取能量"
},
"tip_str": {
"type": "string"
}
}
},
@@ -4420,7 +4377,7 @@
"description": "红包详情信息",
"allOf": [
{
"$ref": "#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd"
"$ref": "#/definitions/model.ImSendRedPackageOrd"
}
]
},
@@ -5045,6 +5002,68 @@
}
}
},
"model.ImSendRedPackageOrd": {
"type": "object",
"properties": {
"amount": {
"type": "string"
},
"create_time": {
"type": "string"
},
"id": {
"type": "integer"
},
"im_data": {
"type": "string"
},
"im_uid": {
"type": "integer"
},
"ord_no": {
"type": "string"
},
"received_im_user_ids": {
"type": "string"
},
"received_times": {
"type": "string"
},
"received_user_amount": {
"type": "string"
},
"received_user_ids": {
"type": "string"
},
"red_packet_balance_amount": {
"type": "string"
},
"red_packet_balance_nums": {
"type": "integer"
},
"red_packet_nums": {
"type": "integer"
},
"red_packet_type": {
"type": "integer"
},
"state": {
"type": "integer"
},
"uid": {
"type": "integer"
},
"update_time": {
"type": "string"
},
"wait_draw_im_user_ids": {
"type": "string"
},
"wait_draw_user_ids": {
"type": "string"
}
}
},
"pb.SendRedPacketResp": {
"type": "object",
"properties": {


+ 73
- 60
docs/swagger.yaml View File

@@ -12,47 +12,6 @@ definitions:
description: 总数据量
type: integer
type: object
code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd:
properties:
amount:
type: string
create_time:
type: string
id:
type: integer
im_data:
type: string
im_uid:
type: integer
ord_no:
type: string
received_im_user_ids:
type: string
received_times:
type: string
received_user_amount:
type: string
received_user_ids:
type: string
red_packet_balance_amount:
type: string
red_packet_balance_nums:
type: integer
red_packet_nums:
type: integer
red_packet_type:
type: integer
state:
type: integer
uid:
type: integer
update_time:
type: string
wait_draw_im_user_ids:
type: string
wait_draw_user_ids:
type: string
type: object
comm.AccessRecordsReq:
properties:
index:
@@ -571,9 +530,7 @@ definitions:
md.GetModuleSettingResp:
properties:
data:
additionalProperties: true
description: 内容
type: object
mod_name:
description: 模块名称
type: string
@@ -786,12 +743,6 @@ definitions:
description: 能否签到
type: boolean
type: object
md.LaunchBindAlipayAccountReq:
properties:
redirect_uri:
description: 回调页面,是经过转义的 URL 链接(url 必须以 HTTP 或者 HTTPS 开头)
type: string
type: object
md.LoginReq:
properties:
code:
@@ -957,6 +908,8 @@ definitions:
is_need_get_energy:
example: 0不需要获取能量 1弹窗提示 前往蛋蛋乐园获取能量
type: string
tip_str:
type: string
type: object
md.RealNameAuthResp:
properties:
@@ -984,7 +937,7 @@ definitions:
properties:
detail:
allOf:
- $ref: '#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd'
- $ref: '#/definitions/model.ImSendRedPackageOrd'
description: 红包详情信息
list:
description: 领取红包用户列表
@@ -1414,6 +1367,47 @@ definitions:
description: 余额
type: string
type: object
model.ImSendRedPackageOrd:
properties:
amount:
type: string
create_time:
type: string
id:
type: integer
im_data:
type: string
im_uid:
type: integer
ord_no:
type: string
received_im_user_ids:
type: string
received_times:
type: string
received_user_amount:
type: string
received_user_ids:
type: string
red_packet_balance_amount:
type: string
red_packet_balance_nums:
type: integer
red_packet_nums:
type: integer
red_packet_type:
type: integer
state:
type: integer
uid:
type: integer
update_time:
type: string
wait_draw_im_user_ids:
type: string
wait_draw_user_ids:
type: string
type: object
pb.SendRedPacketResp:
properties:
seq:
@@ -2041,6 +2035,31 @@ paths:
summary: 实名认证-保存
tags:
- 实名认证
/api/v1/faceRealName/state:
get:
consumes:
- application/json
description: 实名认证-分类
parameters:
- description: 验证参数Bearer和token空格拼接
in: header
name: Authorization
required: true
type: string
produces:
- application/json
responses:
"200":
description: 具体数据
schema:
$ref: '#/definitions/md.RealNameAuthBasicData'
"400":
description: 具体错误
schema:
$ref: '#/definitions/md.Response'
summary: 实名认证-基础信息
tags:
- 实名认证
/api/v1/fastLogin:
post:
consumes:
@@ -2104,7 +2123,8 @@ paths:
name: Authorization
required: true
type: string
- description: 页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户)
- description: 页面名称类型值(1:首页 2:会员中心 3:底部导航 4:邀请下载落地页 5:邀请海报 7:下载渠道 8:贡献值 9:蛋蛋分 10:商务合作 11:资质证书 12:提现页 13:提现到账户
14实名认证)
in: query
name: mod_name_value
required: true
@@ -2934,8 +2954,7 @@ paths:
in: body
name: req
required: true
schema:
type: object
schema: {}
produces:
- application/json
responses:
@@ -3341,7 +3360,7 @@ paths:
tags:
- 钱包
/api/v1/wallet/withdraw/launchBindAlipay:
post:
get:
consumes:
- application/json
description: 发起绑定支付宝获得URL
@@ -3351,12 +3370,6 @@ paths:
name: Authorization
required: true
type: string
- description: 具体参数
in: body
name: req
required: true
schema:
$ref: '#/definitions/md.LaunchBindAlipayAccountReq'
produces:
- application/json
responses:


+ 1
- 1
go.mod View File

@@ -3,7 +3,7 @@ module applet
go 1.19

//replace code.fnuoos.com/EggPlanet/egg_models.git => E:/company/Egg/egg_models
//
//replace code.fnuoos.com/EggPlanet/egg_system_rules.git => E:/company/Egg/egg_system_rules

require (


Loading…
Cancel
Save