This commit is contained in:
shoopea 2019-05-11 13:08:00 +08:00
parent e846045eaa
commit 81b65c3b1f

2
bot.go
View File

@ -78,6 +78,7 @@ func botMsgRescan(m *tb.Message) (string, error) {
p := JobPayloadRescanMsg{}
fmt.Sprintf(p.Query, "SELECT o.id from obj o where o.id = %s and o.obj_type_id = %d and o.obj_sub_type_id = %d;", m.Payload, objTypeMessage, objSubTypeMessageUnknown)
b, _ := json.Marshal(p)
log.Printf("botMsgRescan : %s\n", string(b))
err := createJob(objSubTypeJobRescanMsg, objJobPriorityRescanMsg, time.Now(), b)
logOnError(err, "botMsgRescan : createJob(objSubTypeJobRescanMsg)")
if err != nil {
@ -92,6 +93,7 @@ func botMsgRescan(m *tb.Message) (string, error) {
p := JobPayloadRescanMsg{}
fmt.Sprintf(p.Query, "SELECT o.id from obj o where o.obj_type_id = %d and o.obj_sub_type_id = %d;", objTypeMessage, objSubTypeMessageUnknown)
b, _ := json.Marshal(p)
log.Printf("botMsgRescan : %s\n", string(b))
err := createJob(objSubTypeJobRescanMsg, objJobPriorityRescanAllMsg, time.Now(), b)
logOnError(err, "botMsgRescan : createJob(objSubTypeJobRescanMsg)")
if err != nil {