|
@@ -33,13 +33,20 @@ async function processTask(){
|
|
|
if(data==undefined||data==null){
|
|
|
data = null
|
|
|
}
|
|
|
- if(data.rows==null||data.rows==undefined){
|
|
|
- data = null
|
|
|
+
|
|
|
+ if(data!=null){
|
|
|
+ if(data.rows==null||data.rows==undefined){
|
|
|
+ data = null
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
|
|
|
- if(data.rows.length<=0){
|
|
|
- data = null
|
|
|
+ if(data!=null){
|
|
|
+ if(data.rows.length<=0){
|
|
|
+ data = null
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
|
|
|
if(data!=null){
|
|
|
let publish_time = data.rows[0].createTime
|
|
@@ -47,9 +54,9 @@ async function processTask(){
|
|
|
`UPDATE video_product SET publish_time = "${publish_time}" WHERE id = ${video_product_info.id} `
|
|
|
);
|
|
|
}else{
|
|
|
- // await connection.execute(
|
|
|
- // ` delete from video_product where id = ${video_product_info.id}; `
|
|
|
- // );
|
|
|
+ await connection.execute(
|
|
|
+ ` UPDATE video_product SET status = 0 , publish_time = '2000-01-01 01:01:01' WHERE id = ${video_product_info.id} `
|
|
|
+ );
|
|
|
console.error("查无此书:",video_product_info)
|
|
|
}
|
|
|
}
|