From 7cc2763b382d55ba962487bf921efca40d6b2087 Mon Sep 17 00:00:00 2001 From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com> Date: Thu, 20 Feb 2025 16:47:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=9A=E7=AD=BE=E6=B5=81=E7=A8=8B=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E5=8A=9F=E8=83=BD=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/countersign/countersign.js | 124 +++- src/router/index.js | 311 +++++---- .../business-details.vue | 22 + .../direct-rotation-apply/index.vue | 285 ++++++++ .../receive-apply/business-details.vue | 22 + .../business-examine/receive-apply/index.vue | 285 ++++++++ .../reduction-apply/business-details.vue | 22 + .../reduction-apply/index.vue | 285 ++++++++ .../countersign/config/config-data.vue | 356 ++++++++++ .../material/countersign/config/index.vue | 637 ++++++++---------- .../material/countersign/config/indexold.vue | 311 +++++++++ vue.config.js | 126 ++-- 12 files changed, 2186 insertions(+), 600 deletions(-) create mode 100644 src/views/business-examine/direct-rotation-apply/business-details.vue create mode 100644 src/views/business-examine/direct-rotation-apply/index.vue create mode 100644 src/views/business-examine/receive-apply/business-details.vue create mode 100644 src/views/business-examine/receive-apply/index.vue create mode 100644 src/views/business-examine/reduction-apply/business-details.vue create mode 100644 src/views/business-examine/reduction-apply/index.vue create mode 100644 src/views/material/countersign/config/config-data.vue create mode 100644 src/views/material/countersign/config/indexold.vue diff --git a/src/api/countersign/countersign.js b/src/api/countersign/countersign.js index 7d95530a..55442419 100644 --- a/src/api/countersign/countersign.js +++ b/src/api/countersign/countersign.js @@ -1,48 +1,116 @@ import request from '@/utils/request' +// 会签配置管理列表接口 +export function getConfigListApi(query) { + return request({ + url: '/material/sysWorkflowType/list', + method: 'get', + params: query + }) +} +// 会签配置管理--新增 +export function addConfigApi(data) { + return request({ + url: '/material/sysWorkflowType/add', + method: 'post', + data: data + }) +} +// 会签配置管理--修改 +export function editConfigApi(data) { + return request({ + url: '/material/sysWorkflowType/update', + method: 'post', + data: data + }) +} +// 会签配置管理--删除 +export function deleteConfigApi(data) { + return request({ + url: '/material/sysWorkflowType/delete', + method: 'post', + data: data + }) +} + +// 会签配置流程列表 +export function getConfigNodeListApi(query) { + return request({ + url: '/material/sysWorkflowNode/list', + method: 'get', + params: query + }) +} + +// 会签配置流程--新增 +export function addConfigNodeApi(data) { + return request({ + url: '/material/sysWorkflowNode/add', + method: 'post', + data: data + }) +} +// 会签配置流程--修改 +export function editConfigNodeApi(data) { + return request({ + url: '/material/sysWorkflowNode/update', + method: 'post', + data: data + }) +} +// 会签配置流程--删除 +export function deleteConfigNodeApi(data) { + return request({ + url: '/material/sysWorkflowNode/delete', + method: 'post', + data: data + }) +} + +/** + * + ***************************************************************************************************************************************************** + * + */ + //会签配置管理列表信息 export function getConfigList(query) { - return request({ - url: '/material/sign_config/list', - method: 'get', - params: query, - }) + return request({ + url: '/material/sign_config/list', + method: 'get', + params: query + }) } - // 会签配置管理--新增 export function addConfig(data) { - return request({ - url: '/material/sign_config/addConfig', - method: 'post', - data: data, - }) + return request({ + url: '/material/sign_config/addConfig', + method: 'post', + data: data + }) } - //会签配置管理--详细信息 export function getConfigDetail(id) { - return request({ - url: '/material/sign_config/'+ id, - method: 'get', - }) + return request({ + url: '/material/sign_config/' + id, + method: 'get' + }) } // 会签配置管理--修改 export function editConfig(data) { - return request({ - url: '/material/sign_config/editConfig', - method: 'post', - data: data, - }) + return request({ + url: '/material/sign_config/editConfig', + method: 'post', + data: data + }) } - // 会签配置管理--删除 export function delConfig(id) { - return request({ - url: '/material/sign_config/delConfig/' + id, - method: 'post', - }) + return request({ + url: '/material/sign_config/delConfig/' + id, + method: 'post' + }) } - - diff --git a/src/router/index.js b/src/router/index.js index 7c7c95c7..b1cd5beb 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -30,159 +30,190 @@ import Layout from '@/layout' // 公共路由 export const constantRoutes = [ - { - path: '/redirect', - component: Layout, - hidden: true, - children: [ - { - path: '/redirect/:path(.*)', - component: () => import('@/views/redirect') - } - ] - }, - { - path: '/login', - component: () => import('@/views/login1'), - hidden: true - }, - { - path: '/register', - component: () => import('@/views/register1'), - hidden: true - }, - { - path: '/404', - component: () => import('@/views/error/404'), - hidden: true - }, - { - path: '/401', - component: () => import('@/views/error/401'), - hidden: true - }, - { - path: '', - component: Layout, - redirect: 'index', - children: [ - { - path: 'index', - component: () => import('@/views/index'), - name: 'Index', - meta: { title: '首页', icon: 'dashboard', affix: true } - } - ] - }, - { - path: '/qrCode/qrCodePage', - component: () => import('@/views/qrCode/qrCode'), - hidden: true - }, - { - path: '/user', - component: Layout, - hidden: true, - redirect: 'noredirect', - children: [ - { - path: 'profile', - component: () => import('@/views/system/user/profile/index'), - name: 'Profile', - meta: { title: '个人中心', icon: 'user' } - } - ] - } + { + path: '/redirect', + component: Layout, + hidden: true, + children: [ + { + path: '/redirect/:path(.*)', + component: () => import('@/views/redirect') + } + ] + }, + { + path: '/login', + component: () => import('@/views/login1'), + hidden: true + }, + { + path: '/register', + component: () => import('@/views/register1'), + hidden: true + }, + { + path: '/404', + component: () => import('@/views/error/404'), + hidden: true + }, + { + path: '/401', + component: () => import('@/views/error/401'), + hidden: true + }, + { + path: '', + component: Layout, + redirect: 'index', + children: [ + { + path: 'index', + component: () => import('@/views/index'), + name: 'Index', + meta: { title: '首页', icon: 'dashboard', affix: true } + } + ] + }, + { + path: '/qrCode/qrCodePage', + component: () => import('@/views/qrCode/qrCode'), + hidden: true + }, + { + path: '/user', + component: Layout, + hidden: true, + redirect: 'noredirect', + children: [ + { + path: 'profile', + component: () => import('@/views/system/user/profile/index'), + name: 'Profile', + meta: { title: '个人中心', icon: 'user' } + } + ] + } ] // 动态路由,基于用户权限动态去加载 export const dynamicRoutes = [ - { - path: '/system/user-auth', - component: Layout, - hidden: true, - permissions: ['system:user:edit'], - children: [ - { - path: 'role/:userId(\\d+)', - component: () => import('@/views/system/user/authRole'), - name: 'AuthRole', - meta: { title: '分配角色', activeMenu: '/system/user' } - } - ] - }, - { - path: '/system/role-auth', - component: Layout, - hidden: true, - permissions: ['system:role:edit'], - children: [ - { - path: 'user/:roleId(\\d+)', - component: () => import('@/views/system/role/authUser'), - name: 'AuthUser', - meta: { title: '分配用户', activeMenu: '/system/role' } - } - ] - }, - { - path: '/system/dict-data', - component: Layout, - hidden: true, - permissions: ['system:dict:list'], - children: [ - { - path: 'index/:dictId(\\d+)', - component: () => import('@/views/system/dict/data'), - name: 'Data', - meta: { title: '字典数据', activeMenu: '/system/dict' } - } - ] - }, - { - path: '/monitor/job-log', - component: Layout, - hidden: true, - permissions: ['monitor:job:list'], - children: [ - { - path: 'index/:jobId(\\d+)', - component: () => import('@/views/monitor/job/log'), - name: 'JobLog', - meta: { title: '调度日志', activeMenu: '/monitor/job' } - } - ] - }, - { - path: '/tool/gen-edit', - component: Layout, - hidden: true, - permissions: ['tool:gen:edit'], - children: [ - { - path: 'index/:tableId(\\d+)', - component: () => import('@/views/tool/gen/editTable'), - name: 'GenEdit', - meta: { title: '修改生成配置', activeMenu: '/tool/gen' } - } - ] - } + { + path: '/system/user-auth', + component: Layout, + hidden: true, + permissions: ['system:user:edit'], + children: [ + { + path: 'role/:userId(\\d+)', + component: () => import('@/views/system/user/authRole'), + name: 'AuthRole', + meta: { title: '分配角色', activeMenu: '/system/user' } + } + ] + }, + { + path: '/system/role-auth', + component: Layout, + hidden: true, + permissions: ['system:role:edit'], + children: [ + { + path: 'user/:roleId(\\d+)', + component: () => import('@/views/system/role/authUser'), + name: 'AuthUser', + meta: { title: '分配用户', activeMenu: '/system/role' } + } + ] + }, + { + path: '/system/dict-data', + component: Layout, + hidden: true, + permissions: ['system:dict:list'], + children: [ + { + path: 'index/:dictId(\\d+)', + component: () => import('@/views/system/dict/data'), + name: 'Data', + meta: { title: '字典数据', activeMenu: '/system/dict' } + } + ] + }, + { + path: '/monitor/job-log', + component: Layout, + hidden: true, + permissions: ['monitor:job:list'], + children: [ + { + path: 'index/:jobId(\\d+)', + component: () => import('@/views/monitor/job/log'), + name: 'JobLog', + meta: { title: '调度日志', activeMenu: '/monitor/job' } + } + ] + }, + { + path: '/tool/gen-edit', + component: Layout, + hidden: true, + permissions: ['tool:gen:edit'], + children: [ + { + path: 'index/:tableId(\\d+)', + component: () => import('@/views/tool/gen/editTable'), + name: 'GenEdit', + meta: { title: '修改生成配置', activeMenu: '/tool/gen' } + } + ] + }, + + // 会签配置 + { + path: '/countersign/config-data', + component: Layout, + hidden: true, + permissions: ['system:dict:list'], // 权限字符 + children: [ + { + path: 'index/:processName(.*)/:id(.*)', + component: () => import('@/views/material/countersign/config/config-data.vue'), + name: 'config-data', + meta: { title: '流程配置', activeMenu: '/countersign/config' } + } + ] + } + // 业务详情 + // { + // path: '/business-details', + // component: Layout, // 后续单独拎出来时 要取消layout 直接是独立页面 类似于404页面配置即可 + // hidden: true, + // permissions: ['system:dict:list'], // 权限字符 + // children: [ + // { + // path: 'index', + // name: 'business-details', + // meta: { title: '业务详情', activeMenu: '/business-examine' }, + // component: () => import('@/views/business-examine/business-details.vue') + // } + // ] + // } ] // 防止连续点击多次路由报错 -let routerPush = Router.prototype.push; -let routerReplace = Router.prototype.replace; +let routerPush = Router.prototype.push +let routerReplace = Router.prototype.replace // push Router.prototype.push = function push(location) { - return routerPush.call(this, location).catch(err => err) + return routerPush.call(this, location).catch(err => err) } // replace Router.prototype.replace = function push(location) { - return routerReplace.call(this, location).catch(err => err) + return routerReplace.call(this, location).catch(err => err) } export default new Router({ - mode: 'history', // 去掉url中的# - scrollBehavior: () => ({ y: 0 }), - routes: constantRoutes + mode: 'history', // 去掉url中的# + scrollBehavior: () => ({ y: 0 }), + routes: constantRoutes }) diff --git a/src/views/business-examine/direct-rotation-apply/business-details.vue b/src/views/business-examine/direct-rotation-apply/business-details.vue new file mode 100644 index 00000000..beab4cf6 --- /dev/null +++ b/src/views/business-examine/direct-rotation-apply/business-details.vue @@ -0,0 +1,22 @@ + + + + + diff --git a/src/views/business-examine/direct-rotation-apply/index.vue b/src/views/business-examine/direct-rotation-apply/index.vue new file mode 100644 index 00000000..ea3ae845 --- /dev/null +++ b/src/views/business-examine/direct-rotation-apply/index.vue @@ -0,0 +1,285 @@ + + + diff --git a/src/views/business-examine/receive-apply/business-details.vue b/src/views/business-examine/receive-apply/business-details.vue new file mode 100644 index 00000000..beab4cf6 --- /dev/null +++ b/src/views/business-examine/receive-apply/business-details.vue @@ -0,0 +1,22 @@ + + + + + diff --git a/src/views/business-examine/receive-apply/index.vue b/src/views/business-examine/receive-apply/index.vue new file mode 100644 index 00000000..ea3ae845 --- /dev/null +++ b/src/views/business-examine/receive-apply/index.vue @@ -0,0 +1,285 @@ + + + diff --git a/src/views/business-examine/reduction-apply/business-details.vue b/src/views/business-examine/reduction-apply/business-details.vue new file mode 100644 index 00000000..beab4cf6 --- /dev/null +++ b/src/views/business-examine/reduction-apply/business-details.vue @@ -0,0 +1,22 @@ + + + + + diff --git a/src/views/business-examine/reduction-apply/index.vue b/src/views/business-examine/reduction-apply/index.vue new file mode 100644 index 00000000..ea3ae845 --- /dev/null +++ b/src/views/business-examine/reduction-apply/index.vue @@ -0,0 +1,285 @@ + + + diff --git a/src/views/material/countersign/config/config-data.vue b/src/views/material/countersign/config/config-data.vue new file mode 100644 index 00000000..e98373a3 --- /dev/null +++ b/src/views/material/countersign/config/config-data.vue @@ -0,0 +1,356 @@ + + + + + diff --git a/src/views/material/countersign/config/index.vue b/src/views/material/countersign/config/index.vue index 7476e668..5cfa10c4 100644 --- a/src/views/material/countersign/config/index.vue +++ b/src/views/material/countersign/config/index.vue @@ -1,382 +1,279 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/views/material/countersign/config/indexold.vue b/src/views/material/countersign/config/indexold.vue new file mode 100644 index 00000000..4f9d4b47 --- /dev/null +++ b/src/views/material/countersign/config/indexold.vue @@ -0,0 +1,311 @@ + + + + diff --git a/vue.config.js b/vue.config.js index af82ad38..c06515e0 100644 --- a/vue.config.js +++ b/vue.config.js @@ -1,15 +1,15 @@ -"use strict"; -const path = require("path"); +'use strict' +const path = require('path') function resolve(dir) { - return path.join(__dirname, dir); + return path.join(__dirname, dir) } -const CompressionPlugin = require("compression-webpack-plugin"); +const CompressionPlugin = require('compression-webpack-plugin') -const name = process.env.VUE_APP_TITLE || "智能机具管理系统"; // 网页标题 +const name = process.env.VUE_APP_TITLE || '智能机具管理系统' // 网页标题 -const port = process.env.port || process.env.npm_config_port || 80; // 端口 +const port = process.env.port || process.env.npm_config_port || 80 // 端口 // vue.config.js 配置说明 //官方vue.config.js 参考文档 https://cli.vuejs.org/zh/config/#css-loaderoptions @@ -18,126 +18,128 @@ module.exports = { // 部署生产环境和开发环境下的URL。 // 默认情况下,Vue CLI 会假设你的应用是被部署在一个域名的根路径上 // 例如 https://www.bonus.vip/。如果应用被部署在一个子路径上,你就需要用这个选项指定这个子路径。例如,如果你的应用被部署在 https://www.bonus.vip/admin/,则设置 baseUrl 为 /admin/。 - publicPath: process.env.NODE_ENV === "production" ? "/" : "/", + publicPath: process.env.NODE_ENV === 'production' ? '/' : '/', // 在npm run build 或 yarn build 时 ,生成文件的目录名称(要和baseUrl的生产环境路径一致)(默认dist) - outputDir: "dist", + outputDir: 'dist', // 用于放置生成的静态资源 (js、css、img、fonts) 的;(项目打包之后,静态资源会放在这个文件夹下) - assetsDir: "static", + assetsDir: 'static', // 是否开启eslint保存检测,有效值:ture | false | 'error' - lintOnSave: process.env.NODE_ENV === "development", + lintOnSave: process.env.NODE_ENV === 'development', // 如果你不需要生产环境的 source map,可以将其设置为 false 以加速生产环境构建。 productionSourceMap: false, // webpack-dev-server 相关配置 devServer: { - host: "0.0.0.0", + host: '0.0.0.0', port: port, open: true, proxy: { // detail: https://cli.vuejs.org/config/#devserver-proxy [process.env.VUE_APP_BASE_API]: { // target: `http://localhost:18080`, - target: `http://192.168.0.15:18080`,//马 - // target: `http://192.168.0.244:18580`,//测试 + // target: `http://192.168.0.15:18080`,//马 + // target: `http://192.168.0.244:18580`,//测试 // target: `http://192.168.2.223:18080`,//山 // target: `http://192.168.2.23:18080`,//洪 // target: `http://192.168.0.234:18080`,//阮 // target: `http://192.168.137.1:18080`,// + // target: `http://192.168.0.15:18080`,// 韩傲宇 + target: `http://192.168.2.209:18080`, // 赵福海 changeOrigin: true, pathRewrite: { - ["^" + process.env.VUE_APP_BASE_API]: "", - }, + ['^' + process.env.VUE_APP_BASE_API]: '' + } }, - "/api": { - target: "http://192.168.0.21:17861", + '/api': { + target: 'http://192.168.0.21:17861', //设置允许跨域——此处我经过测试发现可有可无 changeOrigin: true, pathRewrite: { - "^/api": "", - }, - }, + '^/api': '' + } + } }, - disableHostCheck: true, + disableHostCheck: true }, css: { loaderOptions: { sass: { - sassOptions: { outputStyle: "expanded" }, - }, - }, + sassOptions: { outputStyle: 'expanded' } + } + } }, configureWebpack: { name: name, resolve: { alias: { - "@": resolve("src"), - }, + '@': resolve('src') + } }, plugins: [ // http://doc.bonus.vip/bonus-vue/other/faq.html#使用gzip解压缩静态文件 new CompressionPlugin({ cache: false, // 不启用文件缓存 test: /\.(js|css|html|jpe?g|png|gif|svg)?$/i, // 压缩文件格式 - filename: "[path][base].gz[query]", // 压缩后的文件名 - algorithm: "gzip", // 使用gzip压缩 + filename: '[path][base].gz[query]', // 压缩后的文件名 + algorithm: 'gzip', // 使用gzip压缩 minRatio: 0.8, // 压缩比例,小于 80% 的文件不会被压缩 - deleteOriginalAssets: false, // 压缩后删除原文件 - }), - ], + deleteOriginalAssets: false // 压缩后删除原文件 + }) + ] }, chainWebpack(config) { - config.plugins.delete("preload"); // TODO: need test - config.plugins.delete("prefetch"); // TODO: need test + config.plugins.delete('preload') // TODO: need test + config.plugins.delete('prefetch') // TODO: need test // set svg-sprite-loader - config.module.rule("svg").exclude.add(resolve("src/assets/icons")).end(); + config.module.rule('svg').exclude.add(resolve('src/assets/icons')).end() config.module - .rule("icons") + .rule('icons') .test(/\.svg$/) - .include.add(resolve("src/assets/icons")) + .include.add(resolve('src/assets/icons')) .end() - .use("svg-sprite-loader") - .loader("svg-sprite-loader") + .use('svg-sprite-loader') + .loader('svg-sprite-loader') .options({ - symbolId: "icon-[name]", + symbolId: 'icon-[name]' }) - .end(); + .end() - config.when(process.env.NODE_ENV !== "development", (config) => { + config.when(process.env.NODE_ENV !== 'development', config => { config - .plugin("ScriptExtHtmlWebpackPlugin") - .after("html") - .use("script-ext-html-webpack-plugin", [ + .plugin('ScriptExtHtmlWebpackPlugin') + .after('html') + .use('script-ext-html-webpack-plugin', [ { // `runtime` must same as runtimeChunk name. default is `runtime` - inline: /runtime\..*\.js$/, - }, + inline: /runtime\..*\.js$/ + } ]) - .end(); + .end() config.optimization.splitChunks({ - chunks: "all", + chunks: 'all', cacheGroups: { libs: { - name: "chunk-libs", + name: 'chunk-libs', test: /[\\/]node_modules[\\/]/, priority: 10, - chunks: "initial", // only package third parties that are initially dependent + chunks: 'initial' // only package third parties that are initially dependent }, elementUI: { - name: "chunk-elementUI", // split elementUI into a single package + name: 'chunk-elementUI', // split elementUI into a single package test: /[\\/]node_modules[\\/]_?element-ui(.*)/, // in order to adapt to cnpm - priority: 20, // the weight needs to be larger than libs and app or it will be packaged into libs or app + priority: 20 // the weight needs to be larger than libs and app or it will be packaged into libs or app }, commons: { - name: "chunk-commons", - test: resolve("src/components"), // can customize your rules + name: 'chunk-commons', + test: resolve('src/components'), // can customize your rules minChunks: 3, // minimum common number priority: 5, - reuseExistingChunk: true, - }, - }, - }); - config.optimization.runtimeChunk("single"); - }); - }, -}; + reuseExistingChunk: true + } + } + }) + config.optimization.runtimeChunk('single') + }) + } +}