|
@@ -1009,7 +1009,7 @@ const addingFormClick = () => {
|
|
//删除当前节点用表
|
|
//删除当前节点用表
|
|
const deltableexcel =async (row) => {
|
|
const deltableexcel =async (row) => {
|
|
console.log(row,'row');
|
|
console.log(row,'row');
|
|
- if(row['ancestors'].length>0||row['nodeType'].length>0){
|
|
|
|
|
|
+ if(row['ancestors'].length>0||row['nodeType']>0){
|
|
window?.$message?.warning('该表不允许删除')
|
|
window?.$message?.warning('该表不允许删除')
|
|
}else if(row['pdfUrl'].length>0){
|
|
}else if(row['pdfUrl'].length>0){
|
|
window?.$messageBox?.alert('该表已填写数据'+',请谨慎考虑后,确认是否需要删除?', '删除', {
|
|
window?.$messageBox?.alert('该表已填写数据'+',请谨慎考虑后,确认是否需要删除?', '删除', {
|
|
@@ -1034,33 +1034,15 @@ const deltableexcel =async (row) => {
|
|
}
|
|
}
|
|
else{
|
|
else{
|
|
const {error, code,msg} = await divisionApi.removeWbsTreeContract({id: row.pkeyId,stats:0})
|
|
const {error, code,msg} = await divisionApi.removeWbsTreeContract({id: row.pkeyId,stats:0})
|
|
- if (!error && code === 200) {
|
|
|
|
- window?.$message?.success('删除成功')
|
|
|
|
- window?.location?.reload() //刷新页面
|
|
|
|
- }else if( code === 300){
|
|
|
|
- window?.$messageBox?.alert('该表已填写数据'+',请谨慎考虑后,确认是否需要删除?', '删除', {
|
|
|
|
- showCancelButton: true,
|
|
|
|
- confirmButtonText: '确认删除',
|
|
|
|
- cancelButtonText: '取消',
|
|
|
|
- callback:async (action) => {
|
|
|
|
- if (action === 'confirm') {
|
|
|
|
- const {error, code,msg} = await divisionApi.removeWbsTreeContract({
|
|
|
|
- id: row.pkeyId,
|
|
|
|
- stats:1
|
|
|
|
- })
|
|
|
|
- if (!error && code === 200) {
|
|
|
|
|
|
+ if (!error && code === 200) {
|
|
window?.$message?.success('删除成功')
|
|
window?.$message?.success('删除成功')
|
|
window?.location?.reload() //刷新页面
|
|
window?.location?.reload() //刷新页面
|
|
- }else{
|
|
|
|
|
|
+ }else{
|
|
window?.$message?.warning(msg)
|
|
window?.$message?.warning(msg)
|
|
}
|
|
}
|
|
- }
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- }else{
|
|
|
|
- window?.$message?.warning(msg)
|
|
|
|
- }
|
|
|
|
|
|
+
|
|
}
|
|
}
|
|
|
|
+
|
|
}
|
|
}
|
|
//树配置
|
|
//树配置
|
|
const addingFormTreeRef = ref(null)
|
|
const addingFormTreeRef = ref(null)
|