@@ -242,6 +249,10 @@ const poiImport = () => {
if (res.code === 200) {
PoiApi.getPoiList().then((list) => {
poiList.splice(0, poiList.length, ...list.data)
+ poiList.map((item) => {
+ let arr = item.path.split('/')
+ item.name = arr[arr.length - 1]
+ })
//只有一个poi时默认启用
if (poiList.length == 1) {
let formData = new FormData()
@@ -390,6 +401,10 @@ var routeList: any = reactive([])
const getList = async () => {
let list = await RouteApi.getRouteList()
routeList.splice(0, routeList.length, ...list.data)
+ routeList.map((item) => {
+ let arr = item.path.split('/')
+ item.name = arr[arr.length - 1]
+ })
}
getList()
@@ -398,6 +413,10 @@ var poiList: any = reactive([])
const getPoiList = async () => {
let list = await PoiApi.getPoiList()
poiList.splice(0, poiList.length, ...list.data)
+ poiList.map((item) => {
+ let arr = item.path.split('/')
+ item.name = arr[arr.length - 1]
+ })
}
getPoiList()
@@ -680,7 +699,7 @@ function derive() {
box-sizing: border-box;
display: flex;
line-height: 32px; // padding: 20px 0;
- padding: 0 0 20px 0;
+ padding: 0 0 15px 0;
.fankuai {
width: 10px;
height: 10px;
@@ -723,10 +742,10 @@ function derive() {
.fileList {
width: 100%;
// height: 20vh;
- max-height: 20vh;
+ max-height: 15vh;
box-sizing: border-box;
- padding: 0 0 20px 0;
-
+ // padding: 0 0 16px 0;
+ overflow-y: auto;
.fileList_nav {
width: 100%;
height: 100%;
@@ -734,7 +753,7 @@ function derive() {
overflow-y: auto; /* 垂直方向超出时显示滚动条 */
.fileList_nav_item {
width: 100%;
- height: 8vh;
+ height: 7vh;
// background-color: aqua;
box-sizing: border-box;
padding: 10px;
@@ -759,28 +778,57 @@ function derive() {
display: flex;
flex-direction: column;
padding-left: 10px;
+ width: calc(100% - 45px);
}
}
}
}
// 滚动条优化
- .fileList_nav::-webkit-scrollbar {
- width: 5px;
- height: 5px;
- }
+ // .fileList::-webkit-scrollbar {
+ // width: 5px;
+ // height: 5px;
+ // }
- .fileList_nav::-webkit-scrollbar-thumb {
- background-color: rgba(var(--color-base1), 1);
- border-radius: 5px;
- }
+ // .fileList::-webkit-scrollbar-thumb {
+ // background-color: rgba(var(--color-base1), 1);
+ // border-radius: 5px;
+ // }
- .fileList_nav::-webkit-scrollbar-track {
- background-color: rgba(var(--color-base1), 0.2);
- }
+ // .fileList::-webkit-scrollbar-track {
+ // background-color: rgba(var(--color-base1), 0.2);
+ // }
+}
+// 滚动条优化
+.fileList::-webkit-scrollbar {
+ width: 5px;
+ height: 5px;
+}
+
+.fileList::-webkit-scrollbar-thumb {
+ background-color: rgba(var(--color-base1), 1);
+ border-radius: 5px;
+}
+
+.fileList::-webkit-scrollbar-track {
+ background-color: rgba(var(--color-base1), 0.2);
}
.line {
width: 100%;
height: 1px;
background-color: rgba(204, 204, 204, 0.2);
}
+.pdfPath {
+ display: inline-block;
+ width: 100%;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ color: rgba(var(--color-text2), 1);
+}
+.but {
+ display: inline-block;
+ width: 140px;
+ text-align: right;
+ margin-left: 10px;
+}
diff --git a/src/renderer/src/views/components/headers/components/setPup/components/equipment.vue b/src/renderer/src/views/components/headers/components/setPup/components/equipment.vue
index c6b7068..512154e 100644
--- a/src/renderer/src/views/components/headers/components/setPup/components/equipment.vue
+++ b/src/renderer/src/views/components/headers/components/setPup/components/equipment.vue
@@ -147,9 +147,20 @@ const getTableList = async () => {
}
getTableList()
-
-eventBus.on('addOptionResuit', () => {
+let func = () => {
+ console.log('111111')
getTableList()
+}
+// eventBus.on('addOptionResuit', () => {
+// console.log('111111')
+// getTableList()
+// })
+
+onMounted(() => {
+ eventBus.on('addOptionResuit', func)
+})
+onUnmounted(() => {
+ eventBus.off('addOptionResuit', func)
})
//------------------添加--------------------
@@ -232,7 +243,6 @@ const attachUpload = async () => {
const params = new URLSearchParams()
params.append('filePath', path[0])
deviceApi.uploadSingle(params).then((res) => {
- console.log(res, 'res')
ElMessage.success('导入成功')
getTableList()
})
diff --git a/src/renderer/src/views/components/headers/components/setPup/components/materials.vue b/src/renderer/src/views/components/headers/components/setPup/components/materials.vue
index 6b83dd8..dacb808 100644
--- a/src/renderer/src/views/components/headers/components/setPup/components/materials.vue
+++ b/src/renderer/src/views/components/headers/components/setPup/components/materials.vue
@@ -23,10 +23,16 @@
-
+
-
+
+
@@ -116,9 +122,15 @@ const getTableList = async () => {
}
getTableList()
-
-eventBus.on('addOptionResuit2', () => {
+let func = () => {
getTableList()
+}
+
+onMounted(() => {
+ eventBus.on('addOptionResuit2', func)
+})
+onUnmounted(() => {
+ eventBus.off('addOptionResuit2', func)
})
//------------------添加--------------------
@@ -144,7 +156,7 @@ var edit = (type, row) => {
addForm = JSON.parse(JSON.stringify(row))
// addForm.areaId = +row.areaId
}
- eventBus.emit('openAddMaterial', { title: type, data: addForm })
+ eventBus.emit('openAddMaterial', { title: row ? 'edit' : 'add', data: addForm })
}
var delFun = (row) => {
diff --git a/src/renderer/src/views/components/headers/components/setPup/components/modelManage.vue b/src/renderer/src/views/components/headers/components/setPup/components/modelManage.vue
index 0828aa8..fd6b5db 100644
--- a/src/renderer/src/views/components/headers/components/setPup/components/modelManage.vue
+++ b/src/renderer/src/views/components/headers/components/setPup/components/modelManage.vue
@@ -25,7 +25,7 @@
@@ -132,7 +132,7 @@