diff --git a/util/sql/download.js b/util/sql/download.js index 3a24b67..016519d 100644 --- a/util/sql/download.js +++ b/util/sql/download.js @@ -1,8 +1,8 @@ const { run, getAll } = require("./base"); -function addDownList(title,url,save,downDate,isOk){ - let sql = `insert into download(title,url,save,downDate,isOk) values(?,?,?,?,?)` - run(sql,title,url,save,downDate,isOk) +function addDownList(title,url,save,downDate,isOk,vid){ + let sql = `insert into download(title,url,save,downDate,isOk,vid) values(?,?,?,?,?,?)` + run(sql,title,url,save,downDate,isOk,vid) } async function getDownList(){ @@ -21,6 +21,19 @@ async function setDownState(id,state){ await run(sql,state,id) } +async function getVideoInfo(url){ + if(url){ + let sql = `select * from VideoInfo where url = '?'` + let list = await getAll(sql,url) + }else{ + let sql = `insert into ` + } +} + +async function addVideoInfo(cover){ + +} + module.exports = { addDownList, getDownList,