|
@@ -373,7 +373,7 @@ func (this *OrderController) TradeOrderList() {
|
|
|
RealName: productOrder.RealName,
|
|
|
Mobile: fmt.Sprintf("+%s %s", productOrder.AreaCode, productOrder.Mobile),
|
|
|
ProductName: productOrder.ProductName,
|
|
|
- Amount: order.Amount,
|
|
|
+ Amount: fmt.Sprintf("¥%s", order.Amount),
|
|
|
TransactionID: order.TransactionId,
|
|
|
ProductOrderID: order.ProductOrderId,
|
|
|
PaymentWay: PaymentWayMap[order.PaymentWay],
|
|
@@ -507,23 +507,23 @@ func (this *OrderController) ExportProductOrder() {
|
|
|
br.ErrMsg = "导出商品订单失败,Err:" + err.Error()
|
|
|
return
|
|
|
}
|
|
|
- var ListView []models.ProductOrderView
|
|
|
+ var ListView []*models.ProductOrderView
|
|
|
var wg sync.WaitGroup
|
|
|
for _, orderItem := range List {
|
|
|
- go func(orderItem models.ProductOrder) {
|
|
|
+ go func(orderItem *models.ProductOrder) {
|
|
|
defer wg.Done()
|
|
|
- view := models.ProductOrderView{
|
|
|
+ view := &models.ProductOrderView{
|
|
|
OrderID: orderItem.OrderId,
|
|
|
RealName: orderItem.RealName,
|
|
|
Mobile: fmt.Sprintf("+%s %s", orderItem.AreaCode, orderItem.Mobile),
|
|
|
ProductType: ProductTypeMap[orderItem.ProductType],
|
|
|
ProductName: orderItem.ProductName,
|
|
|
- TotalAmount: orderItem.TotalAmount,
|
|
|
+ TotalAmount: fmt.Sprintf("¥%s", orderItem.TotalAmount),
|
|
|
TradeNO: orderItem.TradeNo,
|
|
|
RefundAmount: orderItem.RefundAmount,
|
|
|
RefundTradeId: orderItem.RefundTradeId,
|
|
|
PaymentWay: PaymentWayMap[orderItem.PaymentWay],
|
|
|
- PaymentAmount: orderItem.PaymentAmount,
|
|
|
+ PaymentTime: orderItem.PaymentTime.Format(time.DateTime),
|
|
|
Status: ProductOrderStatus[orderItem.Status],
|
|
|
RefundStatus: RefundStatusMap[orderItem.RefundStatus],
|
|
|
Remark: orderItem.Remark,
|
|
@@ -535,7 +535,7 @@ func (this *OrderController) ExportProductOrder() {
|
|
|
if tradeErr != nil {
|
|
|
utils.FileLog.Error("获取支付订单失败,支付订单号:" + orderItem.TradeNo + ",err:" + tradeErr.Error())
|
|
|
} else {
|
|
|
- view.PaymentAmount = fmt.Sprintf("%s %.2f", tradeOrder.Currency, tradeOrder.Amount)
|
|
|
+ view.PaymentAmount = fmt.Sprintf("¥%s", tradeOrder.Amount)
|
|
|
}
|
|
|
}
|
|
|
if orderItem.Status == models.OrderStatusPaid {
|
|
@@ -656,7 +656,7 @@ func (this *OrderController) ExportTradeOrder() {
|
|
|
RealName: productOrder.RealName,
|
|
|
Mobile: fmt.Sprintf("+%s %s", productOrder.AreaCode, productOrder.Mobile),
|
|
|
ProductName: productOrder.ProductName,
|
|
|
- Amount: order.Amount,
|
|
|
+ Amount: fmt.Sprintf("¥%s", order.Amount),
|
|
|
TransactionID: order.TransactionId,
|
|
|
ProductOrderID: order.ProductOrderId,
|
|
|
PaymentWay: PaymentWayMap[order.PaymentWay],
|