|
@@ -283,6 +283,12 @@ func (e *Entry) FirstFilterUpdate(pastureId int64, xToDay *XToday) (processIds [
|
|
|
|
|
|
cowInfo := e.GetCowInfoByNeckRingNumber(v.PastureId, v.NeckRingNumber)
|
|
|
if cowInfo == nil || cowInfo.Id <= 0 {
|
|
|
+ if err = e.DB.Model(new(model.NeckActiveHabit)).
|
|
|
+ Where("id = ?", v.Id).
|
|
|
+ Where("pasture_id = ?", v.PastureId).
|
|
|
+ Update("is_show", pasturePb.IsShow_Ok).Error; err != nil {
|
|
|
+ zaplog.Error("EntryUpdateActiveHabit", zap.Any("error", err))
|
|
|
+ }
|
|
|
continue
|
|
|
}
|
|
|
|