dividends_incentives_estimate_dto.go
1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
package dto
import (
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-cooperation/pkg/domain"
"time"
)
type DividendsIncentivesEstimateDto struct {
// 分红订单产品ID
OrderGoodId int64 `json:"orderGoodId,string"`
// 共创合约编号
CooperationContractNumber string `json:"cooperationContractNumber"`
// 分红订单号或退货单号、
OrderNumber string `json:"orderNumber"`
// 来源单号
OriginalOrderNum string `json:"originalOrderNum"`
// 客户名称
CustomerName string `json:"customerName"`
// 订单区域
RegionName string `json:"region"`
// 订单金额
OrderAmount float64 `json:"orderAmount"`
// 订单/退货单日期
OrderDate string `json:"orderDate"`
}
func (dto *DividendsIncentivesEstimateDto) LoadDto(orderGood *domain.OrderGood, orderNumber string, originalOrderNum string, customerName string, regionName string, orderDate time.Time) error {
dto.OrderGoodId = orderGood.OrderGoodId
dto.CooperationContractNumber = orderGood.CooperationContractNumber
dto.OrderNumber = orderNumber
dto.OriginalOrderNum = originalOrderNum
dto.CustomerName = customerName
dto.RegionName = regionName
dto.OrderAmount = orderGood.OrderGoodAmount
dto.OrderDate = orderDate.String()
return nil
}