diff --git a/.env.development b/.env.development index 3b6f68d..4aea391 100644 --- a/.env.development +++ b/.env.development @@ -3,8 +3,8 @@ VITE_SYS_TITLE = 受检设备管理系统 # 接口请求地址,会设置到 axios 的 baseURL 参数上 # VITE_APP_API_BASEURL = http://139.198.29.133:8089 -VITE_APP_API_BASEURL = http://111.198.10.15:21611 -# VITE_APP_API_BASEURL = http://192.168.8.107:5909 +# VITE_APP_API_BASEURL = http://111.198.10.15:21611 +VITE_APP_API_BASEURL = http://192.168.8.101:5909 # VITE_APP_API_BASEURL = http://111.198.10.15:21710 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 diff --git a/.env.development b/.env.development index 3b6f68d..4aea391 100644 --- a/.env.development +++ b/.env.development @@ -3,8 +3,8 @@ VITE_SYS_TITLE = 受检设备管理系统 # 接口请求地址,会设置到 axios 的 baseURL 参数上 # VITE_APP_API_BASEURL = http://139.198.29.133:8089 -VITE_APP_API_BASEURL = http://111.198.10.15:21611 -# VITE_APP_API_BASEURL = http://192.168.8.107:5909 +# VITE_APP_API_BASEURL = http://111.198.10.15:21611 +VITE_APP_API_BASEURL = http://192.168.8.101:5909 # VITE_APP_API_BASEURL = http://111.198.10.15:21710 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 diff --git a/public/config/config.json b/public/config/config.json index 3bd0a89..313fcf7 100644 --- a/public/config/config.json +++ b/public/config/config.json @@ -1,4 +1,4 @@ { "title":"计量业务系统", - "baseUrl": "http://111.198.10.15:21611" + "baseUrl": "http://192.168.8.101:5909" } diff --git a/.env.development b/.env.development index 3b6f68d..4aea391 100644 --- a/.env.development +++ b/.env.development @@ -3,8 +3,8 @@ VITE_SYS_TITLE = 受检设备管理系统 # 接口请求地址,会设置到 axios 的 baseURL 参数上 # VITE_APP_API_BASEURL = http://139.198.29.133:8089 -VITE_APP_API_BASEURL = http://111.198.10.15:21611 -# VITE_APP_API_BASEURL = http://192.168.8.107:5909 +# VITE_APP_API_BASEURL = http://111.198.10.15:21611 +VITE_APP_API_BASEURL = http://192.168.8.101:5909 # VITE_APP_API_BASEURL = http://111.198.10.15:21710 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 diff --git a/public/config/config.json b/public/config/config.json index 3bd0a89..313fcf7 100644 --- a/public/config/config.json +++ b/public/config/config.json @@ -1,4 +1,4 @@ { "title":"计量业务系统", - "baseUrl": "http://111.198.10.15:21611" + "baseUrl": "http://192.168.8.101:5909" } diff --git a/src/components/ApprovalRecord/ApprovalRecordTable.vue b/src/components/ApprovalRecord/ApprovalRecordTable.vue index 14ec12e..64e6f48 100644 --- a/src/components/ApprovalRecord/ApprovalRecordTable.vue +++ b/src/components/ApprovalRecord/ApprovalRecordTable.vue @@ -55,11 +55,12 @@ // listQuery.value.offset = 1 // } fetchApproval({ processId: listQuery.value.processId }).then((response) => { + console.log(response.data, 'response') response.data.forEach((item: Array, index: number) => { item.forEach((i: any) => { list.value.push({ cindex: index, - nodeNumber: i.approvalStatus === '发起人' ? 0 : list.value[i.cindex].nodeNumber + 1, + nodeNumber: i.approvalStatus === '发起人' ? 0 : list.value[index - 1].nodeNumber + 1, assigneeName: i.assigneeName, // 姓名 approvalStatus: i.approvalStatus, // 审批类型 finishTime: i.finishTime ? i.finishTime : '-', // 完成时间 diff --git a/.env.development b/.env.development index 3b6f68d..4aea391 100644 --- a/.env.development +++ b/.env.development @@ -3,8 +3,8 @@ VITE_SYS_TITLE = 受检设备管理系统 # 接口请求地址,会设置到 axios 的 baseURL 参数上 # VITE_APP_API_BASEURL = http://139.198.29.133:8089 -VITE_APP_API_BASEURL = http://111.198.10.15:21611 -# VITE_APP_API_BASEURL = http://192.168.8.107:5909 +# VITE_APP_API_BASEURL = http://111.198.10.15:21611 +VITE_APP_API_BASEURL = http://192.168.8.101:5909 # VITE_APP_API_BASEURL = http://111.198.10.15:21710 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 diff --git a/public/config/config.json b/public/config/config.json index 3bd0a89..313fcf7 100644 --- a/public/config/config.json +++ b/public/config/config.json @@ -1,4 +1,4 @@ { "title":"计量业务系统", - "baseUrl": "http://111.198.10.15:21611" + "baseUrl": "http://192.168.8.101:5909" } diff --git a/src/components/ApprovalRecord/ApprovalRecordTable.vue b/src/components/ApprovalRecord/ApprovalRecordTable.vue index 14ec12e..64e6f48 100644 --- a/src/components/ApprovalRecord/ApprovalRecordTable.vue +++ b/src/components/ApprovalRecord/ApprovalRecordTable.vue @@ -55,11 +55,12 @@ // listQuery.value.offset = 1 // } fetchApproval({ processId: listQuery.value.processId }).then((response) => { + console.log(response.data, 'response') response.data.forEach((item: Array, index: number) => { item.forEach((i: any) => { list.value.push({ cindex: index, - nodeNumber: i.approvalStatus === '发起人' ? 0 : list.value[i.cindex].nodeNumber + 1, + nodeNumber: i.approvalStatus === '发起人' ? 0 : list.value[index - 1].nodeNumber + 1, assigneeName: i.assigneeName, // 姓名 approvalStatus: i.approvalStatus, // 审批类型 finishTime: i.finishTime ? i.finishTime : '-', // 完成时间 diff --git a/src/components/NormalTable/index.vue b/src/components/NormalTable/index.vue index f08078d..aefbd8b 100644 --- a/src/components/NormalTable/index.vue +++ b/src/components/NormalTable/index.vue @@ -90,8 +90,16 @@ type: String, default: 'default', }, // 表格大小,默认,small,mini等,与el-table条件相同 + // 排序 + sort: { + type: Object, + default() { + return { + } + }, + }, }) -const emit = defineEmits(['change', 'selectionChange', 'rowClick', 'multiSelect']) +const emit = defineEmits(['change', 'selectionChange', 'rowClick', 'multiSelect', 'sortChange']) // -------定义数据-------------- interface columnsCheckInfo { text: string @@ -139,6 +147,10 @@ function selectionChange(selection: []) { emit('selectionChange', selection) } +// 点击排序 +function sortClick(column: any, prop: any, order: any) { + emit('sortChange', { column, prop, order }) +} // 点击行 function rowClick(row: object, column?: any, event?: any) { emit('rowClick', row) @@ -196,11 +208,13 @@ border stripe :size="size" + :default-sort="props.sort" :show-header="showHeader" style="width: 100%;" @selection-change="handleSelectionChange" @select="selectClick" @row-click="rowClick" + @sort-change="sortClick" > @@ -210,7 +224,7 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - +