- 梳理TIMER,去除TimerTypeBaseExpectedDeliveredTime

This commit is contained in:
gazebo
2019-03-31 15:46:41 +08:00
parent d2fafe5ec0
commit ef05d85fc2
9 changed files with 132 additions and 119 deletions

View File

@@ -25,7 +25,7 @@ var (
func InitServiceInfo(version string, buildTime time.Time, gitCommit string) {
buildTimeStr := ""
if !jxutils.IsTimeEmpty(buildTime) {
if !utils.IsTimeZero(buildTime) {
buildTimeStr = utils.Time2Str(buildTime)
}
serviceInfo = map[string]interface{}{

View File

@@ -391,7 +391,7 @@ func GetStoresSkusSaleInfo(ctx *jxcontext.Context, storeIDs []int, skuIDs []int,
WHERE t1.order_created_at >= ? AND t1.order_created_at <= ?
AND IF(t2.jx_store_id <> 0, jx_store_id, store_id) IN (` + dao.GenQuestionMarks(len(storeIDs)) + `)
`
if jxutils.IsTimeEmpty(toTime) {
if utils.IsTimeZero(toTime) {
toTime = time.Now()
}
sqlParams := []interface{}{

View File

@@ -858,10 +858,10 @@ func unmarshalCommentText(commentStr string) (retVal map[string]interface{}, isN
}
func RefreshEbaiBadComment(ctx *jxcontext.Context, fromTime, toTime time.Time, isAsync, isContinueWhenError bool) (hint string, err error) {
if jxutils.IsTimeEmpty(fromTime) {
if utils.IsTimeZero(fromTime) {
fromTime = utils.Str2Time("2018-05-03 00:00:00")
}
if jxutils.IsTimeEmpty(toTime) {
if utils.IsTimeZero(toTime) {
toTime = time.Now().Add(-3 * time.Hour)
}
days := int(toTime.Sub(fromTime)/(24*time.Hour) + 1)