添加项目 路径图上传样式

This commit is contained in:
宋文超
2022-11-24 18:15:35 +08:00
parent df731a58f0
commit 62c3b2dfa3
6 changed files with 621 additions and 244 deletions

View File

@@ -780,8 +780,8 @@
支持pdf.ppt.pptx.doc.docx.xls.xlsx.jpeg.png.gif.zip
</span>
</div>
<div
v-for="item in docList"
<!-- <div
v-for="item in fileList"
:key="item.src"
style="margin-top: 20px"
class="docListStyle"
@@ -800,6 +800,30 @@
item.name
}}</span>
<span style="color: #4ea6ff; float: right">删除</span>
</div> -->
<div
v-for="item in fileList"
:key="item.uid"
class="docListStyle"
>
<img
src="@/assets/images/basicinfo/download.png"
style="
cursor: pointer;
width: 40px;
height: 40px;
margin-right: 40px;
"
alt=""
/>
<span style="font: oblique bold 16px Sans-serif">{{
item.name
}}</span>
<span
style="color: #4ea6ff; float: right; cursor: pointer"
@click="deFile(item.uid)"
>删除</span
>
</div>
</div>
</div>
@@ -1898,11 +1922,13 @@ export default {
remark: state.remark,
routerId: state.routerId,
status: state.action,
}).then((res) => {
console.log(res)
}).catch((err) => {
console.log(err)
})
.then((res) => {
console.log(res);
})
.catch((err) => {
console.log(err);
});
}
if (info.file.status === "done") {
@@ -2003,6 +2029,32 @@ export default {
message.error("编辑失败");
});
};
const deFile = (id) => {
console.log(id);
let index = state.fileList.findIndex((item) => {
item.uid == id;
});
state.fileList.splice(index, 1);
let str = JSON.stringify(state.fileList);
//要编辑路径图
editRoutered({
attach: str,
name: state.styTitle,
picUrl: state.picUrl,
remark: state.remark,
routerId: state.routerId,
status: state.action,
})
.then((res) => {
console.log(res);
message.destroy();
return message.success("删除成功");
})
.catch((err) => {
console.log(err);
message.warning("删除失败");
});
};
return {
...toRefs(state),
...toRefs(levelList),
@@ -2052,6 +2104,7 @@ export default {
stageChange,
pageChange,
setconfig,
deFile,
};
},
};
@@ -3924,6 +3977,11 @@ export default {
}
}
}
.btnbox {
.ant-upload-list {
display: none !important;
}
}
.onemain {
margin-top: 20px;