作者 tangxuhui

数据结构调整

... ... @@ -25,8 +25,12 @@ type CooperationContractItem struct {
}
func ToCooperationContractItem(param *allied_creation_cooperation.CooperationContract) *CooperationContractItem {
cooperationContractUndertakerType := param.CooperationContractUndertakerTypes
if len(cooperationContractUndertakerType) == 0 {
cooperationContractUndertakerType = []int{}
}
data := CooperationContractItem{
CooperationContractUndertakerType: param.CooperationContractUndertakerTypes,
CooperationContractUndertakerType: cooperationContractUndertakerType,
CooperationContractDescription: param.CooperationContractDescription,
CooperationContractId: param.CooperationContractId,
CooperationProjectNumber: param.CooperationContractNumber,
... ... @@ -177,17 +181,17 @@ func ToCooperationContractInfo(param *allied_creation_cooperation.CooperationCon
}
contractUndertaker = append(contractUndertaker, u)
}
undertakerTypesUncheckedAvailable := param.UndertakerTypesUncheckedAvailable
if len(undertakerTypesUncheckedAvailable) == 0 {
undertakerTypesUncheckedAvailable = []int{}
}
data := CooperationContractInfo{
CooperationContract: *ToCooperationContractItem(param),
Relevant: relevants,
DividendsIncentivesRules: dividendsIncentivesRules,
MoneyIncentivesRules: moneyIncentivesRules,
ContractUndertaker: contractUndertaker,
UndertakerTypesUncheckedAvailable: param.UndertakerTypesUncheckedAvailable,
}
if len(param.UndertakerTypesUncheckedAvailable) == 0 {
data.UndertakerTypesUncheckedAvailable = []int{}
UndertakerTypesUncheckedAvailable: undertakerTypesUncheckedAvailable,
}
return &data
... ...
... ... @@ -37,6 +37,7 @@ func ToDividendsEstimateDividendItem(param *allied_creation_cooperation.DataDivi
return listdata
}
//金额激励列表
type DividendsEstimateMoneyItem struct {
CooperationContractName string `json:"cooperationContractName"` //合约名称
CooperationContractNumber string `json:"cooperationContractNumber"` //合约编码
... ...