合并分支 'dev' 到 'test'
fix:小程序同步销售日期 查看合并请求 !28
正在显示
3 个修改的文件
包含
6 行增加
和
5 行删除
| @@ -87,7 +87,7 @@ func (s SyncOrderService) SyncOrderFromBestshop(cmd command.CreateOrderFromBests | @@ -87,7 +87,7 @@ func (s SyncOrderService) SyncOrderFromBestshop(cmd command.CreateOrderFromBests | ||
| 87 | 87 | ||
| 88 | /** | 88 | /** |
| 89 | * @Author SteveChan | 89 | * @Author SteveChan |
| 90 | - * @Description //TODO 同步小程序订单,增加销售时间 | 90 | + * @Description //同步小程序订单,增加销售时间 |
| 91 | * @Date 23:53 2021/1/26 | 91 | * @Date 23:53 2021/1/26 |
| 92 | * @Param | 92 | * @Param |
| 93 | * @return | 93 | * @return |
| @@ -266,7 +266,7 @@ func (s SyncOrderService) copyOrderBestshopToOrderBase(orderBestshop *domain.Ord | @@ -266,7 +266,7 @@ func (s SyncOrderService) copyOrderBestshopToOrderBase(orderBestshop *domain.Ord | ||
| 266 | orderbase.PartnerCategory = domain.PartnerCategory{Id: 1, Name: "事业合伙人"} | 266 | orderbase.PartnerCategory = domain.PartnerCategory{Id: 1, Name: "事业合伙人"} |
| 267 | orderbase.Compute() | 267 | orderbase.Compute() |
| 268 | // 销售日期 | 268 | // 销售日期 |
| 269 | - orderbase.SaleDate = orderBestshop.CreateTime | 269 | + //orderbase.SaleDate = orderBestshop.CreateTime |
| 270 | err = orderBaseRepository.Save(&orderbase) | 270 | err = orderBaseRepository.Save(&orderbase) |
| 271 | if err != nil { | 271 | if err != nil { |
| 272 | e := fmt.Sprintf("添加order_base数据失败%s", err) | 272 | e := fmt.Sprintf("添加order_base数据失败%s", err) |
| @@ -59,6 +59,7 @@ func (order OrderBestShop) CopyToOrderBase(o *OrderBase) { | @@ -59,6 +59,7 @@ func (order OrderBestShop) CopyToOrderBase(o *OrderBase) { | ||
| 59 | o.OrderCompute.PlanOrderAmount = order.OrderAmount | 59 | o.OrderCompute.PlanOrderAmount = order.OrderAmount |
| 60 | o.OrderCompute.PlanOrderCount = order.OrderCount | 60 | o.OrderCompute.PlanOrderCount = order.OrderCount |
| 61 | o.DeliveryTime, _ = time.Parse("2006-01-02 15:04:05", order.DeliveryTime) | 61 | o.DeliveryTime, _ = time.Parse("2006-01-02 15:04:05", order.DeliveryTime) |
| 62 | + o.SaleDate = order.CreateTime | ||
| 62 | o.RegionInfo.RegionName = order.OrderArea | 63 | o.RegionInfo.RegionName = order.OrderArea |
| 63 | return | 64 | return |
| 64 | } | 65 | } |
| @@ -84,9 +84,9 @@ func (repository OrderBaseRepository) Save(orderInfo *domain.OrderBase) error { | @@ -84,9 +84,9 @@ func (repository OrderBaseRepository) Save(orderInfo *domain.OrderBase) error { | ||
| 84 | Remark: orderInfo.Remark, | 84 | Remark: orderInfo.Remark, |
| 85 | PartnerCategory: orderInfo.PartnerCategory, | 85 | PartnerCategory: orderInfo.PartnerCategory, |
| 86 | } | 86 | } |
| 87 | - if m.OrderType > 2 { // TODO 非平台自建订单,默认销售日期取订单创建日期 | ||
| 88 | - m.SaleDate = orderInfo.CreateTime | ||
| 89 | - } | 87 | + //if m.OrderType > 2 { // TODO 非平台自建订单,默认销售日期取订单创建日期 |
| 88 | + // m.SaleDate = orderInfo.CreateTime | ||
| 89 | + //} | ||
| 90 | if m.Id == 0 { | 90 | if m.Id == 0 { |
| 91 | _, err = tx.Model(m). | 91 | _, err = tx.Model(m). |
| 92 | Returning("*"). | 92 | Returning("*"). |
-
请 注册 或 登录 后发表评论