ソースを参照

Merge remote-tracking branch 'origin/master'

master
huangjiajun 4日前
コミット
c30d446b66
6個のファイルの変更124行の追加13行の削除
  1. +15
    -1
      app/hdl/financial_center/hdl_withdraw.go
  2. +4
    -0
      app/md/financial_center/md_withdraw.go
  3. +41
    -5
      docs/docs.go
  4. +38
    -3
      docs/swagger.json
  5. +24
    -2
      docs/swagger.yaml
  6. +2
    -2
      go.mod

+ 15
- 1
app/hdl/financial_center/hdl_withdraw.go ファイルの表示

@@ -43,8 +43,13 @@ func GetWithdrawSetting(c *gin.Context) {
Kind: 0,
Value: 0,
}
firstWithdrawSet := md2.FirstWithdrawSet{
IsNeedRealName: 0,
FirstWithdrawAmountLimit: "",
}
frequencyStr := utils.SerializeStr(frequency)
withdrawFeeSetStr := utils.SerializeStr(withdrawFeeSet)
firstWithdrawSetStr := utils.SerializeStr(firstWithdrawSet)
m := model.FinWithdrawSetting{
FrequencySet: frequencyStr,
WithdrawType: 0,
@@ -55,8 +60,10 @@ func GetWithdrawSetting(c *gin.Context) {
WithdrawMultipleLimit: "",
IsSupportDecimalPoint: 0,
IsAuto: 0,
IsAutoAmountLimit: "",
WithdrawTimeInterval: "00:00-00:00",
WithdrawFeeSet: withdrawFeeSetStr,
FirstWithdrawSet: firstWithdrawSetStr,
CreateAt: now.Format("2006-01-02 15:04:05"),
UpdateAt: "",
}
@@ -74,8 +81,10 @@ func GetWithdrawSetting(c *gin.Context) {
}
var frequency md2.WithdrawFrequencySettingStruct
var withdrawFeeSet md2.WithdrawFeeSetStruct
var firstWithdrawSet md2.FirstWithdrawSet
utils.Unserialize([]byte(setting.FrequencySet), &frequency)
utils.Unserialize([]byte(setting.WithdrawFeeSet), &withdrawFeeSet)
utils.Unserialize([]byte(setting.FirstWithdrawSet), &firstWithdrawSet)
withdrawTimeIntervals := strings.Split(setting.WithdrawTimeInterval, "-")
withdrawTimeInterval := md2.WithdrawTimeIntervalStruct{
StartAt: withdrawTimeIntervals[0],
@@ -92,8 +101,10 @@ func GetWithdrawSetting(c *gin.Context) {
WithdrawMultipleLimit: setting.WithdrawMultipleLimit,
IsSupportDecimalPoint: setting.IsSupportDecimalPoint,
IsAuto: setting.IsAuto,
IsAutoAmountLimit: setting.IsAutoAmountLimit,
WithdrawTimeInterval: withdrawTimeInterval,
WithdrawFeeSet: withdrawFeeSet,
FirstWithdrawSet: firstWithdrawSet,
CreateAt: setting.CreateAt,
UpdateAt: setting.UpdateAt,
}
@@ -120,6 +131,7 @@ func UpdateWithdrawSetting(c *gin.Context) {
}
frequencyStr := utils.SerializeStr(req.FrequencySet)
withdrawFeeSetStr := utils.SerializeStr(req.WithdrawFeeSet)
firstWithdrawSetStr := utils.SerializeStr(req.FirstWithdrawSet)
var withdrawTimeInterval []string
withdrawTimeInterval = append(withdrawTimeInterval, req.WithdrawTimeInterval.StartAt)
withdrawTimeInterval = append(withdrawTimeInterval, req.WithdrawTimeInterval.EndAt)
@@ -135,11 +147,13 @@ func UpdateWithdrawSetting(c *gin.Context) {
WithdrawMultipleLimit: req.WithdrawMultipleLimit,
IsSupportDecimalPoint: req.IsSupportDecimalPoint,
IsAuto: req.IsAuto,
IsAutoAmountLimit: req.IsAutoAmountLimit,
WithdrawTimeInterval: withdrawTimeIntervalStr,
WithdrawFeeSet: withdrawFeeSetStr,
FirstWithdrawSet: firstWithdrawSetStr,
}

forceColumns := []string{"withdraw_type", "is_real_name", "withdraw_nums_limit", "withdraw_amount_limit", "withdraw_multiple_limit", "is_support_decimal_point", "is_auto"}
forceColumns := []string{"withdraw_type", "is_real_name", "withdraw_nums_limit", "withdraw_amount_limit", "withdraw_multiple_limit", "is_support_decimal_point", "is_auto", "first_withdraw_set", "is_auto_amount_limit"}
settingDb := implement.NewFinWithdrawSettingDb(db.Db)
affected, err := settingDb.FinWithdrawSettingUpdate(req.Id, &m, forceColumns...)
if err != nil {


+ 4
- 0
app/md/financial_center/md_withdraw.go ファイルの表示

@@ -19,8 +19,10 @@ type GetWithdrawSettingResp struct {
WithdrawMultipleLimit string `json:"withdraw_multiple_limit"` // 提现倍数限制(0为不限制,金额限制倍数才可以申请提现 )
IsSupportDecimalPoint int `json:"is_support_decimal_point"` // 是否支持小数点(0:否 1:是)
IsAuto int `json:"is_auto"` // 是否开启自动提现(0:否 1:是)
IsAutoAmountLimit string `json:"is_auto_amount_limit"` // 自动提现金额限制
WithdrawTimeInterval md.WithdrawTimeIntervalStruct `json:"withdraw_time_interval"` // 提现时段
WithdrawFeeSet md.WithdrawFeeSetStruct `json:"withdraw_fee_set"` // 提现手续费设置
FirstWithdrawSet md.FirstWithdrawSet `json:"first_withdraw_set"` // 首次提现设置
CreateAt string `json:"create_at"` // 申请时间
UpdateAt string `json:"update_at"` // 处理时间
}
@@ -36,8 +38,10 @@ type UpdateWithdrawSettingReq struct {
WithdrawMultipleLimit string `json:"withdraw_multiple_limit"` // 提现倍数限制(0为不限制,金额限制倍数才可以申请提现 )
IsSupportDecimalPoint int `json:"is_support_decimal_point"` // 是否支持小数点(0:否 1:是)
IsAuto int `json:"is_auto"` // 是否开启自动提现(0:否 1:是)
IsAutoAmountLimit string `json:"is_auto_amount_limit"` // 自动提现金额限制
WithdrawTimeInterval md.WithdrawTimeIntervalStruct `json:"withdraw_time_interval"` // 提现时段(startAt xx:xx endAt xx:xx)
WithdrawFeeSet md.WithdrawFeeSetStruct `json:"withdraw_fee_set"` // 提现手续费设置
FirstWithdrawSet md.FirstWithdrawSet `json:"first_withdraw_set"` // 首次提现设置
}
type GetWithdrawApplyListReq struct {
Uid string `json:"uid"` // 用户 ID


+ 41
- 5
docs/docs.go ファイルの表示

@@ -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"
@@ -1353,9 +1352,7 @@ const docTemplate = `{
"name": "req",
"in": "body",
"required": true,
"schema": {
"type": "object"
}
"schema": {}
}
],
"responses": {
@@ -8436,6 +8433,19 @@ const docTemplate = `{
}
}
},
"md.FirstWithdrawSet": {
"type": "object",
"properties": {
"first_withdraw_amount_limit": {
"description": "不需要实名时 最大提现金额",
"type": "string"
},
"is_need_real_name": {
"description": "是否需要实名(0:不需要,1:需要)",
"type": "integer"
}
}
},
"md.FreePublishUserNode": {
"type": "object",
"properties": {
@@ -9373,6 +9383,14 @@ const docTemplate = `{
"description": "申请时间",
"type": "string"
},
"first_withdraw_set": {
"description": "首次提现设置",
"allOf": [
{
"$ref": "#/definitions/md.FirstWithdrawSet"
}
]
},
"frequency_set": {
"description": "频率设置(0:日 1:周 2:月 3:年)",
"allOf": [
@@ -9388,6 +9406,10 @@ const docTemplate = `{
"description": "是否开启自动提现(0:否 1:是)",
"type": "integer"
},
"is_auto_amount_limit": {
"description": "自动提现金额限制",
"type": "string"
},
"is_real_name": {
"description": "是否实名(0:否 1:是)",
"type": "integer"
@@ -11276,6 +11298,14 @@ const docTemplate = `{
"md.UpdateWithdrawSettingReq": {
"type": "object",
"properties": {
"first_withdraw_set": {
"description": "首次提现设置",
"allOf": [
{
"$ref": "#/definitions/md.FirstWithdrawSet"
}
]
},
"frequency_set": {
"description": "频率设置(num 个 duration) (duration (0.天 1.小时 2.周 3.月 4.年))",
"allOf": [
@@ -11291,6 +11321,10 @@ const docTemplate = `{
"description": "是否开启自动提现(0:否 1:是)",
"type": "integer"
},
"is_auto_amount_limit": {
"description": "自动提现金额限制",
"type": "string"
},
"is_real_name": {
"description": "是否实名(0:否 1:是)",
"type": "integer"
@@ -12721,6 +12755,8 @@ var SwaggerInfo = &swag.Spec{
Description: "管理后台接口文档",
InfoInstanceName: "swagger",
SwaggerTemplate: docTemplate,
LeftDelim: "{{",
RightDelim: "}}",
}

func init() {


+ 38
- 3
docs/swagger.json ファイルの表示

@@ -1345,9 +1345,7 @@
"name": "req",
"in": "body",
"required": true,
"schema": {
"type": "object"
}
"schema": {}
}
],
"responses": {
@@ -8428,6 +8426,19 @@
}
}
},
"md.FirstWithdrawSet": {
"type": "object",
"properties": {
"first_withdraw_amount_limit": {
"description": "不需要实名时 最大提现金额",
"type": "string"
},
"is_need_real_name": {
"description": "是否需要实名(0:不需要,1:需要)",
"type": "integer"
}
}
},
"md.FreePublishUserNode": {
"type": "object",
"properties": {
@@ -9365,6 +9376,14 @@
"description": "申请时间",
"type": "string"
},
"first_withdraw_set": {
"description": "首次提现设置",
"allOf": [
{
"$ref": "#/definitions/md.FirstWithdrawSet"
}
]
},
"frequency_set": {
"description": "频率设置(0:日 1:周 2:月 3:年)",
"allOf": [
@@ -9380,6 +9399,10 @@
"description": "是否开启自动提现(0:否 1:是)",
"type": "integer"
},
"is_auto_amount_limit": {
"description": "自动提现金额限制",
"type": "string"
},
"is_real_name": {
"description": "是否实名(0:否 1:是)",
"type": "integer"
@@ -11268,6 +11291,14 @@
"md.UpdateWithdrawSettingReq": {
"type": "object",
"properties": {
"first_withdraw_set": {
"description": "首次提现设置",
"allOf": [
{
"$ref": "#/definitions/md.FirstWithdrawSet"
}
]
},
"frequency_set": {
"description": "频率设置(num 个 duration) (duration (0.天 1.小时 2.周 3.月 4.年))",
"allOf": [
@@ -11283,6 +11314,10 @@
"description": "是否开启自动提现(0:否 1:是)",
"type": "integer"
},
"is_auto_amount_limit": {
"description": "自动提现金额限制",
"type": "string"
},
"is_real_name": {
"description": "是否实名(0:否 1:是)",
"type": "integer"


+ 24
- 2
docs/swagger.yaml ファイルの表示

@@ -1328,6 +1328,15 @@ definitions:
- $ref: '#/definitions/md.SubUser'
description: 上级用户信息
type: object
md.FirstWithdrawSet:
properties:
first_withdraw_amount_limit:
description: 不需要实名时 最大提现金额
type: string
is_need_real_name:
description: 是否需要实名(0:不需要,1:需要)
type: integer
type: object
md.FreePublishUserNode:
properties:
nickname:
@@ -1974,6 +1983,10 @@ definitions:
create_at:
description: 申请时间
type: string
first_withdraw_set:
allOf:
- $ref: '#/definitions/md.FirstWithdrawSet'
description: 首次提现设置
frequency_set:
allOf:
- $ref: '#/definitions/md.WithdrawFrequencySettingStruct'
@@ -1983,6 +1996,9 @@ definitions:
is_auto:
description: 是否开启自动提现(0:否 1:是)
type: integer
is_auto_amount_limit:
description: 自动提现金额限制
type: string
is_real_name:
description: 是否实名(0:否 1:是)
type: integer
@@ -3302,6 +3318,10 @@ definitions:
type: object
md.UpdateWithdrawSettingReq:
properties:
first_withdraw_set:
allOf:
- $ref: '#/definitions/md.FirstWithdrawSet'
description: 首次提现设置
frequency_set:
allOf:
- $ref: '#/definitions/md.WithdrawFrequencySettingStruct'
@@ -3311,6 +3331,9 @@ definitions:
is_auto:
description: 是否开启自动提现(0:否 1:是)
type: integer
is_auto_amount_limit:
description: 自动提现金额限制
type: string
is_real_name:
description: 是否实名(0:否 1:是)
type: integer
@@ -5174,8 +5197,7 @@ paths:
in: body
name: req
required: true
schema:
type: object
schema: {}
produces:
- application/json
responses:


+ 2
- 2
go.mod ファイルの表示

@@ -32,8 +32,8 @@ require (
)

require (
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241129055230-e9cbd65b0bfb
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241129035757-6f22c03e842e
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241129070804-d5cc77e19dcb
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241129071929-add8a8e2196a
code.fnuoos.com/go_rely_warehouse/zyos_go_es.git v1.0.1-0.20241118083738-0f22da9ba0be
code.fnuoos.com/go_rely_warehouse/zyos_go_mq.git v0.0.5
github.com/360EntSecGroup-Skylar/excelize v1.4.1


読み込み中…
キャンセル
保存