@@ -72,40 +72,40 @@ func DynamicDataFlowList(c *gin.Context) { | |||
e.OutErr(c, e.ERR_DB_ORM, err.Error()) | |||
return | |||
} | |||
list := make([]md.EggEnergyAvailableEnergyFlow, len(flows)) | |||
for i, flow := range flows { | |||
list[i] = md.EggEnergyAvailableEnergyFlow{ | |||
Id: flow.Id, | |||
Kind: flow.Kind, | |||
Title: flow.Title, | |||
BeforePrice: flow.BeforePrice, | |||
AfterPrice: flow.AfterPrice, | |||
Amount: flow.Amount, | |||
BeforeNowEnergyTotalNums: flow.BeforeNowEnergyTotalNums, | |||
AfterNowEnergyTotalNums: flow.AfterNowEnergyTotalNums, | |||
AfterPlanetTotalValue: flow.AfterPlanetTotalValue, | |||
BeforePlanetTotalValue: flow.BeforePlanetTotalValue, | |||
BeforeMarketplaceMerchantValues: flow.BeforeMarketplaceMerchantValues, | |||
AfterMarketplaceMerchantValues: flow.AfterMarketplaceMerchantValues, | |||
BeforeMarketplaceMerchantFundValues: flow.BeforeMarketplaceMerchantFundValues, | |||
AfterMarketplaceMerchantFundValues: flow.AfterMarketplaceMerchantFundValues, | |||
BeforeDevelopmentCommitteeValues: flow.BeforeDevelopmentCommitteeValues, | |||
AfterDevelopmentCommitteeValues: flow.AfterDevelopmentCommitteeValues, | |||
BeforePublicWelfareAndCharityValues: flow.BeforePublicWelfareAndCharityValues, | |||
AfterPublicWelfareAndCharityValues: flow.AfterPublicWelfareAndCharityValues, | |||
BeforeStarLevelDividendsValues: flow.BeforeStarLevelDividendsValues, | |||
AfterStarLevelDividendsValues: flow.AfterStarLevelDividendsValues, | |||
BeforeDestructionQuantityValues: flow.BeforeDestructionQuantityValues, | |||
AfterDestructionQuantityValues: flow.AfterDestructionQuantityValues, | |||
BeforeCommunityDividends: flow.BeforeCommunityDividends, | |||
AfterCommunityDividends: flow.AfterCommunityDividends, | |||
CreateTime: flow.CreateTime, | |||
} | |||
} | |||
//list := make([]md.EggEnergyAvailableEnergyFlow, len(flows)) | |||
//for i, flow := range flows { | |||
// list[i] = md.EggEnergyAvailableEnergyFlow{ | |||
// Id: flow.Id, | |||
// Kind: flow.Kind, | |||
// Title: flow.Title, | |||
// BeforePrice: flow.BeforePrice, | |||
// AfterPrice: flow.AfterPrice, | |||
// Amount: flow.Amount, | |||
// BeforeNowEnergyTotalNums: flow.BeforeNowEnergyTotalNums, | |||
// AfterNowEnergyTotalNums: flow.AfterNowEnergyTotalNums, | |||
// AfterPlanetTotalValue: flow.AfterPlanetTotalValue, | |||
// BeforePlanetTotalValue: flow.BeforePlanetTotalValue, | |||
// BeforeMarketplaceMerchantValues: flow.BeforeMarketplaceMerchantValues, | |||
// AfterMarketplaceMerchantValues: flow.AfterMarketplaceMerchantValues, | |||
// BeforeMarketplaceMerchantFundValues: flow.BeforeMarketplaceMerchantFundValues, | |||
// AfterMarketplaceMerchantFundValues: flow.AfterMarketplaceMerchantFundValues, | |||
// BeforeDevelopmentCommitteeValues: flow.BeforeDevelopmentCommitteeValues, | |||
// AfterDevelopmentCommitteeValues: flow.AfterDevelopmentCommitteeValues, | |||
// BeforePublicWelfareAndCharityValues: flow.BeforePublicWelfareAndCharityValues, | |||
// AfterPublicWelfareAndCharityValues: flow.AfterPublicWelfareAndCharityValues, | |||
// BeforeStarLevelDividendsValues: flow.BeforeStarLevelDividendsValues, | |||
// AfterStarLevelDividendsValues: flow.AfterStarLevelDividendsValues, | |||
// BeforeDestructionQuantityValues: flow.BeforeDestructionQuantityValues, | |||
// AfterDestructionQuantityValues: flow.AfterDestructionQuantityValues, | |||
// BeforeCommunityDividends: flow.BeforeCommunityDividends, | |||
// AfterCommunityDividends: flow.AfterCommunityDividends, | |||
// CreateTime: flow.CreateTime, | |||
// } | |||
//} | |||
resp := md.DynamicDataFlowListResp{ | |||
KindList: kindList, | |||
List: list, | |||
List: flows, | |||
Paginate: md.Paginate{ | |||
Limit: req.PageSize, | |||
Page: req.Page, | |||
@@ -1,5 +1,7 @@ | |||
package md | |||
import "code.fnuoos.com/EggPlanet/egg_models.git/src/model" | |||
type DynamicDataFlowListReq struct { | |||
Kind int `json:"kind"` // 持有类型 | |||
Page int `json:"page,required"` // 页数 | |||
@@ -37,7 +39,7 @@ type EggEnergyAvailableEnergyFlow struct { | |||
} | |||
type DynamicDataFlowListResp struct { | |||
KindList []map[string]interface{} `json:"kind_list"` | |||
List []EggEnergyAvailableEnergyFlow `json:"list"` | |||
Paginate Paginate `json:"paginate"` | |||
KindList []map[string]interface{} `json:"kind_list"` | |||
List []*model.EggEnergyAvailableEnergyFlow `json:"list"` | |||
Paginate Paginate `json:"paginate"` | |||
} |
@@ -63,7 +63,7 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/availableEnergy/list": { | |||
"/api/institutionalManagement/eggEnergy/availableEnergy/list": { | |||
"post": { | |||
"description": "动态数据流水(获取)", | |||
"consumes": [ | |||
@@ -1088,7 +1088,8 @@ const docTemplate = `{ | |||
"properties": { | |||
"end_at": { | |||
"description": "结束时间", | |||
"type": "string" | |||
"type": "string", | |||
"example": "结束时间" | |||
}, | |||
"kind": { | |||
"description": "持有类型", | |||
@@ -1104,7 +1105,8 @@ const docTemplate = `{ | |||
}, | |||
"start_at": { | |||
"description": "开始时间", | |||
"type": "string" | |||
"type": "string", | |||
"example": "开始时间" | |||
} | |||
} | |||
}, | |||
@@ -1121,7 +1123,7 @@ const docTemplate = `{ | |||
"list": { | |||
"type": "array", | |||
"items": { | |||
"$ref": "#/definitions/md.EggEnergyAvailableEnergyFlow" | |||
"$ref": "#/definitions/model.EggEnergyAvailableEnergyFlow" | |||
} | |||
}, | |||
"paginate": { | |||
@@ -1129,89 +1131,6 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"md.EggEnergyAvailableEnergyFlow": { | |||
"type": "object", | |||
"properties": { | |||
"after_community_dividends": { | |||
"type": "string" | |||
}, | |||
"after_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"after_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"after_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"after_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"after_price": { | |||
"type": "string" | |||
}, | |||
"after_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"after_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"before_community_dividends": { | |||
"type": "string" | |||
}, | |||
"before_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"before_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"before_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"before_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"before_price": { | |||
"type": "string" | |||
}, | |||
"before_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"before_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"coin_id": { | |||
"type": "integer" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"kind": { | |||
"type": "integer" | |||
}, | |||
"title": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.EggEnergyCommunityDividends": { | |||
"type": "object", | |||
"properties": { | |||
@@ -2012,6 +1931,86 @@ const docTemplate = `{ | |||
"example": "货币类型名称" | |||
} | |||
} | |||
}, | |||
"model.EggEnergyAvailableEnergyFlow": { | |||
"type": "object", | |||
"properties": { | |||
"after_community_dividends": { | |||
"type": "string" | |||
}, | |||
"after_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"after_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"after_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"after_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"after_price": { | |||
"type": "string" | |||
}, | |||
"after_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"after_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"before_community_dividends": { | |||
"type": "string" | |||
}, | |||
"before_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"before_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"before_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"before_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"before_price": { | |||
"type": "string" | |||
}, | |||
"before_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"before_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"kind": { | |||
"type": "integer" | |||
}, | |||
"title": { | |||
"type": "string" | |||
} | |||
} | |||
} | |||
}, | |||
"securityDefinitions": { | |||
@@ -56,7 +56,7 @@ | |||
} | |||
} | |||
}, | |||
"/api/institutionalManagement/availableEnergy/list": { | |||
"/api/institutionalManagement/eggEnergy/availableEnergy/list": { | |||
"post": { | |||
"description": "动态数据流水(获取)", | |||
"consumes": [ | |||
@@ -1081,7 +1081,8 @@ | |||
"properties": { | |||
"end_at": { | |||
"description": "结束时间", | |||
"type": "string" | |||
"type": "string", | |||
"example": "结束时间" | |||
}, | |||
"kind": { | |||
"description": "持有类型", | |||
@@ -1097,7 +1098,8 @@ | |||
}, | |||
"start_at": { | |||
"description": "开始时间", | |||
"type": "string" | |||
"type": "string", | |||
"example": "开始时间" | |||
} | |||
} | |||
}, | |||
@@ -1114,7 +1116,7 @@ | |||
"list": { | |||
"type": "array", | |||
"items": { | |||
"$ref": "#/definitions/md.EggEnergyAvailableEnergyFlow" | |||
"$ref": "#/definitions/model.EggEnergyAvailableEnergyFlow" | |||
} | |||
}, | |||
"paginate": { | |||
@@ -1122,89 +1124,6 @@ | |||
} | |||
} | |||
}, | |||
"md.EggEnergyAvailableEnergyFlow": { | |||
"type": "object", | |||
"properties": { | |||
"after_community_dividends": { | |||
"type": "string" | |||
}, | |||
"after_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"after_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"after_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"after_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"after_price": { | |||
"type": "string" | |||
}, | |||
"after_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"after_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"before_community_dividends": { | |||
"type": "string" | |||
}, | |||
"before_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"before_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"before_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"before_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"before_price": { | |||
"type": "string" | |||
}, | |||
"before_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"before_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"coin_id": { | |||
"type": "integer" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"kind": { | |||
"type": "integer" | |||
}, | |||
"title": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.EggEnergyCommunityDividends": { | |||
"type": "object", | |||
"properties": { | |||
@@ -2005,6 +1924,86 @@ | |||
"example": "货币类型名称" | |||
} | |||
} | |||
}, | |||
"model.EggEnergyAvailableEnergyFlow": { | |||
"type": "object", | |||
"properties": { | |||
"after_community_dividends": { | |||
"type": "string" | |||
}, | |||
"after_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"after_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"after_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"after_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"after_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"after_price": { | |||
"type": "string" | |||
}, | |||
"after_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"after_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"before_community_dividends": { | |||
"type": "string" | |||
}, | |||
"before_destruction_quantity_values": { | |||
"type": "string" | |||
}, | |||
"before_development_committee_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_fund_values": { | |||
"type": "string" | |||
}, | |||
"before_marketplace_merchant_values": { | |||
"type": "string" | |||
}, | |||
"before_now_energy_total_nums": { | |||
"type": "string" | |||
}, | |||
"before_planet_total_value": { | |||
"type": "string" | |||
}, | |||
"before_price": { | |||
"type": "string" | |||
}, | |||
"before_public_welfare_and_charity_values": { | |||
"type": "string" | |||
}, | |||
"before_star_level_dividends_values": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"kind": { | |||
"type": "integer" | |||
}, | |||
"title": { | |||
"type": "string" | |||
} | |||
} | |||
} | |||
}, | |||
"securityDefinitions": { | |||
@@ -103,6 +103,7 @@ definitions: | |||
properties: | |||
end_at: | |||
description: 结束时间 | |||
example: 结束时间 | |||
type: string | |||
kind: | |||
description: 持有类型 | |||
@@ -115,6 +116,7 @@ definitions: | |||
type: integer | |||
start_at: | |||
description: 开始时间 | |||
example: 开始时间 | |||
type: string | |||
type: object | |||
md.DynamicDataFlowListResp: | |||
@@ -126,66 +128,11 @@ definitions: | |||
type: array | |||
list: | |||
items: | |||
$ref: '#/definitions/md.EggEnergyAvailableEnergyFlow' | |||
$ref: '#/definitions/model.EggEnergyAvailableEnergyFlow' | |||
type: array | |||
paginate: | |||
$ref: '#/definitions/applet_app_md_institutional_management_egg_energy.Paginate' | |||
type: object | |||
md.EggEnergyAvailableEnergyFlow: | |||
properties: | |||
after_community_dividends: | |||
type: string | |||
after_destruction_quantity_values: | |||
type: string | |||
after_development_committee_values: | |||
type: string | |||
after_marketplace_merchant_fund_values: | |||
type: string | |||
after_marketplace_merchant_values: | |||
type: string | |||
after_now_energy_total_nums: | |||
type: string | |||
after_planet_total_value: | |||
type: string | |||
after_price: | |||
type: string | |||
after_public_welfare_and_charity_values: | |||
type: string | |||
after_star_level_dividends_values: | |||
type: string | |||
amount: | |||
type: string | |||
before_community_dividends: | |||
type: string | |||
before_destruction_quantity_values: | |||
type: string | |||
before_development_committee_values: | |||
type: string | |||
before_marketplace_merchant_fund_values: | |||
type: string | |||
before_marketplace_merchant_values: | |||
type: string | |||
before_now_energy_total_nums: | |||
type: string | |||
before_planet_total_value: | |||
type: string | |||
before_price: | |||
type: string | |||
before_public_welfare_and_charity_values: | |||
type: string | |||
before_star_level_dividends_values: | |||
type: string | |||
coin_id: | |||
type: integer | |||
create_time: | |||
type: string | |||
id: | |||
type: integer | |||
kind: | |||
type: integer | |||
title: | |||
type: string | |||
type: object | |||
md.EggEnergyCommunityDividends: | |||
properties: | |||
coin_id: | |||
@@ -737,6 +684,59 @@ definitions: | |||
example: 货币类型名称 | |||
type: string | |||
type: object | |||
model.EggEnergyAvailableEnergyFlow: | |||
properties: | |||
after_community_dividends: | |||
type: string | |||
after_destruction_quantity_values: | |||
type: string | |||
after_development_committee_values: | |||
type: string | |||
after_marketplace_merchant_fund_values: | |||
type: string | |||
after_marketplace_merchant_values: | |||
type: string | |||
after_now_energy_total_nums: | |||
type: string | |||
after_planet_total_value: | |||
type: string | |||
after_price: | |||
type: string | |||
after_public_welfare_and_charity_values: | |||
type: string | |||
after_star_level_dividends_values: | |||
type: string | |||
amount: | |||
type: string | |||
before_community_dividends: | |||
type: string | |||
before_destruction_quantity_values: | |||
type: string | |||
before_development_committee_values: | |||
type: string | |||
before_marketplace_merchant_fund_values: | |||
type: string | |||
before_marketplace_merchant_values: | |||
type: string | |||
before_now_energy_total_nums: | |||
type: string | |||
before_planet_total_value: | |||
type: string | |||
before_price: | |||
type: string | |||
before_public_welfare_and_charity_values: | |||
type: string | |||
before_star_level_dividends_values: | |||
type: string | |||
create_time: | |||
type: string | |||
id: | |||
type: integer | |||
kind: | |||
type: integer | |||
title: | |||
type: string | |||
type: object | |||
host: localhost:4001 | |||
info: | |||
contact: | |||
@@ -777,7 +777,7 @@ paths: | |||
summary: Demo测试 | |||
tags: | |||
- Demo | |||
/api/institutionalManagement/availableEnergy/list: | |||
/api/institutionalManagement/eggEnergy/availableEnergy/list: | |||
post: | |||
consumes: | |||
- application/json | |||