@@ -1,14 +1,17 @@ | |||
package egg_energy | |||
import ( | |||
"applet/app/cfg" | |||
"applet/app/db" | |||
"applet/app/e" | |||
md "applet/app/md/institutional_management/egg_energy" | |||
"applet/app/utils" | |||
"code.fnuoos.com/EggPlanet/egg_models.git/src/implement" | |||
"code.fnuoos.com/EggPlanet/egg_models.git/src/model" | |||
rule "code.fnuoos.com/EggPlanet/egg_system_rules.git" | |||
"code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/enum" | |||
md2 "code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/md" | |||
"code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/svc" | |||
"errors" | |||
"fmt" | |||
"github.com/gin-gonic/gin" | |||
@@ -235,6 +238,7 @@ func GetEggEnergyBasic(c *gin.Context) { | |||
RewardSystem: rewardSystem, | |||
NewUserIncentiveRules: newUserRewardRules, | |||
SystemID: basicSettings.Id, | |||
SettlementQuantity: basicSettings.SettlementQuantity, | |||
} | |||
e.OutSuc(c, resp, nil) | |||
@@ -289,6 +293,7 @@ func UpdateEggEnergyBasic(c *gin.Context) { | |||
RewardSystem: rewardSystemStr, | |||
NewUserIncentiveRules: newUserIncentiveRulesStr, | |||
TotalTeamDividends: req.DataSetting.TotalTeamDividends, | |||
SettlementQuantity: utils.StrToInt(req.SettlementQuantity), | |||
} | |||
forceColums := []string{"is_open", "video_reward_is_open"} | |||
@@ -474,6 +479,99 @@ func UpdateEggEnergyVipSetting(c *gin.Context) { | |||
e.OutSuc(c, affected, nil) | |||
} | |||
// GetEggEnergyCoreData | |||
// @Summary 制度中心-蛋蛋能量-核心数据(获取) | |||
// @Tags 蛋蛋能量 | |||
// @Description 核心数据(获取) | |||
// @Accept json | |||
// @Produce json | |||
// @param Authorization header string true "验证参数Bearer和token空格拼接" | |||
// @Success 200 {object} md.GetEggEnergyCoreDataResp "具体数据" | |||
// @Failure 400 {object} md.Response "具体错误" | |||
// @Router /api/institutionalManagement/eggEnergy/coreData [GET] | |||
func GetEggEnergyCoreData(c *gin.Context) { | |||
dataDb := implement.NewEggEnergyCoreDataDb(db.Db) | |||
coreData, err := dataDb.EggEnergyCoreDataGet() | |||
if err != nil { | |||
e.OutErr(c, e.ERR_DB_ORM, err.Error()) | |||
return | |||
} | |||
resp := md.GetEggEnergyCoreDataResp{ | |||
Id: coreData.Id, | |||
NowPrice: coreData.NowPrice, | |||
PlanetTotalValue: coreData.PlanetTotalValue, | |||
NowEnergyTotalNums: coreData.NowEnergyTotalNums, | |||
MarketplaceMerchantNums: coreData.MarketplaceMerchantNums, | |||
MarketplaceMerchantFunds: coreData.MarketplaceMerchantFunds, | |||
DevelopmentCommittee: coreData.DevelopmentCommittee, | |||
PublicWelfareAndCharity: coreData.PublicWelfareAndCharity, | |||
StarLevelDividends: coreData.StarLevelDividends, | |||
CommunityDividends: coreData.CommunityDividends, | |||
DestructionQuantityNums: coreData.DestructionQuantityNums, | |||
} | |||
e.OutSuc(c, resp, nil) | |||
} | |||
// UpdateEggEnergyCoreData | |||
// @Summary 制度中心-蛋蛋能量-核心数据(更新) | |||
// @Tags 蛋蛋能量 | |||
// @Description 核心数据(更新) | |||
// @Accept json | |||
// @Produce json | |||
// @param Authorization header string true "验证参数Bearer和token空格拼接" | |||
// @Param req body md.UpdateEggEnergyCoreDataReq true "需要修改的内容和 id" | |||
// @Success 200 {int} "修改数据条数" | |||
// @Failure 400 {object} md.Response "具体错误" | |||
// @Router /api/institutionalManagement/eggEnergy/coreData [POST] | |||
func UpdateEggEnergyCoreData(c *gin.Context) { | |||
var req *md.UpdateEggEnergyCoreDataReq | |||
if err1 := c.ShouldBindJSON(&req); err1 != nil { | |||
e.OutErr(c, e.ERR_INVALID_ARGS, err1.Error()) | |||
return | |||
} | |||
engine := db.Db | |||
coreDataDb := implement.NewEggEnergyCoreDataDb(engine) | |||
rule.Init(cfg.RedisAddr) | |||
_, cb, err := svc.GetEggEnergyCoreData(engine) | |||
if err != nil { | |||
return | |||
} | |||
if cb != nil { | |||
defer cb() // 释放锁 | |||
} | |||
session := engine.NewSession() | |||
defer session.Close() | |||
m := model.EggEnergyCoreData{ | |||
NowPrice: req.NowPrice, | |||
PlanetTotalValue: req.PlanetTotalValue, | |||
NowEnergyTotalNums: req.NowEnergyTotalNums, | |||
MarketplaceMerchantNums: req.MarketplaceMerchantNums, | |||
MarketplaceMerchantFunds: req.MarketplaceMerchantFunds, | |||
DevelopmentCommittee: req.DevelopmentCommittee, | |||
PublicWelfareAndCharity: req.PublicWelfareAndCharity, | |||
StarLevelDividends: req.StarLevelDividends, | |||
CommunityDividends: req.CommunityDividends, | |||
} | |||
affected, err := coreDataDb.EggEnergyCoreDataUpdateBySession(session, req.Id, &m) | |||
if err != nil { | |||
session.Rollback() | |||
e.OutErr(c, e.ERR_DB_ORM, err.Error()) | |||
return | |||
} | |||
err = session.Commit() | |||
if err != nil { | |||
session.Rollback() | |||
e.OutErr(c, e.ERR_DB_ORM, err.Error()) | |||
return | |||
} | |||
e.OutSuc(c, affected, nil) | |||
} | |||
// GetEggCoreDataList | |||
// @Summary 制度中心-蛋蛋能量-数据概览(获取) | |||
// @Tags 蛋蛋能量 | |||
@@ -47,12 +47,12 @@ func GetEggEnergyUserCoinList(c *gin.Context) { | |||
kind1 := md.VirtualCoinListNode{ | |||
Kind: 1, | |||
CoinID: eggEnergyBasicSetting.PersonEggEnergyCoinId, | |||
Name: "个人蛋蛋能量", | |||
Name: "个人能量值", | |||
} | |||
kind2 := md.VirtualCoinListNode{ | |||
Kind: 2, | |||
CoinID: eggEnergyBasicSetting.TeamEggEnergyCoinId, | |||
Name: "团队蛋蛋能量", | |||
Name: "团队能量值", | |||
} | |||
kindList[0] = kind1 | |||
kindList[1] = kind2 | |||
@@ -215,12 +215,12 @@ func GetEggPointsUserCoinList(c *gin.Context) { | |||
kind1 := md.VirtualCoinListNode{ | |||
Kind: 1, | |||
CoinID: eggEnergyBasicSetting.PersonEggPointsCoinId, | |||
Name: "个人蛋蛋积分", | |||
Name: "个人活跃值", | |||
} | |||
kind2 := md.VirtualCoinListNode{ | |||
Kind: 2, | |||
CoinID: eggEnergyBasicSetting.TeamEggPointsCoinId, | |||
Name: "团队蛋蛋积分", | |||
Name: "团队活跃值", | |||
} | |||
kindList[0] = kind1 | |||
kindList[1] = kind2 | |||
@@ -68,9 +68,7 @@ func AddTag(c *gin.Context) { | |||
TagName: req.Name, | |||
Memo: req.Memo, | |||
CreateAt: time.Now().Format("2006-01-02 15:04:05"), | |||
} | |||
if req.IsPunish == "1" { | |||
tag.IsPunish = 1 | |||
IsPunish: req.IsPunish, | |||
} | |||
tagDb := implement.NewUserTagDb(db.Db) | |||
tagID, err := tagDb.UserTagInsert(&tag) | |||
@@ -55,6 +55,7 @@ type GetEggEnergyBasicResp struct { | |||
RewardSystem []md.RewardSystemStruct `json:"reward_system"` // 圈层奖励 | |||
NewUserIncentiveRules md.NewUserRewardRules `json:"new_user_incentive_rules"` // 新用户奖励规则 | |||
SystemID int `json:"system_id"` // 该设置系统 ID | |||
SettlementQuantity int `json:"settlement_quantity"` // 结算数量(百分比) | |||
} | |||
type UpdateEggEnergyBasicReq struct { | |||
@@ -67,6 +68,7 @@ type UpdateEggEnergyBasicReq struct { | |||
ExchangeRules md.ExchangeRulesStruct `json:"exchange_rules"` // 兑换规则 | |||
RewardSystem []md.RewardSystemStruct `json:"reward_system"` // 圈层奖励 | |||
NewUserIncentiveRules md.NewUserRewardRules `json:"new_user_incentive_rules"` // 新用户奖励规则 // 新用户奖励规则 | |||
SettlementQuantity string `json:"settlement_quantity"` // 结算数量(百分比) | |||
} | |||
type AddVirtualCoinNode struct { | |||
@@ -126,6 +128,33 @@ type GetEggCoreDataListResp struct { | |||
UserHoldTotalNums string `json:"user_hold_total_nums"` // 用户持有总量 | |||
} | |||
type GetEggEnergyCoreDataResp struct { | |||
Id int `json:"id"` | |||
NowPrice string `json:"now_price"` // 当前价格 | |||
PlanetTotalValue string `json:"planet_total_value"` // 星球总价值 | |||
NowEnergyTotalNums string `json:"now_energy_total_nums"` // 现行总量 | |||
MarketplaceMerchantNums string `json:"marketplace_merchant_nums"` // 市商数量 | |||
MarketplaceMerchantFunds string `json:"marketplace_merchant_funds"` // 市商资金 | |||
DevelopmentCommittee string `json:"development_committee"` // 发展委员会 | |||
PublicWelfareAndCharity string `json:"public_welfare_and_charity"` // 公益慈善 | |||
StarLevelDividends string `json:"star_level_dividends"` // 星级分红 | |||
CommunityDividends string `json:"community_dividends"` // 社区分红 | |||
DestructionQuantityNums string `json:"destruction_quantity_nums"` // 销毁数量 | |||
} | |||
type UpdateEggEnergyCoreDataReq struct { | |||
Id int `json:"id"` | |||
NowPrice string `json:"now_price"` // 当前价格 | |||
PlanetTotalValue string `json:"planet_total_value"` // 星球总价值 | |||
NowEnergyTotalNums string `json:"now_energy_total_nums"` // 现行总量 | |||
MarketplaceMerchantNums string `json:"marketplace_merchant_nums"` // 市商数量 | |||
MarketplaceMerchantFunds string `json:"marketplace_merchant_funds"` // 市商资金 | |||
DevelopmentCommittee string `json:"development_committee"` // 发展委员会 | |||
PublicWelfareAndCharity string `json:"public_welfare_and_charity"` // 公益慈善 | |||
StarLevelDividends string `json:"star_level_dividends"` // 星级分红 | |||
CommunityDividends string `json:"community_dividends"` // 社区分红 | |||
} | |||
type GetPriceCurveResp struct { | |||
XData []interface{} `json:"x_data"` | |||
YData []interface{} `json:"y_data"` | |||
@@ -17,7 +17,7 @@ type GetTagListResp struct { | |||
type AddTagReq struct { | |||
Name string `json:"name,required"` // 标签名称 | |||
Memo string `json:"memo,required"` // 备注 | |||
IsPunish string `json:"is_punish,required"` // 是否为处罚标签(0:否 1:是) | |||
IsPunish int `json:"is_punish,required"` // 是否为处罚标签(0:否 1:是) | |||
} | |||
type UpdateTagReq struct { | |||
@@ -256,6 +256,8 @@ func rInstitutionalManagement(r *gin.RouterGroup) { //制度管理 | |||
rEggEnergy.GET("/getVipSetting", egg_energy.GetEggEnergyVipSetting) | |||
rEggEnergy.POST("/addVipSetting", egg_energy.AddEggEnergyVipSetting) | |||
rEggEnergy.POST("/updateVipSetting", egg_energy.UpdateEggEnergyVipSetting) | |||
rEggEnergy.GET("/coreData", egg_energy.GetEggEnergyCoreData) | |||
rEggEnergy.POST("/coreData", egg_energy.UpdateEggEnergyCoreData) | |||
rEggEnergyUserCoin := rEggEnergy.Group("/userCoin") | |||
{ | |||
rEggEnergyUserCoin.POST("/eggEnergyUserCoinList", egg_energy.GetEggEnergyUserCoinList) | |||
@@ -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" | |||
@@ -1609,9 +1608,7 @@ const docTemplate = `{ | |||
"name": "req", | |||
"in": "body", | |||
"required": true, | |||
"schema": { | |||
"type": "object" | |||
} | |||
"schema": {} | |||
} | |||
], | |||
"responses": { | |||
@@ -3556,6 +3553,89 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/eggEnergy/coreData": { | |||
"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.GetEggEnergyCoreDataResp" | |||
} | |||
}, | |||
"400": { | |||
"description": "具体错误", | |||
"schema": { | |||
"$ref": "#/definitions/md.Response" | |||
} | |||
} | |||
} | |||
}, | |||
"post": { | |||
"description": "核心数据(更新)", | |||
"consumes": [ | |||
"application/json" | |||
], | |||
"produces": [ | |||
"application/json" | |||
], | |||
"tags": [ | |||
"蛋蛋能量" | |||
], | |||
"summary": "制度中心-蛋蛋能量-核心数据(更新)", | |||
"parameters": [ | |||
{ | |||
"type": "string", | |||
"description": "验证参数Bearer和token空格拼接", | |||
"name": "Authorization", | |||
"in": "header", | |||
"required": true | |||
}, | |||
{ | |||
"description": "需要修改的内容和 id", | |||
"name": "req", | |||
"in": "body", | |||
"required": true, | |||
"schema": { | |||
"$ref": "#/definitions/md.UpdateEggEnergyCoreDataReq" | |||
} | |||
} | |||
], | |||
"responses": { | |||
"200": { | |||
"description": "修改数据条数", | |||
"schema": { | |||
"type": "int" | |||
} | |||
}, | |||
"400": { | |||
"description": "具体错误", | |||
"schema": { | |||
"$ref": "#/definitions/md.Response" | |||
} | |||
} | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/eggEnergy/deleteVirtualCoin/{$id}": { | |||
"delete": { | |||
"description": "删除币种", | |||
@@ -9976,7 +10056,7 @@ const docTemplate = `{ | |||
"properties": { | |||
"is_punish": { | |||
"description": "是否为处罚标签(0:否 1:是)", | |||
"type": "string" | |||
"type": "integer" | |||
}, | |||
"memo": { | |||
"description": "备注", | |||
@@ -12284,6 +12364,10 @@ const docTemplate = `{ | |||
"$ref": "#/definitions/md.RewardSystemStruct" | |||
} | |||
}, | |||
"settlement_quantity": { | |||
"description": "结算数量(百分比)", | |||
"type": "integer" | |||
}, | |||
"system_id": { | |||
"description": "该设置系统 ID", | |||
"type": "integer" | |||
@@ -12298,6 +12382,50 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"md.GetEggEnergyCoreDataResp": { | |||
"type": "object", | |||
"properties": { | |||
"community_dividends": { | |||
"description": "社区分红", | |||
"type": "string" | |||
}, | |||
"development_committee": { | |||
"description": "发展委员会", | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"marketplace_merchant_funds": { | |||
"description": "市商资金", | |||
"type": "string" | |||
}, | |||
"marketplace_merchant_nums": { | |||
"description": "市商数量", | |||
"type": "string" | |||
}, | |||
"now_energy_total_nums": { | |||
"description": "现行总量", | |||
"type": "string" | |||
}, | |||
"now_price": { | |||
"description": "当前价格", | |||
"type": "string" | |||
}, | |||
"planet_total_value": { | |||
"description": "星球总价值", | |||
"type": "string" | |||
}, | |||
"public_welfare_and_charity": { | |||
"description": "公益慈善", | |||
"type": "string" | |||
}, | |||
"star_level_dividends": { | |||
"description": "星级分红", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.GetEggEnergyVipSettingResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -15062,6 +15190,10 @@ const docTemplate = `{ | |||
"$ref": "#/definitions/md.RewardSystemStruct" | |||
} | |||
}, | |||
"settlement_quantity": { | |||
"description": "结算数量(百分比)", | |||
"type": "string" | |||
}, | |||
"system_id": { | |||
"description": "该设置系统 ID", | |||
"type": "integer" | |||
@@ -15076,6 +15208,50 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"md.UpdateEggEnergyCoreDataReq": { | |||
"type": "object", | |||
"properties": { | |||
"community_dividends": { | |||
"description": "社区分红", | |||
"type": "string" | |||
}, | |||
"development_committee": { | |||
"description": "发展委员会", | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"marketplace_merchant_funds": { | |||
"description": "市商资金", | |||
"type": "string" | |||
}, | |||
"marketplace_merchant_nums": { | |||
"description": "市商数量", | |||
"type": "string" | |||
}, | |||
"now_energy_total_nums": { | |||
"description": "现行总量", | |||
"type": "string" | |||
}, | |||
"now_price": { | |||
"description": "当前价格", | |||
"type": "string" | |||
}, | |||
"planet_total_value": { | |||
"description": "星球总价值", | |||
"type": "string" | |||
}, | |||
"public_welfare_and_charity": { | |||
"description": "公益慈善", | |||
"type": "string" | |||
}, | |||
"star_level_dividends": { | |||
"description": "星级分红", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.UpdateEggEnergyVipSettingReq": { | |||
"type": "object", | |||
"properties": { | |||
@@ -16935,6 +17111,8 @@ var SwaggerInfo = &swag.Spec{ | |||
Description: "管理后台接口文档", | |||
InfoInstanceName: "swagger", | |||
SwaggerTemplate: docTemplate, | |||
LeftDelim: "{{", | |||
RightDelim: "}}", | |||
} | |||
func init() { | |||
@@ -1601,9 +1601,7 @@ | |||
"name": "req", | |||
"in": "body", | |||
"required": true, | |||
"schema": { | |||
"type": "object" | |||
} | |||
"schema": {} | |||
} | |||
], | |||
"responses": { | |||
@@ -3548,6 +3546,89 @@ | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/eggEnergy/coreData": { | |||
"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.GetEggEnergyCoreDataResp" | |||
} | |||
}, | |||
"400": { | |||
"description": "具体错误", | |||
"schema": { | |||
"$ref": "#/definitions/md.Response" | |||
} | |||
} | |||
} | |||
}, | |||
"post": { | |||
"description": "核心数据(更新)", | |||
"consumes": [ | |||
"application/json" | |||
], | |||
"produces": [ | |||
"application/json" | |||
], | |||
"tags": [ | |||
"蛋蛋能量" | |||
], | |||
"summary": "制度中心-蛋蛋能量-核心数据(更新)", | |||
"parameters": [ | |||
{ | |||
"type": "string", | |||
"description": "验证参数Bearer和token空格拼接", | |||
"name": "Authorization", | |||
"in": "header", | |||
"required": true | |||
}, | |||
{ | |||
"description": "需要修改的内容和 id", | |||
"name": "req", | |||
"in": "body", | |||
"required": true, | |||
"schema": { | |||
"$ref": "#/definitions/md.UpdateEggEnergyCoreDataReq" | |||
} | |||
} | |||
], | |||
"responses": { | |||
"200": { | |||
"description": "修改数据条数", | |||
"schema": { | |||
"type": "int" | |||
} | |||
}, | |||
"400": { | |||
"description": "具体错误", | |||
"schema": { | |||
"$ref": "#/definitions/md.Response" | |||
} | |||
} | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/eggEnergy/deleteVirtualCoin/{$id}": { | |||
"delete": { | |||
"description": "删除币种", | |||
@@ -9968,7 +10049,7 @@ | |||
"properties": { | |||
"is_punish": { | |||
"description": "是否为处罚标签(0:否 1:是)", | |||
"type": "string" | |||
"type": "integer" | |||
}, | |||
"memo": { | |||
"description": "备注", | |||
@@ -12276,6 +12357,10 @@ | |||
"$ref": "#/definitions/md.RewardSystemStruct" | |||
} | |||
}, | |||
"settlement_quantity": { | |||
"description": "结算数量(百分比)", | |||
"type": "integer" | |||
}, | |||
"system_id": { | |||
"description": "该设置系统 ID", | |||
"type": "integer" | |||
@@ -12290,6 +12375,50 @@ | |||
} | |||
} | |||
}, | |||
"md.GetEggEnergyCoreDataResp": { | |||
"type": "object", | |||
"properties": { | |||
"community_dividends": { | |||
"description": "社区分红", | |||
"type": "string" | |||
}, | |||
"development_committee": { | |||
"description": "发展委员会", | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"marketplace_merchant_funds": { | |||
"description": "市商资金", | |||
"type": "string" | |||
}, | |||
"marketplace_merchant_nums": { | |||
"description": "市商数量", | |||
"type": "string" | |||
}, | |||
"now_energy_total_nums": { | |||
"description": "现行总量", | |||
"type": "string" | |||
}, | |||
"now_price": { | |||
"description": "当前价格", | |||
"type": "string" | |||
}, | |||
"planet_total_value": { | |||
"description": "星球总价值", | |||
"type": "string" | |||
}, | |||
"public_welfare_and_charity": { | |||
"description": "公益慈善", | |||
"type": "string" | |||
}, | |||
"star_level_dividends": { | |||
"description": "星级分红", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.GetEggEnergyVipSettingResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -15054,6 +15183,10 @@ | |||
"$ref": "#/definitions/md.RewardSystemStruct" | |||
} | |||
}, | |||
"settlement_quantity": { | |||
"description": "结算数量(百分比)", | |||
"type": "string" | |||
}, | |||
"system_id": { | |||
"description": "该设置系统 ID", | |||
"type": "integer" | |||
@@ -15068,6 +15201,50 @@ | |||
} | |||
} | |||
}, | |||
"md.UpdateEggEnergyCoreDataReq": { | |||
"type": "object", | |||
"properties": { | |||
"community_dividends": { | |||
"description": "社区分红", | |||
"type": "string" | |||
}, | |||
"development_committee": { | |||
"description": "发展委员会", | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"marketplace_merchant_funds": { | |||
"description": "市商资金", | |||
"type": "string" | |||
}, | |||
"marketplace_merchant_nums": { | |||
"description": "市商数量", | |||
"type": "string" | |||
}, | |||
"now_energy_total_nums": { | |||
"description": "现行总量", | |||
"type": "string" | |||
}, | |||
"now_price": { | |||
"description": "当前价格", | |||
"type": "string" | |||
}, | |||
"planet_total_value": { | |||
"description": "星球总价值", | |||
"type": "string" | |||
}, | |||
"public_welfare_and_charity": { | |||
"description": "公益慈善", | |||
"type": "string" | |||
}, | |||
"star_level_dividends": { | |||
"description": "星级分红", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.UpdateEggEnergyVipSettingReq": { | |||
"type": "object", | |||
"properties": { | |||
@@ -510,7 +510,7 @@ definitions: | |||
properties: | |||
is_punish: | |||
description: 是否为处罚标签(0:否 1:是) | |||
type: string | |||
type: integer | |||
memo: | |||
description: 备注 | |||
type: string | |||
@@ -2091,6 +2091,9 @@ definitions: | |||
items: | |||
$ref: '#/definitions/md.RewardSystemStruct' | |||
type: array | |||
settlement_quantity: | |||
description: 结算数量(百分比) | |||
type: integer | |||
system_id: | |||
description: 该设置系统 ID | |||
type: integer | |||
@@ -2099,6 +2102,38 @@ definitions: | |||
- $ref: '#/definitions/md.VideoRewardSetting' | |||
description: 视频奖励 | |||
type: object | |||
md.GetEggEnergyCoreDataResp: | |||
properties: | |||
community_dividends: | |||
description: 社区分红 | |||
type: string | |||
development_committee: | |||
description: 发展委员会 | |||
type: string | |||
id: | |||
type: integer | |||
marketplace_merchant_funds: | |||
description: 市商资金 | |||
type: string | |||
marketplace_merchant_nums: | |||
description: 市商数量 | |||
type: string | |||
now_energy_total_nums: | |||
description: 现行总量 | |||
type: string | |||
now_price: | |||
description: 当前价格 | |||
type: string | |||
planet_total_value: | |||
description: 星球总价值 | |||
type: string | |||
public_welfare_and_charity: | |||
description: 公益慈善 | |||
type: string | |||
star_level_dividends: | |||
description: 星级分红 | |||
type: string | |||
type: object | |||
md.GetEggEnergyVipSettingResp: | |||
properties: | |||
level_list: | |||
@@ -4030,6 +4065,9 @@ definitions: | |||
items: | |||
$ref: '#/definitions/md.RewardSystemStruct' | |||
type: array | |||
settlement_quantity: | |||
description: 结算数量(百分比) | |||
type: string | |||
system_id: | |||
description: 该设置系统 ID | |||
type: integer | |||
@@ -4038,6 +4076,38 @@ definitions: | |||
- $ref: '#/definitions/md.VideoRewardSetting' | |||
description: 视频奖励 | |||
type: object | |||
md.UpdateEggEnergyCoreDataReq: | |||
properties: | |||
community_dividends: | |||
description: 社区分红 | |||
type: string | |||
development_committee: | |||
description: 发展委员会 | |||
type: string | |||
id: | |||
type: integer | |||
marketplace_merchant_funds: | |||
description: 市商资金 | |||
type: string | |||
marketplace_merchant_nums: | |||
description: 市商数量 | |||
type: string | |||
now_energy_total_nums: | |||
description: 现行总量 | |||
type: string | |||
now_price: | |||
description: 当前价格 | |||
type: string | |||
planet_total_value: | |||
description: 星球总价值 | |||
type: string | |||
public_welfare_and_charity: | |||
description: 公益慈善 | |||
type: string | |||
star_level_dividends: | |||
description: 星级分红 | |||
type: string | |||
type: object | |||
md.UpdateEggEnergyVipSettingReq: | |||
properties: | |||
list: | |||
@@ -6367,8 +6437,7 @@ paths: | |||
in: body | |||
name: req | |||
required: true | |||
schema: | |||
type: object | |||
schema: {} | |||
produces: | |||
- application/json | |||
responses: | |||
@@ -7655,6 +7724,61 @@ paths: | |||
summary: 制度中心-蛋蛋能量-贡献值-基础设置(更新) | |||
tags: | |||
- 贡献值 | |||
/api/institutionalManagement/eggEnergy/coreData: | |||
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.GetEggEnergyCoreDataResp' | |||
"400": | |||
description: 具体错误 | |||
schema: | |||
$ref: '#/definitions/md.Response' | |||
summary: 制度中心-蛋蛋能量-核心数据(获取) | |||
tags: | |||
- 蛋蛋能量 | |||
post: | |||
consumes: | |||
- application/json | |||
description: 核心数据(更新) | |||
parameters: | |||
- description: 验证参数Bearer和token空格拼接 | |||
in: header | |||
name: Authorization | |||
required: true | |||
type: string | |||
- description: 需要修改的内容和 id | |||
in: body | |||
name: req | |||
required: true | |||
schema: | |||
$ref: '#/definitions/md.UpdateEggEnergyCoreDataReq' | |||
produces: | |||
- application/json | |||
responses: | |||
"200": | |||
description: 修改数据条数 | |||
schema: | |||
type: int | |||
"400": | |||
description: 具体错误 | |||
schema: | |||
$ref: '#/definitions/md.Response' | |||
summary: 制度中心-蛋蛋能量-核心数据(更新) | |||
tags: | |||
- 蛋蛋能量 | |||
/api/institutionalManagement/eggEnergy/deleteVirtualCoin/{$id}: | |||
delete: | |||
consumes: | |||
@@ -33,8 +33,8 @@ require ( | |||
) | |||
require ( | |||
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241214095356-fdac2df9537f | |||
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241214095427-b3f9e6ed2446 | |||
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241214062221-cde2ce240fa8 | |||
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241214075617-9e3855ecf0c0 | |||
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 | |||