明树Git Lab

Commit 943135f6 authored by zfp1's avatar zfp1

1

parent 141aa3aa
Pipeline #111912 passed with stage
in 3 seconds
......@@ -1618,6 +1618,24 @@ async function getCompanyProjectApprover(req, res, next) {
return res.sendData(ret);
}
async function updateSnap(req, res, next) {
try {
let {lixiang, juece} = req.body;
if(lixiang && lixiang.id) {
await ProjectLixiang.update({lixiang}, {where: {projectId: lixiang.id}});
}
if(juece && juece.id) {
await ProjectLixiang.update({juece}, {where: {projectId: juece.id}});
}
if(lixiang.id && juece.id) {
await ProjectLixiang.update({lixiang, juece}, {where: {projectId: lixiang.id}});
}
return res.sendData({})
} catch (error) {
next(error);
}
}
module.exports = {
getProjectFields,
createProject,
......@@ -1644,4 +1662,5 @@ module.exports = {
startZaiJuece,
approvalZaiJuece,
getCompanyProjectApprover,
updateSnap,
}
\ No newline at end of file
......@@ -224,4 +224,8 @@ router.post('/getGdf', projectQtController.getGdf);
router.post('/getGdfList', projectQtController.getGdfList);
router.post('/deleteGdf', projectQtController.deleteGdf);
//快照
router.post('/updateSnap', projectController.updateSnap);
module.exports = router;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment