|
@@ -502,6 +502,18 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) ImportDivide |
|
@@ -502,6 +502,18 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) ImportDivide |
502
|
break
|
502
|
break
|
503
|
}
|
503
|
}
|
504
|
|
504
|
|
|
|
505
|
+ // 退货日期格式转换
|
|
|
506
|
+ timeValue2, err := time.ParseInLocation("2006/01/02", dividendsReturnedOrder.DividendsReturnedDate, time.Local)
|
|
|
507
|
+ if err != nil {
|
|
|
508
|
+ var tmpRow []string
|
|
|
509
|
+ tmpRow = append(tmpRow, "无效的订单日期") // 错误信息
|
|
|
510
|
+ s := strconv.Itoa(i + 1)
|
|
|
511
|
+ tmpRow = append(tmpRow, s) // 行号
|
|
|
512
|
+ //tmpRow = append(tmpRow, dividendsReturnedOrder.OriginalOrderNum) // TODO 错误行数据
|
|
|
513
|
+ aggregateErrorList = append(aggregateErrorList, tmpRow)
|
|
|
514
|
+ break
|
|
|
515
|
+ }
|
|
|
516
|
+
|
505
|
// 产品相关:产品名称,退货数量、退货价格
|
517
|
// 产品相关:产品名称,退货数量、退货价格
|
506
|
quantity, err := strconv.ParseInt(dividendsReturnedOrder.OrderGoodQuantity, 10, 64)
|
518
|
quantity, err := strconv.ParseInt(dividendsReturnedOrder.OrderGoodQuantity, 10, 64)
|
507
|
if err != nil {
|
519
|
if err != nil {
|
|
@@ -516,9 +528,10 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) ImportDivide |
|
@@ -516,9 +528,10 @@ func (dividendsReturnedOrderService *DividendsReturnedOrderService) ImportDivide |
516
|
dividendsReturnedOrderCommands[hashString] = &command.CreateDividendsReturnedOrderCommand{
|
528
|
dividendsReturnedOrderCommands[hashString] = &command.CreateDividendsReturnedOrderCommand{
|
517
|
DividendsReturnedCustomerName: dividendsReturnedOrder.DividendsReturnedCustomerName,
|
529
|
DividendsReturnedCustomerName: dividendsReturnedOrder.DividendsReturnedCustomerName,
|
518
|
OriginalOrderNum: dividendsReturnedOrder.OriginalOrderNum,
|
530
|
OriginalOrderNum: dividendsReturnedOrder.OriginalOrderNum,
|
519
|
- OrderTime: string(rune(timeValue.Nanosecond() / 1000)),
|
531
|
+ OrderTime: strconv.FormatInt(timeValue.Local().UnixNano()/1e6, 10),
|
520
|
Remarks: "",
|
532
|
Remarks: "",
|
521
|
RegionName: dividendsReturnedOrder.RegionName,
|
533
|
RegionName: dividendsReturnedOrder.RegionName,
|
|
|
534
|
+ DividendsReturnedDate: strconv.FormatInt(timeValue2.Local().UnixNano()/1e6, 10),
|
522
|
OperatorUid: strconv.FormatInt(importDividendsReturnedOrderCommand.UserId, 10),
|
535
|
OperatorUid: strconv.FormatInt(importDividendsReturnedOrderCommand.UserId, 10),
|
523
|
OrderGoods: []command.OrderGoods{
|
536
|
OrderGoods: []command.OrderGoods{
|
524
|
{
|
537
|
{
|