diff --git a/package-lock.json b/package-lock.json index 3f3f483..f20eba9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,10 +8,10 @@ "name": "vue3_template", "version": "0.0.0", "dependencies": { - "@element-plus/icons-vue": "^2.1.0", + "@element-plus/icons-vue": "^2.3.1", "@icon-park/vue-next": "^1.4.2", "@vueuse/core": "^9.13.0", - "@vueuse/integrations": "^10.7.0", + "@vueuse/integrations": "^10.7.1", "animate.css": "^4.1.1", "axios": "^1.6.3", "dayjs": "^1.11.10", @@ -20,40 +20,42 @@ "mitt": "^3.0.1", "normalize.css": "^8.0.1", "pinia": "^2.1.7", - "pinia-plugin-persistedstate": "^3.2.0", + "pinia-plugin-persistedstate": "^3.2.1", "qrcode": "^1.5.3", "qs": "^6.11.2", + "relation-graph": "^2.1.24", "throttle-debounce": "^5.0.0", "v-viewer": "^3.0.11", - "vue": "^3.3.13", + "vue": "^3.4.3", "vue-router": "^4.2.5", + "vue3-pdfjs": "^0.1.6", "vue3-print-nb": "^0.1.4", - "vue3-puzzle-vcode": "^1.0.16" + "vue3-puzzle-vcode": "^1.1.5" }, "devDependencies": { "@our-patches/postcss-px-to-viewport": "^1.2.0", - "@types/node": "^18.18.4", - "@vitejs/plugin-basic-ssl": "^1.0.1", - "@vitejs/plugin-vue": "^4.4.0", + "@types/node": "^18.19.4", + "@vitejs/plugin-basic-ssl": "^1.0.2", + "@vitejs/plugin-vue": "^4.6.2", "@vue/eslint-config-prettier": "^7.1.0", "autoprefixer": "^10.4.16", - "eslint": "^8.51.0", + "eslint": "^8.56.0", "eslint-config-prettier": "^8.10.0", "eslint-config-standard": "^17.1.0", - "eslint-plugin-import": "^2.28.1", + "eslint-plugin-import": "^2.29.1", "eslint-plugin-n": "^15.7.0", "eslint-plugin-prettier": "^4.2.1", "eslint-plugin-promise": "^6.1.1", - "eslint-plugin-vue": "^9.17.0", + "eslint-plugin-vue": "^9.19.2", "prettier": "^2.8.8", "sass": "^1.69.0", "unplugin-auto-import": "^0.12.2", "unplugin-vue-components": "^0.22.12", - "vite": "^4.4.11", + "vite": "^4.5.1", "vite-plugin-enhance-log": "^0.5.2", "vite-plugin-eslint": "^1.8.1", - "vite-plugin-remove-console": "^2.1.1", - "vue-eslint-parser": "^9.3.1" + "vite-plugin-remove-console": "^2.2.0", + "vue-eslint-parser": "^9.3.2" } }, "node_modules/@aashutoshrathi/word-wrap": { @@ -1935,6 +1937,14 @@ "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", "dev": true }, + "node_modules/base64-arraybuffer": { + "version": "1.0.2", + "resolved": "https://registry.npmmirror.com/base64-arraybuffer/-/base64-arraybuffer-1.0.2.tgz", + "integrity": "sha512-I3yl4r9QB5ZRY3XuJVEPfc2XhZO6YweFPI+UovAzn+8/hb3oJ6lnysaFcjVpkCPfVWFUDvoZ8kmVDP7WyRtYtQ==", + "engines": { + "node": ">= 0.6.0" + } + }, "node_modules/binary-extensions": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", @@ -2215,6 +2225,14 @@ "node": ">= 8" } }, + "node_modules/css-line-break": { + "version": "2.1.0", + "resolved": "https://registry.npmmirror.com/css-line-break/-/css-line-break-2.1.0.tgz", + "integrity": "sha512-FHcKFCZcAha3LwfVBhCQbW2nCNbkZXn7KVUJcsT5/P8YmfsVja0FMPJr0B903j/E69HUphKiV9iQArX8SDYA4w==", + "dependencies": { + "utrie": "^1.0.2" + } + }, "node_modules/cssesc": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", @@ -2323,6 +2341,12 @@ "node": ">=6.0.0" } }, + "node_modules/dommatrix": { + "version": "1.0.3", + "resolved": "https://registry.npmmirror.com/dommatrix/-/dommatrix-1.0.3.tgz", + "integrity": "sha512-l32Xp/TLgWb8ReqbVJAFIvXmY7go4nTxxlWiAFyhoQw9RKEOHBZNnyGvJWqDVSPmq3Y9HlM4npqF/T6VMOXhww==", + "deprecated": "dommatrix is no longer maintained. Please use @thednp/dommatrix." + }, "node_modules/electron-to-chromium": { "version": "1.4.617", "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.617.tgz", @@ -3466,6 +3490,18 @@ "node": ">= 0.4" } }, + "node_modules/html2canvas": { + "version": "1.4.1", + "resolved": "https://registry.npmmirror.com/html2canvas/-/html2canvas-1.4.1.tgz", + "integrity": "sha512-fPU6BHNpsyIhr8yyMpTLLxAbkaK8ArIBcmZIRiBLiDhjeqvXolaEmDGmELFuX9I4xDcaKKcJl+TKZLqruBbmWA==", + "dependencies": { + "css-line-break": "^2.1.0", + "text-segmentation": "^1.0.3" + }, + "engines": { + "node": ">=8.0.0" + } + }, "node_modules/ignore": { "version": "5.3.0", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.0.tgz", @@ -4326,6 +4362,23 @@ "integrity": "sha512-d+RQGp0MAYTIaDBIMmOfMwz3E+LOZnxx1HZd5R18mmCZY0QBlK0LDZfPc8FW8Ed2DlvsuE6PRjroDY+wg4+j/Q==", "dev": true }, + "node_modules/pdfjs-dist": { + "version": "2.16.105", + "resolved": "https://registry.npmmirror.com/pdfjs-dist/-/pdfjs-dist-2.16.105.tgz", + "integrity": "sha512-J4dn41spsAwUxCpEoVf6GVoz908IAA3mYiLmNxg8J9kfRXc2jxpbUepcP0ocp0alVNLFthTAM8DZ1RaHh8sU0A==", + "dependencies": { + "dommatrix": "^1.0.3", + "web-streams-polyfill": "^3.2.1" + }, + "peerDependencies": { + "worker-loader": "^3.0.8" + }, + "peerDependenciesMeta": { + "worker-loader": { + "optional": true + } + } + }, "node_modules/picocolors": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", @@ -4608,6 +4661,15 @@ "url": "https://github.com/sponsors/mysticatea" } }, + "node_modules/relation-graph": { + "version": "2.1.24", + "resolved": "https://registry.npmmirror.com/relation-graph/-/relation-graph-2.1.24.tgz", + "integrity": "sha512-W9eM2Ph8libTN1GeFrmVW8lYFW5wEZdeXrfliT+l1Mc6nBdGEojT+qXeiUSK0yhjhmilrD+yW1hx5d607/15Hw==", + "dependencies": { + "html2canvas": "^1.4.1", + "screenfull": "^5.1.0" + } + }, "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", @@ -4760,6 +4822,14 @@ "node": ">=14.0.0" } }, + "node_modules/screenfull": { + "version": "5.2.0", + "resolved": "https://registry.npmmirror.com/screenfull/-/screenfull-5.2.0.tgz", + "integrity": "sha512-9BakfsO2aUQN2K9Fdbj87RJIEZ82Q9IGim7FqM5OsebfoFC6ZHXgDq/KvniuLTPdeM8wY2o6Dj3WQ7KeQCj3cA==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/scule": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/scule/-/scule-1.1.1.tgz", @@ -4985,6 +5055,14 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/text-segmentation": { + "version": "1.0.3", + "resolved": "https://registry.npmmirror.com/text-segmentation/-/text-segmentation-1.0.3.tgz", + "integrity": "sha512-iOiPUo/BGnZ6+54OsWxZidGCsdU8YbE4PSpdPinp7DeMtUJNJBoJ/ouUSTJjHkh1KntHaltHl/gDs2FC4i5+Nw==", + "dependencies": { + "utrie": "^1.0.2" + } + }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", @@ -5318,6 +5396,14 @@ "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", "dev": true }, + "node_modules/utrie": { + "version": "1.0.2", + "resolved": "https://registry.npmmirror.com/utrie/-/utrie-1.0.2.tgz", + "integrity": "sha512-1MLa5ouZiOmQzUbjbu9VmjLzn1QLXBhwpUa7kdLUQK+KQ5KA9I1vk5U4YHe/X2Ch7PYnJfWuWT+VbuxbGwljhw==", + "dependencies": { + "base64-arraybuffer": "^1.0.2" + } + }, "node_modules/v-viewer": { "version": "3.0.11", "resolved": "https://registry.npmjs.org/v-viewer/-/v-viewer-3.0.11.tgz", @@ -5546,6 +5632,18 @@ "vue": "^3.2.0" } }, + "node_modules/vue3-pdfjs": { + "version": "0.1.6", + "resolved": "https://registry.npmmirror.com/vue3-pdfjs/-/vue3-pdfjs-0.1.6.tgz", + "integrity": "sha512-7UaWbsp8wNqB0y/rRlyo5yRb0S+XOkkSpmdUuS267Dhi07Pt4RFEetQ8inrpf/aTFJwGnW0Uc/UE4p376s+Zmw==", + "dependencies": { + "pdfjs-dist": "^2.10.377", + "vue": "^3.2.19" + }, + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/vue3-print-nb": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/vue3-print-nb/-/vue3-print-nb-0.1.4.tgz", @@ -5559,6 +5657,14 @@ "resolved": "https://registry.npmjs.org/vue3-puzzle-vcode/-/vue3-puzzle-vcode-1.1.5.tgz", "integrity": "sha512-JesxfEucupQYDHXcywVx5BGQ1Wjybtlj4dAeNw2tC1jfHt1FXoG0bpBSlLUS4TPyS+pHp++4zmTfBQZLf9ldXw==" }, + "node_modules/web-streams-polyfill": { + "version": "3.3.2", + "resolved": "https://registry.npmmirror.com/web-streams-polyfill/-/web-streams-polyfill-3.3.2.tgz", + "integrity": "sha512-3pRGuxRF5gpuZc0W+EpwQRmCD7gRqcDOMt688KmdlDAgAyaB1XlN0zq2njfDNm44XVdIouE7pZ6GzbdyH47uIQ==", + "engines": { + "node": ">= 8" + } + }, "node_modules/webpack-sources": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-3.2.3.tgz", diff --git a/package.json b/package.json index 0d617c2..d7eb5c1 100644 --- a/package.json +++ b/package.json @@ -25,10 +25,12 @@ "pinia-plugin-persistedstate": "^3.2.1", "qrcode": "^1.5.3", "qs": "^6.11.2", + "relation-graph": "^2.1.24", "throttle-debounce": "^5.0.0", "v-viewer": "^3.0.11", "vue": "^3.4.3", "vue-router": "^4.2.5", + "vue3-pdfjs": "^0.1.6", "vue3-print-nb": "^0.1.4", "vue3-puzzle-vcode": "^1.1.5" }, diff --git a/src/assets/js/asyncRouter.js b/src/assets/js/asyncRouter.js index 26333e0..3193881 100644 --- a/src/assets/js/asyncRouter.js +++ b/src/assets/js/asyncRouter.js @@ -73,6 +73,11 @@ export default [ }, ], }, + { + path: "/enterprise_management/department", + meta: { title: "组织机构", isSubMenu: false }, + component: "enterprise_management/department/index", + }, ], }, { @@ -393,4 +398,84 @@ export default [ }, ], }, + { + path: "/temporary_electricity_usage", + redirect: "/temporary_electricity_usage/job_data", + meta: { title: "临时用电作业管理", model: MODEL["3"] }, + component: "children", + children: [ + { + path: "/temporary_electricity_usage/job_data", + meta: { title: "临时用电作业数据", isSubMenu: false }, + component: "children", + children: [ + { path: "", component: "temporary_electricity_usage/job_data/index" }, + { + path: "/temporary_electricity_usage/job_data/view", + meta: { + title: "审批表详情", + activeMenu: "/temporary_electricity_usage/job_data", + }, + component: "temporary_electricity_usage/job_data/view", + }, + ], + }, + { + path: "/temporary_electricity_usage/archive", + meta: { title: "归档管理", isSubMenu: false }, + component: "children", + children: [ + { path: "", component: "temporary_electricity_usage/archive/index" }, + { + path: "/temporary_electricity_usage/archive/view", + meta: { + title: "审批表详情", + activeMenu: "/temporary_electricity_usage/archive", + }, + component: "temporary_electricity_usage/archive/view", + }, + ], + }, + ], + }, + { + path: "/hot_work", + redirect: "/hot_work/job_data", + meta: { title: "动火作业管理", model: MODEL["3"] }, + component: "children", + children: [ + { + path: "/hot_work/job_data", + meta: { title: "动火作业数据", isSubMenu: false }, + component: "children", + children: [ + { path: "", component: "hot_work/job_data/index" }, + { + path: "/hot_work/job_data/view", + meta: { + title: "审批表详情", + activeMenu: "/hot_work/job_data", + }, + component: "hot_work/job_data/view", + }, + ], + }, + { + path: "/hot_work/archive", + meta: { title: "归档管理", isSubMenu: false }, + component: "children", + children: [ + { path: "", component: "hot_work/archive/index" }, + { + path: "/hot_work/archive/view", + meta: { + title: "审批表详情", + activeMenu: "/hot_work/archive", + }, + component: "hot_work/archive/view", + }, + ], + }, + ], + }, ]; diff --git a/src/assets/js/data_dictionary.js b/src/assets/js/data_dictionary.js index 08974eb..1691e6c 100644 --- a/src/assets/js/data_dictionary.js +++ b/src/assets/js/data_dictionary.js @@ -3,6 +3,7 @@ import { getLevels, getLevelsAndChildrenNumber, getRegulatoryType, + getDepartmentTree, } from "@/request/data_dictionary.js"; import { ref } from "vue"; @@ -67,6 +68,11 @@ export const layoutFnGetRiskLevel = async () => { }); return ref(resData.list); }; +// 部门树 +export const layoutFnGetDepartmentTree = async () => { + const resData = await getDepartmentTree(); + return ref(JSON.parse(resData.zTreeNodes)); +}; // 无法确定DICTIONARIES_ID的数据字典 export const layoutFnGetLevels = async (DICTIONARIES_ID) => { const resData = await getLevels({ DICTIONARIES_ID }); diff --git a/src/assets/js/usePrint.js b/src/assets/js/usePrint.js index ecfaf04..9767d45 100644 --- a/src/assets/js/usePrint.js +++ b/src/assets/js/usePrint.js @@ -1,6 +1,6 @@ import { ref } from "vue"; -export default function usePrint(THEAD_HEIGHT = 81.59) { +export default function usePrint(THEAD_HEIGHT) { const buttonRef = ref(null); const A4_HEIGHT_MM = 297; const A4_HEIGHT_MM_TO_PX_PROPORTION = 3.78; diff --git a/src/components/department/index.vue b/src/components/department/index.vue new file mode 100644 index 0000000..0ad91a5 --- /dev/null +++ b/src/components/department/index.vue @@ -0,0 +1,65 @@ + + + + + diff --git a/src/components/pdf/index.vue b/src/components/pdf/index.vue new file mode 100644 index 0000000..f90b76f --- /dev/null +++ b/src/components/pdf/index.vue @@ -0,0 +1,52 @@ + + + diff --git a/src/components/print_table_package/index.vue b/src/components/print_table_package/index.vue index 00dcad2..4dfd4a5 100644 --- a/src/components/print_table_package/index.vue +++ b/src/components/print_table_package/index.vue @@ -23,15 +23,22 @@ diff --git a/src/request/data_dictionary.js b/src/request/data_dictionary.js index 030427d..5e86a7c 100644 --- a/src/request/data_dictionary.js +++ b/src/request/data_dictionary.js @@ -30,3 +30,9 @@ export const getUserListAllByCorp = (params) => loading: false, ...params, }); +// 部门树 +export const getDepartmentTree = (params) => + post("/department/listTree", { + loading: false, + ...params, + }); diff --git a/src/request/department.js b/src/request/department.js new file mode 100644 index 0000000..e6a7632 --- /dev/null +++ b/src/request/department.js @@ -0,0 +1,5 @@ +import { post } from "@/request/axios.js"; + +export const getDepartmentList = (params) => post("/department/list", params); // 组织机构列表 +export const setDepartmentDelete = (params) => + post("/department/delete", params); // 组织机构删除 diff --git a/src/request/hot_work.js b/src/request/hot_work.js new file mode 100644 index 0000000..105c3bd --- /dev/null +++ b/src/request/hot_work.js @@ -0,0 +1,4 @@ +import { post } from "@/request/axios.js"; + +export const getHotWorkList = (params) => post("/hotwork/list", params); // 动火作业管理列表 +export const getHotWorkView = (params) => post("/hotwork/goEdit", params); // 动火作业管理查看 diff --git a/src/request/temporary_electricity_usage.js b/src/request/temporary_electricity_usage.js new file mode 100644 index 0000000..2a87111 --- /dev/null +++ b/src/request/temporary_electricity_usage.js @@ -0,0 +1,6 @@ +import { post } from "@/request/axios.js"; + +export const getTemporaryElectricityUsageList = (params) => + post("/electricity/list", params); // 临时用电作业管理列表 +export const getTemporaryElectricityUsageView = (params) => + post("/electricity/goEdit", params); // 临时用电作业管理查看 diff --git a/src/views/blind_plate_plugging/job_data/index.vue b/src/views/blind_plate_plugging/job_data/index.vue index 9dd4433..4543be9 100644 --- a/src/views/blind_plate_plugging/job_data/index.vue +++ b/src/views/blind_plate_plugging/job_data/index.vue @@ -148,12 +148,10 @@ const stateList = [ { ID: "-6", NAME: "待验收打回" }, ]; const router = useRouter(); -const listData = useListData(getBlindPlatePluggingList, { - otherParams: { - APPLY_STATUS: props.entrance === "archive" ? "6" : "", - }, -}); -const { list, pagination, searchForm, fnGetData, fnResetPagination } = listData; +const { list, pagination, searchForm, fnGetData, fnResetPagination } = + useListData(getBlindPlatePluggingList, { + otherParams: props.entrance === "archive" ? { APPLY_STATUS: "6" } : {}, + }); const data = reactive({ flowChartDialog: { visible: false, diff --git a/src/views/blind_plate_plugging/job_data/view.vue b/src/views/blind_plate_plugging/job_data/view.vue index 93e2d61..03973b8 100644 --- a/src/views/blind_plate_plugging/job_data/view.vue +++ b/src/views/blind_plate_plugging/job_data/view.vue @@ -1,5 +1,5 @@