作者 yangfu

机会统计错误捕获

@@ -1526,6 +1526,9 @@ func ChanceStatistics(header *protocol.RequestHeader, request *protocol.ChanceSt @@ -1526,6 +1526,9 @@ func ChanceStatistics(header *protocol.RequestHeader, request *protocol.ChanceSt
1526 item := chanceType[i] 1526 item := chanceType[i]
1527 if total, err = agg.GetChancePool(header.UserId, header.CompanyId, models.NewChancePoolOption(item.Id, []int{}, models.ChancePool, 0), 0, false, 0, 0, nil); err != nil { 1527 if total, err = agg.GetChancePool(header.UserId, header.CompanyId, models.NewChancePoolOption(item.Id, []int{}, models.ChancePool, 0), 0, false, 0, 0, nil); err != nil {
1528 log.Error(err) 1528 log.Error(err)
  1529 + if err == orm.ErrNoRows {
  1530 + err = nil
  1531 + }
1529 return 1532 return
1530 } 1533 }
1531 sum += total 1534 sum += total