From b7e5fa6428eac05c57f10dd760c8c4566751b21f Mon Sep 17 00:00:00 2001 From: zhangxin Date: Fri, 24 Dec 2021 00:14:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=9F=A5=E8=AF=A2=E7=89=88?= =?UTF-8?q?=E6=9C=ACbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dao/ap/implments/ArticleDemand.dao.impl.go | 4 ++-- task/k3cloud.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dao/ap/implments/ArticleDemand.dao.impl.go b/dao/ap/implments/ArticleDemand.dao.impl.go index 2a61677..f5f9c20 100644 --- a/dao/ap/implments/ArticleDemand.dao.impl.go +++ b/dao/ap/implments/ArticleDemand.dao.impl.go @@ -406,8 +406,8 @@ func (impl *ArticleDemandDAOImplement) RefreshArticleDemand() ([]model.ArticleDe ******************************************************************************/ func (impl *ArticleDemandDAOImplement) SelectTop() (*model.ArticleDemand, error) { - parameters := []interface{}{impl.plantNr} - where := fmt.Sprintf("%s = ?", meta.ArticleDemand_PlantNr.ColumnName) + parameters := []interface{}{impl.plantNr, 2} + where := fmt.Sprintf("%s = ? and %s = ?", meta.ArticleDemand_PlantNr.ColumnName, meta.ArticleDemand_Status.ColumnName) session := impl.session.Table(impl.meta.TableName).Where(where, parameters...) session = session.OrderBy(meta.ArticleDemand_PlantNr.ColumnName) diff --git a/task/k3cloud.go b/task/k3cloud.go index ff49cca..fadb927 100644 --- a/task/k3cloud.go +++ b/task/k3cloud.go @@ -52,14 +52,14 @@ func TaskInit() { //erp.PublishPlan(100, "admin") i = false } - time.Sleep(time.Minute * 30) + time.Sleep(time.Minute * 5) } } //1天任务 func oneTask(_date time.Time) { //需要定时登录erp - utils.K3configTestInit() + utils.K3configInit() //if DaysBetweenDates(lastTime.OneTime, _date) >= 1 {