作者 yangfu
... ... @@ -49,4 +49,5 @@ type PersonSearchCooperationProjectQuery struct {
PageSize int `json:"pageSize" valid:"Required"`
//
OrgId int64 `json:"orgId"`
Keyword string `json:"keyword"`
}
... ...
... ... @@ -111,6 +111,7 @@ func (srv CooperationProjectService) PersonSearchCooperationProject(projectQuery
PageSize: projectQuery.PageSize,
OrgId: projectQuery.OrgId,
Status: 1, //搜索状态为“招标中”项目
Keyword: projectQuery.Keyword,
//UserBaseId: projectQuery.Operator.UserBaseId,
})
if err != nil {
... ...
... ... @@ -28,8 +28,8 @@ func (dividendsOrderService *DividendsOrderService) CreateDividendsOrder(createD
OrderGoodPrice: v.OrderGoodPrice,
OrderGoodQuantity: v.OrderGoodQuantity,
}
orderGoodAmount := v.OrderGoodPrice*float64(v.OrderGoodQuantity) - v.OrderGoodExpense
good.OrderGoodAmount = orderGoodAmount
// orderGoodAmount := v.OrderGoodPrice*float64(v.OrderGoodQuantity) - v.OrderGoodExpense
// good.OrderGoodAmount = orderGoodAmount
orderGoods = append(orderGoods, good)
}
creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(createDividendsOrderCommand.Operator)
... ... @@ -114,8 +114,8 @@ func (dividendsOrderService *DividendsOrderService) UpdateDividendsOrder(updateD
OrderGoodPrice: v.OrderGoodPrice,
OrderGoodQuantity: v.OrderGoodQuantity,
}
orderGoodAmount := v.OrderGoodPrice*float64(v.OrderGoodQuantity) - v.OrderGoodExpense
good.OrderGoodAmount = orderGoodAmount
// orderGoodAmount := v.OrderGoodPrice*float64(v.OrderGoodQuantity) - v.OrderGoodExpense
// good.OrderGoodAmount = orderGoodAmount
orderGoods = append(orderGoods, good)
}
creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(updateDividendsOrderCommand.Operator)
... ...
... ... @@ -12,7 +12,7 @@ type UpdateDividendsReturnedOrderCommand struct {
DividendsOrderNumber string `json:"dividendsOrderNumber"` //分红单号
OriginalOrderNum string `json:"originalOrderNum"` //源单号
OrderGoods []struct {
OrderGoodId int64 `json:"orderGoodId,string"` // 订单产品id
OrderGoodId int `json:"orderGoodId,string"` // 订单产品id
CooperationContractNumber string `json:"cooperationContractNumber"` //关联的共创合约编号
// OrderGoodAmount float64 `json:"orderGoodAmount"` //订单产品金额
OrderGoodName string `json:"orderGoodName"` //订单产品名称
... ...
... ... @@ -21,13 +21,14 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) CreateDivide
var orderGooods []allied_creation_cooperation.ReqDividendsReturnedOrderGood
for _, v := range createDividendsReturnedOrderCommand.OrderGoods {
good := allied_creation_cooperation.ReqDividendsReturnedOrderGood{
OrderGoodId: "0",
CooperationContractNumber: v.CooperationContractNumber,
OrderGoodAmount: 0,
OrderGoodName: v.OrderGoodName,
OrderGoodPrice: v.OrderGoodPrice,
OrderGoodQuantity: v.OrderGoodQuantity,
}
good.OrderGoodAmount = good.OrderGoodPrice * float64(good.OrderGoodQuantity)
// good.OrderGoodAmount = good.OrderGoodPrice * float64(good.OrderGoodQuantity)
orderGooods = append(orderGooods, good)
}
result, err := creationCooperationGateway.DividendsReturnedOrderAdd(allied_creation_cooperation.ReqDividendsReturnedOrderAdd{
... ... @@ -97,13 +98,14 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) UpdateDivide
var orderGooods []allied_creation_cooperation.ReqDividendsReturnedOrderGood
for _, v := range updateDividendsReturnedOrderCommand.OrderGoods {
good := allied_creation_cooperation.ReqDividendsReturnedOrderGood{
OrderGoodId: strconv.Itoa(v.OrderGoodId),
CooperationContractNumber: v.CooperationContractNumber,
OrderGoodAmount: 0,
OrderGoodName: v.OrderGoodName,
OrderGoodPrice: v.OrderGoodPrice,
OrderGoodQuantity: v.OrderGoodQuantity,
}
good.OrderGoodAmount = good.OrderGoodPrice * float64(good.OrderGoodQuantity)
// good.OrderGoodAmount = good.OrderGoodPrice * float64(good.OrderGoodQuantity)
orderGooods = append(orderGooods, good)
}
_, err := creationCooperationGateway.DividendsReturnedOrderUpdate(allied_creation_cooperation.ReqDividendsReturnedOrderUpdate{
... ...
... ... @@ -156,6 +156,8 @@ type (
CooperationProjectName string `json:"cooperationProjectName"`
// 共创项目状态,1招标中,2结束 0 全部
Status int `json:"status"`
// 关键字搜索
Keyword string `cname:"关键字" json:"keyword"`
// 组织机构ID
OrgId int64 `cname:"组织机构ID" json:"orgId"`
OrgIds []int64 `json:"orgIds"`
... ...
... ... @@ -50,6 +50,7 @@ type (
//
ReqDividendsReturnedOrderGood struct {
OrderGoodId string `json:"orderGoodId"`
CooperationContractNumber string `json:"cooperationContractNumber"` //关联的共创合约编号
OrderGoodAmount float64 `json:"orderGoodAmount"` //订单产品金额
OrderGoodName string `json:"orderGoodName"` //订单产品名称
... ...