Browse Source

'fix'

master
u 2 years ago
parent
commit
e2c928529e
  1. 8
      hasaki-gen-crud/template.go

8
hasaki-gen-crud/template.go

@ -285,7 +285,7 @@ func StartQueueTaskPrefixHigHead3A60Temp3A60() {
defer func() {
err := recover()
if err != nil {
L.Error("StartQueueTaskPrefixHigHead3A60Temp3A60意外退出:", err)
L.Error("StartQueueTaskPrefixHigHead3A60Temp3A60 意外退出:", err)
}
time.Sleep(time.Second * 5)
@ -313,8 +313,8 @@ func StartQueueTaskPrefixHigHead3A60Temp3A60() {
{
err := onec.queueEvent()
session := onec.getXorm().NewSession()
session.Table(onec)
defer session.Close()
session = session.Table(onec)
whereQuery, whereArgs := onec.wherePrimaryKey()
whereCond := onec.wherePrimaryKeyWithCond()
if whereQuery != "" {
@ -324,9 +324,9 @@ func StartQueueTaskPrefixHigHead3A60Temp3A60() {
session = session.Where(whereCond)
}
if err != nil {
session.Where(fmt.Sprintf("`%s`=?", f), TempLowHead3A60_AutoQueueStatusIng).Update(map[string]interface{}{f: TempLowHead3A60_AutoQueueStatusFail})
session.Update(map[string]interface{}{f: TempLowHead3A60_AutoQueueStatusFail})
} else {
session.Where(fmt.Sprintf("`%s`=?", f), TempLowHead3A60_AutoQueueStatusIng).Update(map[string]interface{}{f: TempLowHead3A60_AutoQueueStatusSuccess})
session.Update(map[string]interface{}{f: TempLowHead3A60_AutoQueueStatusSuccess})
}
}
}()

Loading…
Cancel
Save