diff --git a/src/components/cockpit/monitoringPointList/components/overLimitDetails.vue b/src/components/cockpit/monitoringPointList/components/overLimitDetails.vue index 203cd04..24feba5 100644 --- a/src/components/cockpit/monitoringPointList/components/overLimitDetails.vue +++ b/src/components/cockpit/monitoringPointList/components/overLimitDetails.vue @@ -14,7 +14,7 @@ @@ -34,7 +34,7 @@ import TableHeader from '@/components/table/header/index.vue' import TableStore from '@/utils/tableStore' import { mainHeight } from '@/utils/layout' import HarmonicRatio‌ from '@/components/cockpit/gridSideStatistics/components/harmonicRatio‌.vue' -import { cslineList } from '@/api/harmonic-boot/cockpit/cockpit' +import { cslineList ,governLineList} from '@/api/harmonic-boot/cockpit/cockpit' const dialogVisible: any = ref(false) const harmonicRatio‌Ref: any = ref(null) @@ -139,8 +139,10 @@ const tableStore: any = new TableStore({ provide('tableStore', tableStore) tableStore.table.params.sortBy = '' tableStore.table.params.orderBy = '' +const time:any=ref([]) const open = async (row: any,searchBeginTime:any,searchEndTime:any) => { dialogVisible.value = true + time.value=[searchBeginTime,searchEndTime] initCSlineList() tableStore.table.params.lineId = row.lineId @@ -175,8 +177,19 @@ const onHarmonicRatioClose = () => { } const initCSlineList = async () => { - const res = await cslineList({}) - options.value = res.data + // const res = await cslineList({}) + const res = await governLineList({ + endTime:time.value[1], +keywords:"", +pageNum:1, +pageSize:10000, +searchBeginTime:time.value[0], +searchEndTime:time.value[1], +startTime:time.value[0], +timeFlag:1 + }) + options.value = res.data.records + } diff --git a/src/components/cockpit/monitoringPointList/index.vue b/src/components/cockpit/monitoringPointList/index.vue index 8ffd09f..875bbd4 100644 --- a/src/components/cockpit/monitoringPointList/index.vue +++ b/src/components/cockpit/monitoringPointList/index.vue @@ -6,7 +6,8 @@ :showReset="false" @selectChange="selectChange" datePicker - v-if="fullscreen" :timeKeyList="prop.timeKey" + v-if="fullscreen" + :timeKeyList="prop.timeKey" > - + 点击上传 @@ -59,7 +62,7 @@ const prop = defineProps({ h: { type: [String, Number] }, width: { type: [String, Number] }, height: { type: [String, Number] }, - timeKey: { type: Array as () => string[] }, + timeKey: { type: Array as () => string[] }, timeValue: { type: Object }, interval: { type: Number } }) @@ -279,14 +282,18 @@ const handleDialogClosed = () => { } // 处理文件超出限制 -const handleExceed = (files: any, fileList: any) => { +const handleExceed = (files: any) => { ElMessage.warning('只能上传一个文件,请先删除已选择的文件') } +const handleRemove = (files: any) => { + fileList.value = [] +} // 文件变更处理函数 -const handleChange = (file: any, fileList: any) => { +const handleChange = (file: any) => { // 在这里直接处理文件上传逻辑 - beforeUpload(file.raw) // 注意使用 file.raw 获取原始文件对象 + // beforeUpload(file.raw) // 注意使用 file.raw 获取原始文件对象 + fileList.value = [file] // 只保留最新选择的文件 } // 处理上传前检查 @@ -303,11 +310,7 @@ const beforeUpload = (file: any) => { const isLt10M = file.size / 1024 / 1024 < 10 if (!isValidType) { - ElMessage.error('上传文件只能是 Word 文档(.doc/.docx) 或 PDF 文件(.pdf)!') - return false - } - if (!isLt10M) { - ElMessage.error('上传文件大小不能超过 10MB!') + ElMessage.error('请上传(.doc/.docx/.pdf)格式文件!') return false } @@ -315,10 +318,12 @@ const beforeUpload = (file: any) => { return true } -const handleUpload = async (options: any) => { - const { file } = options +const handleUpload = async () => { + console.log(123, fileList.value) + // return + const formData = new FormData() - formData.append('file', file) + formData.append('file', fileList.value[0]?.raw) formData.append('lineId', currentUploadRow.value?.lineId || currentUploadRow.value?.id || '') try { diff --git a/src/components/table/fieldRender/index.vue b/src/components/table/fieldRender/index.vue index 987bf37..f035376 100644 --- a/src/components/table/fieldRender/index.vue +++ b/src/components/table/fieldRender/index.vue @@ -21,8 +21,8 @@ @@ -226,10 +226,12 @@ const handlerCommand = (item: OptButton) => { break } } +const imgList: any = ref({}) const getUrl = (url: string) => { getFileUrl({ filePath: url }).then(res => { - return res.data + imgList.value[url] = res.data }) + return true } diff --git a/src/components/tree/govern/deviceTree.vue b/src/components/tree/govern/deviceTree.vue index 5660ff5..2f10d49 100644 --- a/src/components/tree/govern/deviceTree.vue +++ b/src/components/tree/govern/deviceTree.vue @@ -35,7 +35,6 @@ const config = useConfig() const tree = ref() const treRef = ref() const changeDeviceType = (val: any, obj: any) => { - console.log('🚀 ~ changeDeviceType ~ val:', val, obj) emit('deviceTypeChange', val, obj) } getDeviceTree().then(res => { @@ -105,7 +104,6 @@ getDeviceTree().then(res => { }) } }) - console.log('🚀 ~ file: deviceTree.vue ~ line 18 ~ getDeviceTree ~ tree:', arr, arr2, arr3) tree.value = res.data nextTick(() => { diff --git a/src/layouts/admin/components/popup/password.vue b/src/layouts/admin/components/popup/password.vue index 0b29a48..f746843 100644 --- a/src/layouts/admin/components/popup/password.vue +++ b/src/layouts/admin/components/popup/password.vue @@ -1,109 +1,123 @@ - - + + diff --git a/src/utils/request.ts b/src/utils/request.ts index a796349..f827b1c 100644 --- a/src/utils/request.ts +++ b/src/utils/request.ts @@ -65,6 +65,7 @@ function createAxios>( if ( !( config.url == '/system-boot/file/upload' || + config.url == '/system-boot/file/getFileUrl' || config.url == '/harmonic-boot/grid/getAssessOverview' || config.url == '/harmonic-boot/gridDiagram/getGridDiagramAreaData' || config.url == '/cs-device-boot/csline/list' || diff --git a/src/views/auth/userList/popupEdit.vue b/src/views/auth/userList/popupEdit.vue index 82a69f5..7acafe2 100644 --- a/src/views/auth/userList/popupEdit.vue +++ b/src/views/auth/userList/popupEdit.vue @@ -1,6 +1,6 @@ - + + diff --git a/src/views/govern/manage/gplot/popupEdit.vue b/src/views/govern/manage/gplot/popupEdit.vue index 165d1b8..44f365e 100644 --- a/src/views/govern/manage/gplot/popupEdit.vue +++ b/src/views/govern/manage/gplot/popupEdit.vue @@ -1,149 +1,154 @@ - - - - + + + + diff --git a/src/views/govern/sensitiveLoadMange/index.vue b/src/views/govern/sensitiveLoadMange/index.vue index 1d05b48..2682c54 100644 --- a/src/views/govern/sensitiveLoadMange/index.vue +++ b/src/views/govern/sensitiveLoadMange/index.vue @@ -1,6 +1,6 @@