|
|
|
@@ -172,30 +172,32 @@ export default { |
|
|
|
console.log(err) |
|
|
|
}) |
|
|
|
}, |
|
|
|
getCb1NotebookInfo(id){ |
|
|
|
getCb1Notebook(id).then((res)=>{ |
|
|
|
getCb1NotebookInfo(path,id){ |
|
|
|
getCb1Notebook(path,id).then((res)=>{ |
|
|
|
console.log(res) |
|
|
|
}) |
|
|
|
}, |
|
|
|
getCb2NotebookInfo(id){ |
|
|
|
getCb2Notebook(id).then((res)=>{ |
|
|
|
getCb2NotebookInfo(path,id){ |
|
|
|
getCb2Notebook(path,id).then((res)=>{ |
|
|
|
console.log(res) |
|
|
|
}) |
|
|
|
}, |
|
|
|
createTask(index){ |
|
|
|
this.btnStatus[index]=1 |
|
|
|
const data = {type:index,...this.fileInfo} |
|
|
|
let repoPath = `repos/${this.fileInfo.owner_name}/${this.fileInfo.project_name}` |
|
|
|
createNotebook(data).then((res)=>{ |
|
|
|
console.log("=========",res) |
|
|
|
if(res.data.code===0 && res.status===200){ |
|
|
|
// this.btnStatus[index]=2 |
|
|
|
if(index===2){ |
|
|
|
console.log("index",index) |
|
|
|
timerCb2 = setInterval(() => { |
|
|
|
setTimeout(this.getCb2NotebookInfo(res.data.message), 0) |
|
|
|
setTimeout(this.getCb2NotebookInfo(repoPath,res.data.message), 0) |
|
|
|
}, 3000) |
|
|
|
}else{ |
|
|
|
timerCb1 = setInterval(() => { |
|
|
|
setTimeout(this.getCb1NotebookInfo(res.data.message), 0) |
|
|
|
setTimeout(this.getCb1NotebookInfo(repoPath,res.data.message), 0) |
|
|
|
}, 3000) |
|
|
|
} |
|
|
|
|
|
|
|
|