- 打开错误数据信息运营报警

This commit is contained in:
gazebo
2019-04-17 15:45:21 +08:00
parent bfc3b5f945
commit 1cc643b42a
2 changed files with 7 additions and 7 deletions

View File

@@ -259,15 +259,15 @@ func (c *OrderManager) SaveOrder(order *model.GoodsOrder, isAdjust bool, db *dao
func (c *OrderManager) updateOrderSkuOtherInfo(order *model.GoodsOrder, db *dao.DaoDB) (err error) { func (c *OrderManager) updateOrderSkuOtherInfo(order *model.GoodsOrder, db *dao.DaoDB) (err error) {
globals.SugarLogger.Debugf("updateOrderSkuOtherInfo orderID:%s, VendorStoreID:%s", order.VendorOrderID, order.VendorStoreID) globals.SugarLogger.Debugf("updateOrderSkuOtherInfo orderID:%s, VendorStoreID:%s", order.VendorOrderID, order.VendorStoreID)
jxStoreID := jxutils.GetShowStoreIDFromOrder(order) jxStoreID := jxutils.GetShowStoreIDFromOrder(order)
opNumStr := "2" var opNumStr string
if time.Now().Sub(order.OrderCreatedAt) < 48*time.Hour && order.VendorID != model.VendorIDEBAI { if time.Now().Sub(order.OrderCreatedAt) < 48*time.Hour && order.VendorID != model.VendorIDEBAI {
opNumStr = "" opNumStr = ""
} else {
// opNumStr = "2"
} }
if jxStoreID == 0 { if jxStoreID == 0 {
if order.VendorID != model.VendorIDEBAI {
globals.SugarLogger.Infof("updateOrderSkuOtherInfo [运营%s]订单在京西与平台都找不到京西门店信息orderID:%s, VendorStoreID:%s", opNumStr, order.VendorOrderID, order.VendorStoreID) globals.SugarLogger.Infof("updateOrderSkuOtherInfo [运营%s]订单在京西与平台都找不到京西门店信息orderID:%s, VendorStoreID:%s", opNumStr, order.VendorOrderID, order.VendorStoreID)
}
return nil return nil
} }
orderSkus := order.Skus orderSkus := order.Skus

View File

@@ -86,7 +86,7 @@ func CalculateOrderDeliveryFee(order *model.GoodsOrder, billTime time.Time, db o
deliveryFee = 650 deliveryFee = 650
} }
if lng == 0 || lat == 0 { if lng == 0 || lat == 0 {
globals.SugarLogger.Warnf("calculateDeliveryFee 门店没有坐标信息 orderID:%s", order.VendorOrderID) globals.SugarLogger.Infof("[运营]计算订单配送费orderID:%s,门店:%d没有坐标信息", order.VendorOrderID, jxutils.GetSaleStoreIDFromOrder(order))
return 0, 0, fmt.Errorf("找不到门店:%d的坐标", jxutils.GetSaleStoreIDFromOrder(order)) return 0, 0, fmt.Errorf("找不到门店:%d的坐标", jxutils.GetSaleStoreIDFromOrder(order))
} }
lng2, lat2, _ := jxutils.IntCoordinate2MarsStandard(order.ConsigneeLng, order.ConsigneeLat, order.CoordinateType) lng2, lat2, _ := jxutils.IntCoordinate2MarsStandard(order.ConsigneeLng, order.ConsigneeLat, order.CoordinateType)
@@ -99,7 +99,7 @@ func CalculateOrderDeliveryFee(order *model.GoodsOrder, billTime time.Time, db o
} else { } else {
distanceAddFee = jxutils.StandardPrice2Int(2 + 2*math.Ceil(distance-5)) distanceAddFee = jxutils.StandardPrice2Int(2 + 2*math.Ceil(distance-5))
if distance > warningDistance { if distance > warningDistance {
globals.SugarLogger.Infof("[运营]CalculateOrderDeliveryFee orderID:%s distance is %.3fkm", order.VendorOrderID, distance) globals.SugarLogger.Infof("[运营]计算订单配送费orderID:%s,距离%.3fkm太远,请检查门店坐标信息", order.VendorOrderID, distance)
} }
} }
globals.SugarLogger.Debugf("CalculateOrderDeliveryFee orderID:%s", order.VendorOrderID) globals.SugarLogger.Debugf("CalculateOrderDeliveryFee orderID:%s", order.VendorOrderID)
@@ -112,7 +112,7 @@ func CalculateOrderDeliveryFee(order *model.GoodsOrder, billTime time.Time, db o
} else { } else {
weightAddFee = jxutils.StandardPrice2Int(2.5 + 10 + 2*float64(jxutils.IntWeight2Float(order.Weight)-20)) weightAddFee = jxutils.StandardPrice2Int(2.5 + 10 + 2*float64(jxutils.IntWeight2Float(order.Weight)-20))
if order.Weight > warningWeight { if order.Weight > warningWeight {
globals.SugarLogger.Infof("[运营]CalculateOrderDeliveryFee orderID:%s weight is %d", order.VendorOrderID, order.Weight) globals.SugarLogger.Infof("[运营]计算订单配送费orderID:%s,重量:%dg太重,请检查商品属性", order.VendorOrderID, order.Weight)
} }
} }