Pārlūkot izejas kodu

update 区块星链

tags/v3.0.7
DengBiao pirms 2 gadiem
vecāks
revīzija
9e83a94dca
1 mainītis faili ar 2 papildinājumiem un 2 dzēšanām
  1. +2
    -2
      rule/block_star_chain_settlement.go

+ 2
- 2
rule/block_star_chain_settlement.go Parādīt failu

@@ -27,7 +27,7 @@ func Init(redisAddr string) (err error) {
}

// DailySettlementBlockStarChain 每日结算“区块星链”
func DailySettlementBlockStarChain(engine *xorm.Engine, mid string) (err error) {
func DailySettlementBlockStarChain(engine *xorm.Engine, mid string, isTask bool) (err error) {
session := engine.NewSession()
defer func() {
session.Close()
@@ -40,7 +40,7 @@ func DailySettlementBlockStarChain(engine *xorm.Engine, mid string) (err error)
today := now.Format("2006-01-02")

fmt.Println(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>", now.Hour())
if mid != "666666" && (now.Hour() > 8 || now.Hour() < 1) {
if isTask && (now.Hour() > 8 || now.Hour() < 1) {
//TODO::只在凌晨一点 ~ 凌晨 8 点运行
return errors.New("非运行时间")
}


Notiek ielāde…
Atcelt
Saglabāt