Explorar o código

隆重 0 值判断

xingzai %!s(int64=3) %!d(string=hai) anos
pai
achega
508883cea0
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      services/data_source_longzhong.go

+ 2 - 2
services/data_source_longzhong.go

@@ -1147,7 +1147,7 @@ func GetLzSurveyProductData(cont context.Context) (err error) {
 					//	msg = "获取隆众调研指标数据失败:err " + err.Error()
 					//	return err
 					//}
-					if findItem, ok := existMap[shouldDateTimeStr]; !ok {
+					if findItem, ok := existMap[shouldDateTimeStr]; !ok && n.InputValue != "0" {
 						item := new(models.LongzhongSurveyData)
 						item.SurveyProductId = v.SurveyProductId
 						item.ProjectQuotaId = n.ProjectQuotaID
@@ -1185,7 +1185,7 @@ func GetLzSurveyProductData(cont context.Context) (err error) {
 							return err
 						}
 					} else {
-						if findItem.InputValue != n.InputValue {
+						if findItem.InputValue != n.InputValue && n.InputValue != "0" {
 							models.ModifyLzSurveyData(n.InputValue,findItem.SurveyDataId)
 						}
 						fmt.Println("exist:", shouldDateTimeStr)