Browse Source

Merge branch 'master' of http://git.shengws.com/csx/gdyb

csx 3 years ago
parent
commit
2f69dc73a6
1 changed files with 12 additions and 4 deletions
  1. 12 4
      controllers/sg/his_api_controller.go

+ 12 - 4
controllers/sg/his_api_controller.go View File

1069
 		json.Unmarshal([]byte(order.SetlDetail), &rf)
1069
 		json.Unmarshal([]byte(order.SetlDetail), &rf)
1070
 
1070
 
1071
 		var tempFunPays []service.CustomStruct
1071
 		var tempFunPays []service.CustomStruct
1072
+		var tempFunPay610100 service.CustomStruct
1073
+
1072
 		for _, item := range rf {
1074
 		for _, item := range rf {
1073
-			var tempFunPay service.CustomStruct
1074
-			tempFunPay.FundPayamt = item.FundPayamt
1075
-			tempFunPay.FundPayType = item.FundPayType
1076
-			tempFunPays = append(tempFunPays, tempFunPay)
1075
+			if item.FundPayType == "610100" {
1076
+				tempFunPay610100.FundPayamt = tempFunPay610100.FundPayamt + item.FundPayamt
1077
+				tempFunPay610100.FundPayType = item.FundPayType
1078
+			} else {
1079
+				var tempFunPay service.CustomStruct
1080
+				tempFunPay.FundPayamt = item.FundPayamt
1081
+				tempFunPay.FundPayType = item.FundPayType
1082
+				tempFunPays = append(tempFunPays, tempFunPay)
1083
+			}
1077
 		}
1084
 		}
1085
+		tempFunPays = append(tempFunPays, tempFunPay610100)
1078
 		struct4101.CustomStruct = tempFunPays
1086
 		struct4101.CustomStruct = tempFunPays
1079
 
1087
 
1080
 		var tempOpspdiseinfos []service.OpspdiseinfoStruct
1088
 		var tempOpspdiseinfos []service.OpspdiseinfoStruct