Pārlūkot izejas kodu

Merge branch 'hjw-outexcel' into 'hjw-outexcel'

# Conflicts:
#   vue.config.js
胡俊炜 2 gadi atpakaļ
vecāks
revīzija
8d5c50baad
89 mainītis faili ar 32210 papildinājumiem un 1046 dzēšanām
  1. 10 0
      config/agdev.env.js
  2. 17 0
      config/dev.env.js
  3. 10 0
      config/docker.env.js
  4. 88 0
      config/index.js
  5. 11 0
      config/prod.env.js
  6. 10 0
      config/test.env.js
  7. 1 1
      package.json
  8. BIN
      src/assets/a_img1.png
  9. BIN
      src/assets/a_img2.png
  10. BIN
      src/assets/a_img3.png
  11. BIN
      src/assets/a_img4.png
  12. BIN
      src/assets/a_img5.png
  13. BIN
      src/assets/a_img6.png
  14. BIN
      src/assets/b_img1.png
  15. BIN
      src/assets/b_img2.png
  16. BIN
      src/assets/b_img3.png
  17. BIN
      src/assets/b_img4.png
  18. BIN
      src/assets/b_img5.png
  19. BIN
      src/assets/b_img6.png
  20. 2 7
      src/assets/calendar.scss
  21. BIN
      src/assets/jiantou.png
  22. BIN
      src/assets/jiantou1.png
  23. 1349 0
      src/assets/js/common.js
  24. 45 0
      src/assets/js/http.js
  25. 1721 0
      src/assets/js/url.js
  26. 772 0
      src/assets/js/util.js
  27. BIN
      src/assets/newlogo.png
  28. BIN
      src/assets/newlogo2.png
  29. 57 0
      src/components/ProcessDiagramDialog.vue
  30. 6 0
      src/components/common/bus.js
  31. 9 0
      src/components/components/approvalDialog/index-mixins.js
  32. 16 0
      src/components/components/approvalDialog/index.vue
  33. 5 1
      src/components/el-form.vue
  34. 58 24
      src/components/newTree.vue
  35. 162 32
      src/components/workflow.vue
  36. 592 0
      src/components/workflowBase.vue
  37. 662 0
      src/components/workflowEntrance.vue
  38. 292 0
      src/components/workflowUpload.vue
  39. 4 0
      src/config/index.js
  40. 53 0
      src/http/api.js
  41. 9 1
      src/main.js
  42. 92 0
      src/pages/main/comWin/aproveStep.vue
  43. 368 0
      src/pages/main/comWin/aproveWin.vue
  44. 192 0
      src/pages/main/comWin/prosess.vue
  45. 219 0
      src/pages/main/leader/components/deptThree.vue
  46. 102 0
      src/pages/main/leader/components/export.vue
  47. 121 0
      src/pages/main/leader/components/form.vue
  48. 1073 0
      src/pages/main/leader/components/formTable.vue
  49. 139 0
      src/pages/main/leader/components/search.vue
  50. 55 0
      src/pages/main/leader/components/tabs.vue
  51. 1597 0
      src/pages/main/leader/demand/demandHome.vue
  52. 1682 0
      src/pages/main/leader/demand/demandHomes.vue
  53. 412 0
      src/pages/main/leader/demand/reportForm.vue
  54. 269 0
      src/pages/main/leader/demand/supportState.vue
  55. 298 305
      src/pages/main/leader/leaderhomeTask.vue
  56. 1 1
      src/pages/main/performance/components/dialog.vue
  57. 420 0
      src/pages/main/processinst/doDistribution.vue
  58. 149 0
      src/pages/main/processinst/index.vue
  59. 30 0
      src/pages/main/processinst/processHistory.vue
  60. 64 0
      src/pages/main/processinst/wfActivitySelect.vue
  61. 248 0
      src/pages/main/processruns/doDistribution.vue
  62. 30 0
      src/pages/main/processruns/processHistory.vue
  63. 326 0
      src/pages/main/processruns/processruns.vue
  64. 64 0
      src/pages/main/processruns/wfActivitySelect.vue
  65. 2 2
      src/pages/main/terminal/advertisement.vue
  66. 641 0
      src/pages/main/terminals/advchecks.vue
  67. 308 0
      src/pages/main/terminals/advdetailed.vue
  68. 894 0
      src/pages/main/terminals/advertincreases.vue
  69. 241 0
      src/pages/main/terminals/advertisement.vue
  70. 241 0
      src/pages/main/terminals/advertisements.vue
  71. 513 0
      src/pages/main/terminals/advertmaterial.vue
  72. 837 0
      src/pages/main/terminals/components/adverts.vue
  73. 377 0
      src/pages/main/terminals/components/terminals.vue
  74. 343 0
      src/pages/main/terminals/terminApproval.vue
  75. 643 0
      src/pages/main/terminals/terminal.vue
  76. 436 0
      src/pages/main/terminals/terminalApply.vue
  77. 440 0
      src/pages/main/terminals/terminalModel.vue
  78. 270 0
      src/pages/main/terminals/terminalOver.vue
  79. 198 0
      src/pages/main/terminals/terminalStandbook.vue
  80. 133 0
      src/pages/main/terminals/terminalhome.vue
  81. 188 0
      src/pages/main/workflowdef/Import.vue
  82. 0 0
      src/pages/main/workflowdef/codeView.vue
  83. 45 0
      src/pages/main/workflowdef/design.vue
  84. 105 0
      src/pages/main/workflowdef/edit.vue
  85. 294 0
      src/pages/main/workflowdef/index.vue
  86. 4 0
      src/plugins/element-ui.js
  87. 737 671
      src/router/index.js
  88. 2 1
      vue.config.js
  89. 10406 0
      yarn.lock

+ 10 - 0
config/agdev.env.js

@@ -0,0 +1,10 @@
+'use strict'
+module.exports = {
+    NODE_ENV: '"production"',
+    ENV_CONFIG: '"agdev"',
+    ctx: '"http://finance.agilestar.cn:9501"',
+    ctxForm: '"http://finance.agilestar.cn:9500"',
+    excludeMeWhenSelectNextHandler: true,
+    excludeFormerHanlder: true,
+    envTitle: '"公司开发环境"'
+}

+ 17 - 0
config/dev.env.js

@@ -0,0 +1,17 @@
+'use strict'
+const merge = require('webpack-merge')
+const prodEnv = require('./prod.env')
+
+module.exports = merge(prodEnv, {
+  NODE_ENV: '"development"',
+  ENV_CONFIG: '"dev"',
+  ctx:'"http://127.0.0.1:8080"',
+  // ctxForm: '"http://10.149.85.91:8880"',//dev
+  // ctxForm: '"http://43.138.50.94:8880"',//test
+  // ctxForm: '"http://192.168.2.124:8880"',//test
+  ctxForm: '"http://10.230.15.228:8880"',//生产
+  excludeMeWhenSelectNextHandler:false,
+  excludeFormerHanlder:false,
+  envTitle:'"本地开发环境"'
+})
+  

+ 10 - 0
config/docker.env.js

@@ -0,0 +1,10 @@
+'use strict'
+module.exports = {
+  NODE_ENV: '"production"',
+  ENV_CONFIG: '"docker"',
+  ctx:'"http://172.21.137.102:9501"', 
+  ctxForm: '"http://172.21.137.102:9500"',
+  excludeMeWhenSelectNextHandler:true,
+  excludeFormerHanlder:true,
+  envTitle:'""'
+}

+ 88 - 0
config/index.js

@@ -0,0 +1,88 @@
+'use strict'
+// Template version: 1.2.7
+// see http://vuejs-templates.github.io/webpack for documentation.
+
+const path = require('path')
+// import common from '../src/assets/js/common.js';
+module.exports = {
+  dev: {
+
+    // Paths
+    assetsSubDirectory: 'static',
+    assetsPublicPath: '/',
+    proxyTable: {
+      // '/api':{
+      //     target:'http://192.168.1.79:8080',//common.ctx,//
+      //     changeOrigin:true,
+      //     pathRewrite:{
+      //         '^/api':''
+      //     }
+      // },
+      // '/ms':{
+      //   target:'http://192.168.1.79:8081',//common.ctxForm,//
+      //   changeOrigin:true,
+      //   pathRewrite:{
+      //       '^/ms':''
+      //   }
+      // }
+    },
+    // Various Dev Server settings
+    host: 'localhost', // can be overwritten by process.env.HOST
+    port: 8081, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
+    autoOpenBrowser: false,
+    errorOverlay: true,
+    notifyOnErrors: true,
+    poll: false, // https://webpack.js.org/configuration/dev-server/#devserver-watchoptions-
+
+    
+    /**
+     * Source Maps
+     */
+
+    // https://webpack.js.org/configuration/devtool/#development
+    devtool: 'eval-source-map',
+
+    // If you have problems debugging vue-files in devtools,
+    // set this to false - it *may* help
+    // https://vue-loader.vuejs.org/en/options.html#cachebusting
+    cacheBusting: true,
+
+    // CSS Sourcemaps off by default because relative paths are "buggy"
+    // with this option, according to the CSS-Loader README
+    // (https://github.com/webpack/css-loader#sourcemaps)
+    // In our experience, they generally work as expected,
+    // just be aware of this issue when enabling this option.
+    cssSourceMap: false,
+  },
+
+  build: {
+    // Template for index.html
+    index: path.resolve(__dirname, '../dist/index.html'),
+
+    // Paths
+    assetsRoot: path.resolve(__dirname, '../dist'),
+    assetsSubDirectory: 'static',
+    assetsPublicPath: './',
+
+    /**
+     * Source Maps
+     */
+
+    productionSourceMap: false,
+    // https://webpack.js.org/configuration/devtool/#production
+    devtool: '#source-map',
+
+    // Gzip off by default as many popular static hosts such as
+    // Surge or Netlify already gzip all static assets for you.
+    // Before setting to `true`, make sure to:
+    // npm install --save-dev compression-webpack-plugin
+    productionGzip: false,
+    productionGzipExtensions: ['js', 'css'],
+
+    // Run the build command with an extra argument to
+    // View the bundle analyzer report after build finishes:
+    // `npm run build --report`
+    // Set to `true` or `false` to always turn it on or off
+    bundleAnalyzerReport: process.env.npm_config_report,
+  }
+}

+ 11 - 0
config/prod.env.js

@@ -0,0 +1,11 @@
+'use strict'
+module.exports = {
+  NODE_ENV: '"production"',
+  ENV_CONFIG: '"prod"',
+  ctx:'"http://10.2.110.201:9501"',
+  ctxForm: '"http://10.2.110.201:9500"',
+  excludeMeWhenSelectNextHandler:true,
+  excludeFormerHanlder:true,
+  envTitle:'""'
+}
+

+ 10 - 0
config/test.env.js

@@ -0,0 +1,10 @@
+'use strict'
+module.exports = {
+  NODE_ENV: '"production"',
+  ENV_CONFIG: '"test"',
+  ctx:'"http://10.2.110.203:8601"',
+  ctxForm: '"http://10.2.110.203:8600"',
+  excludeMeWhenSelectNextHandler:true,
+  excludeFormerHanlder:true,
+  envTitle:'"测试环境"'
+}

+ 1 - 1
package.json

@@ -17,7 +17,7 @@
     "canvg": "^3.0.7",
     "core-js": "^3.6.1",
     "echarts": "^4.7.0",
-    "element-ui": "^2.13.0",
+    "element-ui": "^2.15.7",
     "exceljs": "^4.2.0",
     "file-saver": "^2.0.5",
     "form-making": "^1.2.10",

BIN
src/assets/a_img1.png


BIN
src/assets/a_img2.png


BIN
src/assets/a_img3.png


BIN
src/assets/a_img4.png


BIN
src/assets/a_img5.png


BIN
src/assets/a_img6.png


BIN
src/assets/b_img1.png


BIN
src/assets/b_img2.png


BIN
src/assets/b_img3.png


BIN
src/assets/b_img4.png


BIN
src/assets/b_img5.png


BIN
src/assets/b_img6.png


+ 2 - 7
src/assets/calendar.scss

@@ -1,12 +1,7 @@
 @charset "UTF-8";
 .calendar-box {
-  height: 720px;
-  overflow-y: auto;
-  background: rgb(255, 255, 255);
-  padding-left: 15px;
-  padding-top: 20px;
-  padding-right: 15px;
-  border-radius: 5px;
+  height: 710px;
+  overflow-y: scroll;
 }
 .tag-tip{
   text-align: right;

BIN
src/assets/jiantou.png


BIN
src/assets/jiantou1.png


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1349 - 0
src/assets/js/common.js


+ 45 - 0
src/assets/js/http.js

@@ -0,0 +1,45 @@
+
+import axios from 'axios'
+import common from "./common.js";
+import vue from '../../components/common/bus';
+axios.defaults.baseURL = common.ctx//'bus.common.ctx';//配置你的接口请求地址
+axios.defaults.headers.post['Content-Type'] = 'application/json';//'multipart/form-data';//配置请求头信息。
+
+
+// http response 拦截器
+axios.interceptors.response.use(
+  response => {
+    //vue.$store.commit('endLoading');
+    if(response.config.url.indexOf('8880')!=-1 || response.config.url.indexOf('8099')!=-1){
+      return response.data;
+    }else{
+      return response;
+    }
+  },
+  error => {
+    //vue.$store.commit('endLoading');
+    if (error.response) {
+      switch (error.response.status) {
+        case 401:
+          // 401 清除token信息并跳转到登录页面
+          vue.$store.commit('signOut');
+          vue.$router.push('/login');
+          break;
+        case 500:
+
+          vue.$store.commit('signOut');
+
+          vue.$router.push('/login');
+
+          break;
+        default:
+          break;
+      }
+    }
+    let msg = "系统出现错误,请重试";
+    vue.$message.error(msg);
+    return Promise.reject(msg)
+
+  });
+
+export default axios;

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1721 - 0
src/assets/js/url.js


+ 772 - 0
src/assets/js/util.js

@@ -0,0 +1,772 @@
+//
+// import accounting from 'accounting-js'
+// import idcard from 'idcard' //https://www.npmjs.com/package/idcard
+let moment = require("moment");
+let Decimal = require('decimal');
+let util = {
+   
+  ui: {
+
+  }
+};
+util.rules={ // 就是我们在el-form中绑定的rules,进行表单的验证
+  
+  name: { required: true, message: '必填项' },
+  id: { required: true, message: '必填项' },
+  code: { required: true, message: '必填项' },
+  email:[
+    { required: true, message: '必填项' },
+    { pattern:/^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/, message: '填写正确邮箱格式' }
+  ],
+  mobile:[
+    { pattern:/^1([38][0-9]|4[579]|5[0-3,5-9]|6[6]|7[0135678]|9[89])\d{8}$/, message: '填写正确手机号' }
+  ],
+  name1:[
+    { required: true, message: '必填项' },
+    { min: 1, max: 32, message: '长度在1 到 32之间', trigger: 'blur' }
+  ]
+ 
+}
+//前端权限校验
+util.hasPermission = function(permission) {
+  let vm = window.vue;
+  let permissions = vm.$store.state.app.user.userPermissions || [];
+  let found = permissions.includes(permission);
+
+  return found;
+};
+//获取前端地址参数对象
+util.getRequestSearchObject = function() {
+  var url = window.location.search; //获取url中"?"符后的字串
+  var theRequest = new Object();
+  if (url.indexOf("?") != -1) {
+    var str = url.substr(1);
+    strs = str.split("&");
+    for (var i = 0; i < strs.length; i++) {
+      //就是这句的问题
+      theRequest[strs[i].split("=")[0]] = decodeURI(strs[i].split("=")[1]);
+      //之前用了unescape()
+      //才会出现乱码
+    }
+  }
+  return theRequest;
+};
+//字符串转化为日期类型
+util.toLocalDate = function(input) {
+  if (!input) {
+    return null;
+  }
+  let a = moment(input);
+
+  let b = a.toDate();
+  return b;
+};
+//根据数据字典Id,获取显示名称
+util.dataDicFormat = function(dicType, dicId) {
+  if (!dicId) {
+    return '';
+  }
+  let dic = tapp.datadictionary[dicType];
+  if (!dic) {
+    return '';
+  }
+
+  let dicItem = dic.find(i => i.Id === dicId);
+  if (!dicItem) {
+    return '';
+  }
+  return dicItem.Name || '';
+};
+//根据数据字典Id列表,获取用','分隔的显示名称
+util.dataDicsFormat = function(dicType, dicIds) {
+  if (!dicIds) {
+    return '';
+  }
+  let dic = tapp.datadictionary[dicType];
+  if (!dic) {
+    return '';
+  }
+  let checkedDicItemIds = dicIds.split(',');
+  let dicItems = dic.filter(i => checkedDicItemIds.includes(i.Id));
+  return dicItems.map(p => p.Name).join(",");
+};
+//根据字典类别生成grid探件的过滤条件
+util.getListDataDicFilters = function(dicType) {
+    let data = tapp.datadictionary[dicType];
+    if (!data) {
+      return [];
+    }
+    return data.map(p => {
+      return {
+        text: p.Name,
+        value: p.Id
+      };
+    });
+  },
+  //日期时间格式化,:YYYY-MM-DD HH:mm:ss格式
+  util.datetimeFormat = function(input) {
+    if (!input) {
+      return '';
+    }
+    let a = moment(input).utc(8);
+    return a.format('YYYY-MM-DD HH:mm:ss');
+  };
+//日期格式化,:YYYY-MM-DD格式
+util.dateFormat = function(input) {
+  if (!input) {
+    return '';
+  }
+  let a = moment(input).utc(8);
+  return a.format('YYYY-MM-DD');
+};
+//根据输入datePattern做日期格式化
+util.datePatternFormat = function(input, fmt) {
+  if (!input) {
+    return '';
+  }
+  let a = moment(input).utc(8);
+  return a.format(fmt);
+};
+//货币格式化,如:数字输入100000,格式化后:¥100,000
+// util.moneyFormat = function(input) {
+//   if (input == null) {
+//     return '';
+//   }
+//   let s = accounting.formatMoney(input, {
+//     symbol: '¥',
+
+//   })
+//   return s;
+// };
+//货币阿拉伯数字转中文大写格式
+util.moneyArabiaToChinese = function(Num) {
+  let isNegative = false; // 是否负数
+  if (Num < 0) {
+    Num = -Num;
+    isNegative = true;
+  }
+  if (typeof Num == 'number') {
+    Num = Num.toString();
+  }
+  for (var i = Num.length - 1; i >= 0; i--) {
+    Num = Num.replace(",", ""); // 替换money中的“,”
+    Num = Num.replace(" ", ""); // 替换money中的空格
+  }
+  Num = Num.replace("¥", ""); // 替换掉可能出现的¥字符
+  if (isNaN(Num)) { // 验证输入的字符是否为数字
+    return;
+  }
+  // ---字符处理完毕,开始转换,转换采用前后两部分分别转换---//
+  let part = String(Num).split(".");
+  let newchar = "";
+  // 小数点前进行转化
+  for (let i = part[0].length - 1; i >= 0; i--) {
+    if (part[0].length > 10) {
+      alert("位数过大,无法计算");
+      return "";
+    } // 若数量超过拾亿单位,提示
+    let tmpnewchar = "";
+    let perchar = part[0].charAt(i);
+    switch (perchar) {
+      case "0":
+        tmpnewchar = "零" + tmpnewchar;
+        break;
+      case "1":
+        tmpnewchar = "壹" + tmpnewchar;
+        break;
+      case "2":
+        tmpnewchar = "贰" + tmpnewchar;
+        break;
+      case "3":
+        tmpnewchar = "叁" + tmpnewchar;
+        break;
+      case "4":
+        tmpnewchar = "肆" + tmpnewchar;
+        break;
+      case "5":
+        tmpnewchar = "伍" + tmpnewchar;
+        break;
+      case "6":
+        tmpnewchar = "陆" + tmpnewchar;
+        break;
+      case "7":
+        tmpnewchar = "柒" + tmpnewchar;
+        break;
+      case "8":
+        tmpnewchar = "捌" + tmpnewchar;
+        break;
+      case "9":
+        tmpnewchar = "玖" + tmpnewchar;
+        break;
+    }
+    switch (part[0].length - i - 1) {
+      case 0:
+        tmpnewchar = tmpnewchar + "元";
+        break;
+      case 1:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "拾";
+        break;
+      case 2:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "佰";
+        break;
+      case 3:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "仟";
+        break;
+      case 4:
+        tmpnewchar = tmpnewchar + "万";
+        break;
+      case 5:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "拾";
+        break;
+      case 6:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "佰";
+        break;
+      case 7:
+        if (perchar != 0)
+          tmpnewchar = tmpnewchar + "仟";
+        break;
+      case 8:
+        tmpnewchar = tmpnewchar + "亿";
+        break;
+      case 9:
+        tmpnewchar = tmpnewchar + "拾";
+        break;
+    }
+    newchar = tmpnewchar + newchar;
+  }
+  // 小数点之后进行转化
+  if (Num.indexOf(".") != -1) {
+    if (part[1].length > 2) {
+      alert("小数点之后只能保留两位,系统将自动截段");
+      part[1] = part[1].substr(0, 2);
+    }
+    for (var i = 0; i < part[1].length; i++) {
+      let tmpnewchar = "";
+      let perchar = part[1].charAt(i);
+      switch (perchar) {
+        case "0":
+          tmpnewchar = "零" + tmpnewchar;
+          break;
+        case "1":
+          tmpnewchar = "壹" + tmpnewchar;
+          break;
+        case "2":
+          tmpnewchar = "贰" + tmpnewchar;
+          break;
+        case "3":
+          tmpnewchar = "叁" + tmpnewchar;
+          break;
+        case "4":
+          tmpnewchar = "肆" + tmpnewchar;
+          break;
+        case "5":
+          tmpnewchar = "伍" + tmpnewchar;
+          break;
+        case "6":
+          tmpnewchar = "陆" + tmpnewchar;
+          break;
+        case "7":
+          tmpnewchar = "柒" + tmpnewchar;
+          break;
+        case "8":
+          tmpnewchar = "捌" + tmpnewchar;
+          break;
+        case "9":
+          tmpnewchar = "玖" + tmpnewchar;
+          break;
+      }
+      if (i == 0)
+        tmpnewchar = tmpnewchar + "角";
+      if (i == 1)
+        tmpnewchar = tmpnewchar + "分";
+      newchar = newchar + tmpnewchar;
+    }
+  }
+  // 替换所有无用汉字
+  while (newchar.search("零零") != -1)
+    newchar = newchar.replace("零零", "零");
+  newchar = newchar.replace("零亿", "亿");
+  newchar = newchar.replace("亿万", "亿");
+  newchar = newchar.replace("零万", "万");
+  newchar = newchar.replace("零元", "元");
+  newchar = newchar.replace("零角", "");
+  newchar = newchar.replace("零分", "");
+
+  if (newchar.charAt(newchar.length - 1) == "元" || newchar.charAt(newchar.length - 1) == "角") {
+    newchar = newchar + "整";
+  }
+
+  if (isNegative) {
+    newchar = '负' + newchar;
+  }
+
+  return newchar;
+};
+//百分比格式化,如0.15,格式化后 15%
+// util.percentFormat = function(input) {
+//   if (input == null) {
+//     return '';
+//   }
+
+//   let s = accounting.formatMoney(input, {
+//     symbol: '%',
+//     format: "%v %s"
+//   })
+//   return s;
+// };
+//验证输入字符串是否是有效的手机号码
+util.verifyMobile = function(str) {
+  let re = /^1\d{10}$/;
+  return re.test(str);
+};
+//验证输入字符串字符是否都是数字
+util.verifyNumber = function(str) {
+  let re = /^\d+(?=\.{0,1}\d+$|$)/ ;
+  return re.test(str);
+};
+//验证输入日期是否小于等于当前日期
+util.verifyLTDateNow = function(input) {
+  let a = moment(input);
+  let b = a.toDate();
+  let r = b <= Date.now();
+  return r;
+};
+//验证输入日期是否大于等于当前日期
+util.verifyGTDateNow = function(input) {
+  let now = new Date();
+  let a = moment(input);
+  let b = a.toDate();
+  let r = b >= new Date(now.getFullYear(),now.getMonth(),now.getDate());
+  return r;
+};
+//验证输入字符串字符是否有效的身份证号码
+util.verifyIdCard = function(input) {
+  if (input == null) {
+    return true;
+  }
+  return idcard.verify(input);
+};
+// 解析身份证号码字符串的信息
+util.parseIdCard = function(input) {
+  if (input == null) {
+    return '';
+  }
+
+  let cardNoInfo = idcard.info(input);
+  if (cardNoInfo && cardNoInfo.valid) {
+    let birthdayStr = cardNoInfo.birthday.toString();
+    cardNoInfo.birthdayString = birthdayStr.substr(0, 4) + "-" +
+      birthdayStr.substr(4, 2) +
+      "-" +
+      birthdayStr.substr(6, 2) +
+      " 00:00:00";
+  }
+  return cardNoInfo;
+};
+// 转化替换-年月日
+util.TimeLanguage = function (row, column,cellValue) {
+  if (!cellValue) {
+    return '';
+  }
+  moment.locale('zh-cn')
+  return moment(cellValue).format('LL');
+}
+//修改当前网页标题
+util.ui.title = function(title) {
+  title = title || window.SITE_CONFIG.appName;
+  window.document.title = title;
+};
+//关闭导航tab,formName:关闭的导航name,toName:激活的导航name,如果已打开则激活,如果未打开,则打开页面
+util.closeTabNav = function(fromName, toName) {
+
+  if (!fromName) {
+    return;
+  }
+  let vm = window.vue;
+  let contentTabsActiveName = vm.$store.state.ui.contentTabsActiveName;
+  var newTabs = vm.$store.state.ui.contentTabs.filter(item => item.name !== fromName);
+
+  vm.$store.commit('UPDATE_CONTENT_TABS', newTabs);
+  if (newTabs == null || newTabs.length == 0) {
+    vm.$router.push({
+      path: '/'
+    }, () => {
+      vm.$store.commit('UPDATE_CONTENT_TABS', []);
+    })
+    return;
+  }
+  if (toName) {
+    let routerObj = newTabs.find(p => {
+      return p.name == toName
+    })
+
+    vm.$router.push({
+      // 'name': routerObj.name
+      path: routerObj.url
+    }, () => {
+      vm.$store.commit('UPDATE_CONTENT_TABS', newTabs);
+      vm.$store.commit('UPDATE_CONTENT_TABS_ACTIVE_NAME', routerObj.name);
+    })
+  }
+};
+//关闭当前导航tab并激活toName导航,toName:激活的导航name,如果已打开则激活,如果未打开,则打开页面
+util.closeCurrentTabNav = function(toName) {
+  let vm = window.vue;
+  if (!vm.$router.currentRoute) {
+    return;
+  }
+  let fromName = vm.$router.currentRoute.name;
+  util.closeTabNav(fromName, toName);
+};
+//遍历树形实体(服务器端定义有树形结构)
+util.retriveTree = function(items, func) {
+  function innerRetriveTrees(nodes) {
+    for (let i = 0; i < nodes.length; i++) {
+      let node = nodes[i];
+      func(node);
+
+      if (node.items && node.items.length > 0) {
+        innerRetriveTrees(nodes[i].items);
+      }
+    }
+  }
+  innerRetriveTrees(items);
+}
+//读取树形实体的所有叶子结点
+util.getTreeLeafNodes = function(nodes) {
+  let leaftNodes = [];
+  util.retriveTree(nodes, (node) => {
+    if (!node.items || node.items.length == 0) {
+      leaftNodes.push(node);
+    }
+  })
+  return leaftNodes;
+};
+//树形实体转换为数组结构
+util.treeToArray = function(nodes) {
+  let allnodes = [];
+
+  util.retriveTree(nodes, (node) => {
+    let {
+      self
+    } = node;
+    Object.assign(node, self);
+    if (node._expanded === undefined) {
+      node._expanded = true;  
+    }
+    allnodes.push(node);
+  })
+  return allnodes;
+};
+//设置cookie
+util.setCookie = function(cname, cvalue, exdays) {
+  var d = new Date();
+  d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));
+  var expires = "expires=" + d.toUTCString();
+  document.cookie = cname + "=" + escape(cvalue) + "; " + expires;
+};
+//获取cookie
+util.getCookie = function(cname) {
+  var name = cname + "=";
+  var ca = document.cookie.split(';');
+  for (var i = 0; i < ca.length; i++) {
+    var c = ca[i];
+    while (c.charAt(0) == ' ') c = c.substring(1);
+    if (c.indexOf(name) != -1) return unescape(c.substring(name.length, c.length));
+  }
+  return "";
+};
+//清除cookie
+util.clearCookie = function(cname) {
+  util.setCookie(cname, "", -1);
+};
+// 根据文件名后缀区分 文件类型
+util.getFileType = function(fileName) {
+  /*
+   * @param: fileName - 文件名称
+   * @param: 数据返回 1) 无后缀匹配 - false
+   * @param: 数据返回 2) 匹配图片 - image
+   * @param: 数据返回 3) 匹配 txt - txt
+   * @param: 数据返回 4) 匹配 excel - excel
+   * @param: 数据返回 5) 匹配 word - word
+   * @param: 数据返回 6) 匹配 pdf - pdf
+   * @param: 数据返回 7) 匹配 ppt - ppt
+   * @param: 数据返回 8) 匹配 视频 - video
+   * @param: 数据返回 9) 匹配 音频 - audio
+   * @param: 数据返回 10) 其他匹配项 - other
+   */
+
+
+
+  // 后缀获取
+  var suffix = '';
+  // 获取类型结果
+  var result = '';
+  try {
+
+    var flieArr = fileName.split('.');
+    suffix = flieArr[flieArr.length - 1];
+  } catch (err) {
+    suffix = '';
+  }
+  // fileName无后缀返回 false
+
+  if (!suffix) {
+    result = false;
+    return result;
+  }
+  // 图片格式
+  var imglist = ['png', 'jpg', 'jpeg', 'bmp', 'gif'];
+  // 进行图片匹配
+  result = imglist.some(function(item) {
+    return item == suffix;
+  });
+  if (result) {
+    result = 'image';
+    return result;
+  };
+
+  // 匹配txt
+  var txtlist = ['txt'];
+  result = txtlist.some(function(item) {
+    return item == suffix;
+  });
+  if (result) {
+    result = 'txt';
+    return result;
+  };
+  // 匹配 excel
+  var excelist = ['xls', 'xlsx'];
+  result = excelist.some(function(item) {
+    return item == suffix;
+  });
+  if (result) {
+    result = 'excel';
+    return result;
+  };
+  // 匹配 word
+  var wordlist = ['doc', 'docx'];
+  result = wordlist.some(function(item) {
+    return item == suffix;
+  });
+  if (result) {
+    result = 'word';
+    return result;
+  };
+  // 匹配 pdf
+  var pdflist = ['pdf'];
+  result = pdflist.some(function(item) {
+    return item == suffix;
+  });
+
+  if (result) {
+    result = 'pdf';
+    return result;
+  };
+
+  // 匹配 ppt
+  var pptlist = ['ppt'];
+  result = pptlist.some(function(item) {
+    return item == suffix;
+  });
+
+  if (result) {
+    result = 'ppt';
+    return result;
+  };
+
+
+  // 匹配 视频
+  var videolist = ['mp4', 'm2v', 'mkv'];
+  result = videolist.some(function(item) {
+    return item == suffix;
+  });
+
+  if (result) {
+    result = 'video';
+    return result;
+  };
+
+  // 匹配 音频
+  var radiolist = ['mp3', 'wav', 'wmv'];
+  result = radiolist.some(function(item) {
+    return item == suffix;
+  });
+  if (result) {
+    result = 'audio';
+    return result;
+
+  }
+  // 其他 文件类型
+  result = 'other';
+  return result;
+};
+util.download = function(fileName, url, params) {
+  window.vue.$http.request({
+    url: url,
+    method: 'post',
+    data: params,
+    responseType: 'blob'
+  }).then(res => {
+    const content = res
+    const blob = new Blob([content])
+    if ('download' in document.createElement('a')) { // 非IE下载
+      const elink = document.createElement('a')
+      elink.download = fileName
+      elink.style.display = 'none'
+      elink.href = URL.createObjectURL(blob)
+      document.body.appendChild(elink)
+      elink.click()
+      URL.revokeObjectURL(elink.href) // 释放URL 对象
+      document.body.removeChild(elink)
+    } else { // IE10+下载
+      navigator.msSaveBlob(blob, fileName)
+    }
+  }).catch(err => {
+    alert(err);
+  })
+};
+util.YYMM = function (row, column,cellValue){
+  return util.datetimeFormat(cellValue)
+}
+util.toFixed2 = function (row, column,cellValue){
+  if(!cellValue){
+    return '';
+  }
+  return cellValue.toFixed(2)
+}
+util.ThNum = function (row, column,cellValue){
+  let a = cellValue;
+  if (!cellValue){
+    return '0.00'
+  }
+  cellValue = Number(cellValue)
+ 
+  if(!(typeof(cellValue)=="number")||isNaN(cellValue)){
+    
+    return '-'
+  }
+  // cellValue = (new Decimal(cellValue).div(100)).toFixed(2);
+  // cellValue = (new Decimal(cellValue).div(100));
+  let dcmlVal = new Decimal(cellValue).div(100);
+  if(dcmlVal.toFixed){
+      dcmlVal = (new Decimal(cellValue).div(100)).toFixed(2)
+  }else{
+      dcmlVal = (new Decimal(cellValue).div(100)).toNumber().toFixed(2)
+  }
+  cellValue = dcmlVal;//
+    
+  var intPart =  cellValue.toString().split(".")[0] // 获取整数部分
+
+  var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
+  intPartFormat= intPartFormat+"."+cellValue.toString().split(".")[1]
+  if(!intPartFormat){
+    intPartFormat = 0.00;
+  }
+  
+  return intPartFormat
+}
+util.ThNum4 = function (row, column,cellValue){
+  let a = cellValue;
+  if (!cellValue){
+    return '0.00'
+  }
+  cellValue = Number(cellValue)
+ 
+  if(!(typeof(cellValue)=="number")||isNaN(cellValue)){
+    
+    return '——'
+  }
+  // cellValue = (new Decimal(cellValue).div(100)).toFixed(2);
+  // cellValue = (new Decimal(cellValue).div(100));
+  let dcmlVal = new Decimal(cellValue).div(100);
+  if(dcmlVal.toFixed){
+      dcmlVal = (new Decimal(cellValue).div(100)).toFixed(4)
+  }else{
+      dcmlVal = (new Decimal(cellValue).div(100)).toNumber().toFixed(4)
+  }
+  cellValue = dcmlVal;//
+    
+  var intPart =  cellValue.toString().split(".")[0] // 获取整数部分
+
+  var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
+  intPartFormat= intPartFormat+"."+cellValue.toString().split(".")[1]
+  if(!intPartFormat){
+    intPartFormat = 0.00;
+  }
+  
+  return intPartFormat
+}
+ 
+util.YYMMDD = function (row, column,cellValue){
+  return util.dateFormat(cellValue)
+}
+util.ThNumW = function (row, column,cellValue) {
+
+  if (!cellValue) return ' '
+  if(!(typeof(cellValue)=="number")||isNaN(cellValue)){
+
+      return '——'
+  }
+  // cellValue = (new Decimal(cellValue).div(1000000)).toFixed(2);
+  // cellValue = (new Decimal(cellValue).div(100));
+  let dcmlVal = new Decimal(cellValue).div(1000000);
+  if(dcmlVal.toFixed){
+      dcmlVal = (new Decimal(cellValue).div(1000000)).toFixed(2)
+  }else{
+      dcmlVal = (new Decimal(cellValue).div(1000000)).toNumber().toFixed(2)
+  }
+  cellValue = dcmlVal;//
+   
+  var intPart =  cellValue.toString().split(".")[0] // 获取整数部分
+
+  var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
+  intPartFormat= intPartFormat+"."+cellValue.toString().split(".")[1]
+  
+  return intPartFormat
+   
+  
+}
+util.dieTausendstel = function (model,str,num=2){
+  // var value = modelp[str].toString();
+  var amount = model[str];
+  if(Object.is(Number(amount),NaN)) return  model[str] = '0.00'
+  if (amount) {
+    model[str] = Number(model[str]).toFixed(num)
+    var intPart =  model[str].toString().split(".")[0] // 获取整数部分
+    var intpart1 = model[str].toString().split(".")[1]
+    intPart= intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') ;
+     
+    if(intpart1){
+      model[str] = intPart+"."+intpart1 
+    }else{
+      model[str] = intPart+".00"
+    }
+    return model[str];
+  }
+}
+util.rushTausendstel = function (model,str){
+  var amount = model[str];
+  if (amount) {
+      
+      var intPart =  model[str].toString().split(".")[0] // 获取整数部分
+      var intpart1 = model[str].toString().split(".")[1]
+      
+      if(intPart.indexOf(",")>0){
+        intPart = intPart.replace(/,/g,"")
+      }
+      if(intpart1){
+        model[str] = intPart+"."+intpart1 
+      }else{
+        model[str] = intPart+".00"
+      }
+      return model[str];
+  }
+}
+
+export default util;

BIN
src/assets/newlogo.png


BIN
src/assets/newlogo2.png


+ 57 - 0
src/components/ProcessDiagramDialog.vue

@@ -0,0 +1,57 @@
+<template>
+  <el-dialog :title="processDiagramTitle" v-if="processDiagramDialogVisible" :visible.sync="processDiagramDialogVisible">
+    <img class="img-responsive" :src="processDiagramSrc" />
+    <img />
+    <div slot="footer" class="dialog-footer">
+      <el-button @click="processDiagramDialogVisible = false">关 闭</el-button>
+      <!-- <el-button type="primary" @click="processDiagramDialogVisible = false">确 定</el-button> -->
+    </div>
+  </el-dialog>
+</template>
+<style>
+.img-responsive {
+  display: inline-block;
+  height: auto;
+  max-width: 100%;
+}
+</style>
+<script>
+export default {
+    data() {
+        return {
+            processDiagramDialogVisible: false
+        }
+    },
+    watch: {
+    	   screenWidth (val) {
+             if(val < 990){
+             	this.testspan = 24;
+             }else{
+             	this.testspan = 12;
+             }
+          }
+    },
+    mounted () {
+        const that = this
+        window.onresize = () => {
+            return (() => {
+                window.screenWidth = document.body.clientWidth
+                that.screenWidth = window.screenWidth
+            })()
+        }
+    },
+    methods: {
+        showProcessDiagram(row) {
+            if (row.processInstanceId) {
+                this.processDiagramDialogVisible = true;
+                this.processDiagramSrc = this.$url.processinst.showDiagramByTask + "/" + row.taskid;
+                this.processDiagramTitle = "流程轨迹-" + row.title;
+            }else if(row.procinstid){
+                this.processDiagramDialogVisible = true;
+                this.processDiagramSrc = this.$url.processinst.showDiagramByTask + "/" + row.taskid;
+                this.processDiagramTitle = "流程轨迹-" + row.programmecode;
+            }
+        }
+    }
+};
+</script>

+ 6 - 0
src/components/common/bus.js

@@ -0,0 +1,6 @@
+import Vue from 'vue';
+
+// 使用 Event Bus
+const bus = new Vue();
+
+export default bus;

+ 9 - 0
src/components/components/approvalDialog/index-mixins.js

@@ -0,0 +1,9 @@
+export default {
+  created() {
+    processDefinitionKey.call(this, this.processDefinitionKey, false)
+  }
+}
+export const processDefinitionKey = function(processDefinitionKey, isGetService) {
+ 
+  
+}

+ 16 - 0
src/components/components/approvalDialog/index.vue

@@ -0,0 +1,16 @@
+<script>
+import index from './index-mixins'
+export default {
+  mixins:[index],
+  name: 'rootApprovaComponent',
+  data() {
+    return {}
+  },
+  props: {
+    processDefinitionKey: {
+      type: String,
+      default: '',
+    }
+  }
+}
+</script>

+ 5 - 1
src/components/el-form.vue

@@ -147,5 +147,9 @@ export default {
 };
 </script>
 
-<style>
+<style lang="scss" scoped>
+.btn{
+  display: flex;
+  justify-content: center;
+}
 </style>

+ 58 - 24
src/components/newTree.vue

@@ -2,6 +2,8 @@
   <div class="flex-box">
     <div class="treebox">
       <div class="tree-text">组织机构</div>
+      <el-input placeholder="可按名字匹配所在部门" v-model="filterText">
+      </el-input>
       <el-tree
         ref="tree"
         @node-click="handleNodeClick"
@@ -26,7 +28,6 @@
       <el-transfer
         v-model="value"
         :titles="['待选人员', '已选人员']"
-        filterable
         @change="handleCheckChange"
         :data="transferList"
       ></el-transfer>
@@ -39,9 +40,11 @@ export default {
   props: ["defaultList", "type"],
   data() {
     return {
+      filterTexts: "",
+      filterText: "",
       transferList: [],
       treeList: [],
-      treeLists:[],
+      treeLists: [],
       rightList: [],
       value: [],
       newArr: [],
@@ -56,6 +59,24 @@ export default {
   },
   methods: {
     handleNodeClick(v) {
+      for(let i = v.children.length-1;i>=0;i--){
+        if(v.children[i].haveUserFlag == "N"){
+          v.children.splice(i, 1);
+        }
+      }
+      // v.children.map((item,index) =>{
+        
+      //   if(item.haveUserFlag == "N"){
+      //     v.children.splice(index, 1);
+      //   }
+      //   console.log(v.children);
+      // })
+      let list = {
+        groupId: v.o,
+      };
+      if (this.filterTexts) {
+        list.loginNameStr = this.filterTexts;
+      }
       if (v.o !== this.treeId) {
         if (this.value.length !== 0) {
           let a = [];
@@ -87,22 +108,20 @@ export default {
       }
       if (v.o !== this.treeId) {
         this.$http({
-          url: "/sysmgr/sysuserinfo/queryList",
+          url: "/sysmgr/sysuserinfo/queryListByName",
           method: "post",
           headers: {
             "Content-Type": "application/json",
           },
-          data: {
-            groupId: v.o,
-          },
+          data:list
         }).then((res) => {
+          v.children = v.children ? v.children : [];
           this.treeId = v.o;
-          this.treeLists = res.data
+          this.treeLists = res.data;
           res.data.map((item, index) => {
             this.transferList.push({
               label: item.loginNameStr,
-              key: item.loginNoStr
-,
+              key: item.loginNoStr,
             });
           });
         });
@@ -110,20 +129,29 @@ export default {
         console.log(this.transferList);
       }
     },
-    getTree(v) {
+    getTree(v,e) {
+      let list = {
+        parentorgid: v,
+        // functionName: e,
+      };
+      if (e) {
+        list.functionName = e;
+      }
+      this.loading = true;
       this.$http({
         url: "/sysmgr/csysdept/queryAllList",
         method: "post",
         headers: {
           "Content-Type": "application/json",
         },
-        data: {
-          parentorgid: v,
-        },
+        data: list,
       }).then((res) => {
+        this.loading = false;
         this.treeList = res.data;
-
-        console.log(this.treeLists);
+        let list = res.data[0].children.filter((item, i, array) => {
+          return item.haveUserFlag === "Y";
+        });
+        this.treeList[0].children = list;
       });
     },
     handleCheckChange(v) {
@@ -143,24 +171,30 @@ export default {
       //   }
       // }
       // console.log(opt);
-      console.log(this.transferList);
-      console.log(this.value);
       let opt = [];
-      this.transferList.map((item) =>{
-        this.value.map((items) =>{
-          if(item.key === items){
-            opt.push(item)
+      this.transferList.map((item) => {
+        this.value.map((items) => {
+          if (item.key === items) {
+            opt.push(item);
           }
-        })
-      })
+        });
+      });
       console.log(opt);
-      this.$emit("treeCheck",opt);
+      this.$emit("treeCheck", opt);
     },
   },
   created() {
     this.getTree();
     this.defaultListc = this.defaultList;
   },
+  watch: {
+    filterText(val) {
+      // this.$refs.tree.filter(val);
+      console.log(val);
+      this.filterTexts = val;
+      this.getTree("", this.filterTexts);
+    },
+  },
 };
 </script>
 

+ 162 - 32
src/components/workflow.vue

@@ -1,6 +1,7 @@
 <template>
   <div>
     <div class="flex-handle">
+      <!-- <button @click="qqq">123</button> -->
       <div class="flex-left">
         <div class="flex-left-header">
           <div class="flex-path">
@@ -52,11 +53,10 @@
           </el-input>
         </div>
       </div>
-      <div class="flex-right" :class="{ copyClass: CopyStatus }">
-        <div
-          class="flex-left-header-text"
-          :class="{ 'flex-right-text': CopyStatus }"
-        >
+      <!-- :class="{ copyClass: CopyStatus }" -->
+      <!-- :class="{ 'flex-right-text': CopyStatus }" -->
+      <div class="flex-right">
+        <div class="flex-left-header-text">
           本部门人员办理
           <div style="display: flex">
             <div class="flex-header-text-tree">
@@ -74,7 +74,7 @@
             </div>
           </div>
         </div>
-        <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
+        <!-- <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
           抄送人员
           <div style="display: flex">
             <div class="flex-header-text-tree">
@@ -91,7 +91,7 @@
               <div class="">{{ copyUser }}</div>
             </div>
           </div>
-        </div>
+        </div> -->
       </div>
     </div>
     <div class="flex-footer-botton">
@@ -99,6 +99,29 @@
         <el-button type="primary" @click="submitWork()">提交</el-button>
       </div>
     </div>
+    <el-dialog
+      title="修改常用意见"
+      :visible.sync="editStatus"
+      width="100%"
+      :before-close="editCloses"
+      :modal="false"
+      :destroy-on-close="true"
+    >
+      <div style="overflow-y: scroll; overflow-x: hidden; height: 240px">
+        <div
+          v-for="(item, index) in commonlyList"
+          :key="index"
+          ref="common"
+          class="flex-common"
+        >
+          {{ item.dataName
+          }}<i class="el-icon-circle-close" @click="deleStatus(item)"></i>
+        </div>
+        <div class="flex-common">
+          <i class="el-icon-circle-plus-outline" @click="addStatus()"></i>
+        </div>
+      </div>
+    </el-dialog>
   </div>
 </template>
 
@@ -118,14 +141,18 @@ export default {
       node: [], //路径列表
       seleIndex: "", //点击路径下标
       commonlyList: [], //常用意见数组
-      textarea: "", //意见内容字段
+      textarea: "未填写意见", //意见内容字段
       copyUser: "", //抄送人员列表
       selectUser: "", //已选人员列表
       treeList: [], // 待选人员列表
       propsList: [],
       nodes: [],
-      initialList :[],//第一次进入是加载节点
-      clicknextName:''//获取的流程节点
+      initialList: [], //第一次进入是加载节点
+      clicknextName: "", //获取的流程节点
+      backThree: [],
+      editStatus: false, //修改控制显示字段
+      treeCopyList: [],
+      demand: "",
     };
   },
   props: {
@@ -134,13 +161,39 @@ export default {
     list: {
       type: Object,
     },
+    requestForm: {
+      type: Object,
+    },
   },
   created() {
+    console.log(this.list);
     this.getNextPath(this.list.resourceId, 1);
     this.getMetirialType();
   },
   methods: {
+    //生成需求决策编号接口
+    getDemand() {
+      this.$http({
+        url: "/market/waf/getBusi",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data:{}
+      }).then((res) => {
+        console.log(res);
+        this.demand = res.data;
+      });
+    },
     submitWork() {
+      //生成需求决策编号
+      if (this.clicknextName === "起草人发送") {
+        this.getDemand()
+      }
+      if (!this.list.taskId) {
+        this.$message.error("请先保存表单后处理");
+        return false;
+      }
       if (this.TransferStatus === true) {
         if (this.backThree.length > 0) {
           this.nextWork();
@@ -158,9 +211,9 @@ export default {
           // resolution: this.nodes.currentShape[0].condition.resolution, //流程图线节点
           // nextDealMan: this.backThree[0].loginNoStr || '', //下一步处理人
         };
-        if (this.copyUser) {
+        if (this.treeCopyList.length) {
           //抄送
-          list.copyman = this.backCopyThree[0].loginNoStr;
+          list.copyman = this.treeCopyList[0].loginNoStrCopy;
         }
         if (this.nodes.currentShape) {
           list.resolution = this.nodes.currentShape[0].condition.resolution;
@@ -218,7 +271,10 @@ export default {
             };
             if (data.copytaskid) {
               list.copytaskid = data.copytaskid;
-              list.copyman = _this.backCopyThree[0].loginNoStr;
+              list.copyman = _this.treeCopyList[0].loginNoStrCopy;
+            }
+            if(_this.demand){
+              list.needNo = _this.demand
             }
             _this.setUpdate(list);
           }
@@ -229,11 +285,12 @@ export default {
           };
           _this.setUpdate(list);
         }
-        _this.dialogStatus = false;
-        _this.handleCloses();
       }
     },
-     //更新工作流接口
+    // qqq() {
+    //   this.$emit("beforeClose", true);
+    // },
+    //更新工作流接口
     setUpdate(e) {
       this.$http({
         url: "/market/waf/update",
@@ -243,6 +300,7 @@ export default {
         },
         data: e,
       }).then((res) => {
+        this.$emit("beforeClose", true);
         // this.fromList.taskId = res.data.body.taskId;
         // this.fromList.taskName = res.data.body.taskName;
         // if (res.data.body.taskName === "起草") {
@@ -259,14 +317,16 @@ export default {
     getNextPath(e, status) {
       let list = {
         // fresourceId: "bf79721c-33f3-11ed-ba0b-00505687dcd3", //测试环境
-        fresourceId: "0d94de8a-0281-11ed-a302-4ae7da54db39", // 本地环境
-        processId: "request_form_process",
-        resourceId: e,
+        fresourceId: this.requestForm.fresourceId, // 本地环境
+        processId: this.requestForm.processDefinitionKey,
+        // fresourceId: "0d94de8a-0281-11ed-a302-4ae7da54db39", // 本地环境
+        // processId: "request_form_process",
+        // resourceId: e,
       };
-      //   if (e) {
-      //     this.propsList = [];
-      //     list.resourceId = e;
-      //   }
+      if (e) {
+        // this.propsList = [];
+        list.resourceId = e;
+      }
       this.$http({
         url: "/market/waf/queryPath",
         method: "post",
@@ -288,9 +348,9 @@ export default {
             this.transferStatus = false;
           }
           if (res.data.body.nextShapes[0].copy !== null) {
-            console.log(res.data.body.nextShapes[0].copy.copy);
             if (res.data.body.nextShapes[0].copy.copy === "true") {
-              this.copyStatus = true; //抄送按钮生效
+              // this.copyStatus = true; //抄送按钮生效
+              this.CopyStatus = true;
             } else {
               this.copyStatus = false;
             }
@@ -316,10 +376,17 @@ export default {
     },
     //查询候选人接口
     getTreeLists(e, status) {
-      let id =
-        e.nextShapes[0].properties.documentation == "createId"
-          ? this.fromList.createId
-          : e.nextShapes[0].properties.documentation;
+      let id = "";
+      if (status === 2) {
+        id = "copy." + e;
+      } else {
+        id =
+          e.nextShapes[0].properties.documentation == "createId" ||
+          e.nextShapes[0].properties.documentation == "createId-copy"
+            ? this.list.createId
+            : e.nextShapes[0].properties.documentation;
+      }
+
       this.$http({
         url: "/market/api/user/info/queryNodePers?params=" + id,
         method: "post",
@@ -331,6 +398,7 @@ export default {
         console.log(status);
         if (status === 2) {
           this.treeCopyList = res.data; //抄送
+          console.log(this.treeCopyList);
           //  this.$refs.defTrees.treeList = res.data;
         } else {
           this.treeList = res.data; //抄送
@@ -350,11 +418,11 @@ export default {
     },
     //点击节点获取下一步的处理人字段
     clickGetTree(e, index) {
-      this.CopyStatus = false;
+      // this.CopyStatus = false;
       this.TransferStatus = false;
       //   this.clickTaskName = e.properties.name;
-        this.clicknextName = e.properties.name;
-        this.seleIndex = index;
+      this.clicknextName = e.properties.name;
+      this.seleIndex = index;
       this.getNextPath(e.resourceId, 3); //1 为点击后获取线
     },
     //点击常用意见方法
@@ -363,6 +431,7 @@ export default {
     },
     //点击修改
     clickEdit() {
+      console.log(123);
       this.editStatus = true;
     },
     //选择树的回调
@@ -371,7 +440,12 @@ export default {
         this.$message.error("只能选择一个人");
         return;
       } else {
+        console.log(e);
         this.backThree = e;
+        if (this.CopyStatus === true) {
+          this.getTreeLists(e[0].loginNoStr, 2);
+        }
+
         if (e[0]) {
           this.selectUser = e[0].loginNameStr;
         } else {
@@ -421,6 +495,62 @@ export default {
         this.getMetirialType();
       });
     },
+    //常用意见添加
+    addStatus() {
+      let newData = Date.parse(new Date());
+      this.$prompt("请输入常用意见", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+      })
+        .then(({ value }) => {
+          let list = {
+            dictCode: "approval",
+            dataCode: newData,
+            dataName: value,
+            dictName: "审批意见",
+          };
+          this.geaddctType(list);
+          this.$message({
+            type: "success",
+            message: "常用意见添加成功",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "取消输入",
+          });
+        });
+    },
+    //常用意见删除
+    deleStatus(e) {
+      this.$confirm("此操作将删除此常用意见, 是否继续?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let list = {
+            dataCode: e.dataCode,
+            dictCode: "approval",
+          };
+          this.geDelectType(list);
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    //关闭修改
+    editCloses() {
+      this.editStatus = false;
+    },
   },
 };
 </script>

+ 592 - 0
src/components/workflowBase.vue

@@ -0,0 +1,592 @@
+<template>
+  <div>
+    <div class="flex-handle">
+      <div class="flex-left">
+        <div class="flex-left-header">
+          <div class="flex-path">
+            <div class="flex-left-header-text">
+              选择路径
+
+              <div class="flex-path-list">
+                <div v-if="transferStatus" @click="clickTransfer(1)">转派</div>
+                <div v-if="copyStatus" @click="clickTransfer(2)">抄送</div>
+                <div
+                  v-for="(item, index) in node.nextShapes"
+                  :key="index"
+                  :class="seleIndex == index ? 'active' : ''"
+                  @click="clickGetTree(item, index)"
+                >
+                  {{ item.properties.name }}
+                </div>
+              </div>
+            </div>
+          </div>
+          <div class="flex-commons">
+            <div class="flex-left-header-text">
+              常用意见
+              <span @click="clickEdit" class="flex-icon"
+                ><i class="el-icon-edit"></i>修改</span
+              >
+            </div>
+            <div class="flex-slide">
+              <div
+                v-for="(item, index) in commonlyList"
+                :key="index"
+                ref="common"
+                class="flex-common"
+                @click="clickCommonly($event)"
+              >
+                {{ item.dataName }}
+              </div>
+            </div>
+          </div>
+        </div>
+        <div class="flex-opinion">
+          <div class="flex-left-header-text">意见内容</div>
+          <el-input
+            type="textarea"
+            autosize
+            placeholder="请输入内容"
+            v-model="textarea"
+          >
+          </el-input>
+        </div>
+      </div>
+      <div class="flex-right" :class="{ copyClass: CopyStatus }">
+        <div
+          class="flex-left-header-text"
+          :class="{ 'flex-right-text': CopyStatus }"
+        >
+          本部门人员办理
+          <div style="display: flex">
+            <div class="flex-header-text-tree">
+              候选人
+              <deptTree
+                ref="defTree"
+                class="flex-slide"
+                :treeList="treeList"
+                @changeTree="changeTree"
+              />
+            </div>
+            <div class="flex-header-text-tree">
+              已选人员
+              <div class="">{{ selectUser }}</div>
+            </div>
+          </div>
+        </div>
+        <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
+          抄送人员
+          <div style="display: flex">
+            <div class="flex-header-text-tree">
+              抄送人
+              <deptTree
+                ref="defTrees"
+                class="flex-slide"
+                :treeList="treeCopyList"
+                @changeTree="changeTreeCopy"
+              />
+            </div>
+            <div class="flex-header-text-tree">
+              已选人员
+              <div class="">{{ copyUser }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+    <div class="flex-footer-botton">
+      <div class="flex-button">
+        <el-button type="primary" @click="submitWork()">提交</el-button>
+      </div>
+    </div>
+    <el-dialog
+      title="修改常用意见"
+      :visible.sync="editStatus"
+      width="100%"
+      :before-close="editCloses"
+      :modal="false"
+      :destroy-on-close="true"
+    >
+      <div style="overflow-y: scroll; overflow-x: hidden; height: 240px">
+        <div
+          v-for="(item, index) in commonlyList"
+          :key="index"
+          ref="common"
+          class="flex-common"
+        >
+          {{ item.dataName
+          }}<i class="el-icon-circle-close" @click="deleStatus(item)"></i>
+        </div>
+        <div class="flex-common">
+          <i class="el-icon-circle-plus-outline" @click="addStatus()"></i>
+        </div>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import deptTree from "./workDeptThree.vue";
+export default {
+  components: {
+    deptTree,
+  },
+  name: "workflow",
+  data() {
+    return {
+      transferStatus: false, //转派按钮控制
+      TransferStatus: false, //是否点击转派状态
+      copyStatus: false, //抄送按钮控制
+      CopyStatus: false, //是否点击抄送状态
+      node: [], //路径列表
+      seleIndex: "", //点击路径下标
+      commonlyList: [], //常用意见数组
+      textarea: "未填写意见", //意见内容字段
+      copyUser: "", //抄送人员列表
+      selectUser: "", //已选人员列表
+      treeList: [], // 待选人员列表
+      propsList: [],
+      nodes: [],
+      initialList: [], //第一次进入是加载节点
+      clicknextName: "", //获取的流程节点
+      backThree: [],
+    };
+  },
+  props: {
+    //  表格数据和表格部分属性的对象
+    // eslint-disable-next-line vue/require-default-prop
+    list: {
+      type: Object,
+    },
+    requestForm: {
+      type: Object,
+    },
+  },
+  created() {
+    this.getNextPath(this.list.resourceId, 1);
+    this.getMetirialType();
+  },
+  methods: {
+    submitWork() {
+      if (this.TransferStatus === true) {
+        if (this.backThree.length > 0) {
+          this.nextWork();
+        } else {
+          this.$message.error("请选择候选人");
+          return false;
+        }
+      } else {
+        let list = {
+          userId: JSON.parse(window.sessionStorage.userInfo).loginNo, //人员id
+          taskId: this.list.taskId, //表单标识
+          taskName: this.clicknextName, //流程节点
+          userCode: JSON.parse(window.sessionStorage.userInfo).loginNo, //人员code
+          content: this.textarea, //意见内容
+          // resolution: this.nodes.currentShape[0].condition.resolution, //流程图线节点
+          // nextDealMan: this.backThree[0].loginNoStr || '', //下一步处理人
+        };
+        if (this.copyUser) {
+          //抄送
+          list.copyman = this.backCopyThree[0].loginNoStr;
+        }
+        if (this.nodes.currentShape) {
+          list.resolution = this.nodes.currentShape[0].condition.resolution;
+          list.approve = this.nodes.currentShape[0].condition.approve;
+        }
+        if (this.clicknextName === "") {
+          this.$message.error("请选择流程节点");
+          return false;
+        }
+        if (this.backThree.length > 0) {
+          list.nextDealMan = this.backThree[0].loginNoStr;
+        } else {
+          if (this.clicknextName === "流程结束") {
+          } else {
+            this.$message.error("请选择候选人");
+            return false;
+          }
+        }
+        this.nextWork(list);
+      }
+    },
+    async nextWork(list) {
+      //e:yes||no,list:传入数组,title:结束标签,res:驳回标签,id:工单更新id
+      let _this = this;
+      let obj = {
+        url: _this.$url.formList.nextWork, //下一步工作流接口
+        data: list,
+        status: "form",
+      };
+      if (_this.TransferStatus === true) {
+        let lists = {
+          userId: _this.backThree[0].loginNoStr,
+          taskId: _this.list.taskId,
+          content: _this.textarea,
+          tableName: _this.requestForm.processDefinitionKey,
+        };
+        obj.url = _this.$url.formList.transferTask + _this.list.taskId;
+        obj.data = lists;
+      }
+      await this.common.httpPost(obj, success);
+      function success(data) {
+        if (data != null) {
+          if (_this.TransferStatus === true) {
+            let list = {
+              taskId: data.taskid,
+              id: _this.list.id,
+              tableName: _this.requestForm.processDefinitionKey,
+            };
+
+            _this.setUpdate(list);
+          } else {
+            let list = {
+              taskId: data.taskid,
+              id: _this.list.id,
+              resourceId: _this.nodes.currentShape[0].resourceId,
+              taskName: _this.nodes.nextShapes[0].properties.name,
+              tableName: _this.requestForm.processDefinitionKey,
+            };
+            if (data.copytaskid) {
+              list.copytaskid = data.copytaskid;
+              list.copyman = _this.backCopyThree[0].loginNoStr;
+              // list.tableName = _this.requestForm.processDefinitionKey;
+            }
+            _this.setUpdate(list);
+          }
+        } else {
+          let list = {
+            taskName: "结束",
+            id: _this.list.id,
+            tableName: _this.requestForm.processDefinitionKey,
+          };
+          _this.setUpdate(list);
+        }
+        _this.dialogStatus = false;
+        _this.handleCloses();
+      }
+    },
+    setUpdate(e) {
+      this.$http({
+        url: "/market/waf/updateBase",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.$emit("updateForm", true);
+      });
+    },
+    //查询路径接口
+    getNextPath(e, status) {
+      let list = {
+        // fresourceId: "bf79721c-33f3-11ed-ba0b-00505687dcd3", //测试环境
+        fresourceId: this.requestForm.fresourceId, // 本地环境
+        processId: this.requestForm.processDefinitionKey,
+        // resourceId: e,
+      };
+      if (e) {
+        list.resourceId = e;
+      }
+      this.$http({
+        url: "/market/waf/queryPath",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: list,
+      }).then((res) => {
+        if (status === 1) {
+          //第一次进入取路径
+          this.initialList = res.data.body;
+          if (res.data.body.nextShapes[0].loop !== null) {
+            if (res.data.body.nextShapes[0].loop.loop === "true") {
+              this.transferStatus = true; //转派按钮生效
+            } else {
+              this.transferStatus = false;
+            }
+          } else {
+            this.transferStatus = false;
+          }
+          if (res.data.body.nextShapes[0].copy !== null) {
+            console.log(res.data.body.nextShapes[0].copy.copy);
+            if (res.data.body.nextShapes[0].copy.copy === "true") {
+              this.copyStatus = true; //抄送按钮生效
+            } else {
+              this.copyStatus = false;
+            }
+          } else {
+            this.copyStatus = false;
+          }
+          res.data.body.currentShape.map((item, index) => {
+            this.getNextPath(item.resourceId, 2);
+          });
+        }
+        if (status === 2) {
+          if (res.data.body.nextShapes[0].condition !== null) {
+            this.node = res.data.body;
+          } else {
+            this.getNextPath(res.data.body.nextShapes[0].resourceId, 2);
+          }
+        }
+        if (status === 3) {
+          this.nodes = res.data.body;
+          this.getTreeLists(res.data.body, 1);
+        }
+      });
+    },
+    //查询候选人接口
+    getTreeLists(e, status) {
+      let createdId = "createld";
+      let id =
+        e.nextShapes[0].properties.documentation === createdId
+          ? this.list.createId
+          : e.nextShapes[0].properties.documentation;
+      console.log(id);
+      this.$http({
+        url: "/market/api/user/info/queryNodePers?params=" + id,
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: "",
+      }).then((res) => {
+        console.log(status);
+        if (status === 2) {
+          this.treeCopyList = res.data; //抄送
+          //  this.$refs.defTrees.treeList = res.data;
+        } else {
+          this.treeList = res.data; //抄送
+          // this.$refs.defTree.treeList = res.data;
+          console.log(this.treeList);
+        }
+      });
+    },
+    //转派按钮方法
+    clickTransfer(e) {
+      if (e == 1) {
+        this.TransferStatus = true;
+      } else if (e == 2) {
+        this.CopyStatus = true;
+      }
+      this.getTreeLists(this.initialList, e);
+    },
+    //点击节点获取下一步的处理人字段
+    clickGetTree(e, index) {
+      this.CopyStatus = false;
+      this.TransferStatus = false;
+      //   this.clickTaskName = e.properties.name;
+      this.clicknextName = e.properties.name;
+      this.seleIndex = index;
+      this.getNextPath(e.resourceId, 3); //1 为点击后获取线
+    },
+    //点击常用意见方法
+    clickCommonly(e) {
+      this.textarea = e.currentTarget.innerHTML;
+    },
+    //点击修改
+    clickEdit() {
+      this.editStatus = true;
+    },
+    //选择树的回调
+    changeTree(e) {
+      if (e.length > 1) {
+        this.$message.error("只能选择一个人");
+        return;
+      } else {
+        this.backThree = e;
+        if (e[0]) {
+          this.selectUser = e[0].loginNameStr;
+        } else {
+          this.selectUser = "暂无选择";
+        }
+      }
+    },
+    //获取字典表常用意见
+    getMetirialType(e) {
+      this.$http({
+        url: "/market/cfgDataDict/queryList",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "approval",
+        },
+      }).then((res) => {
+        console.log(res);
+        this.commonlyList = res.data;
+      });
+    },
+    //添加字典表常用意见
+    geaddctType(e) {
+      this.$http({
+        url: "/market/cfgDataDict/add",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.getMetirialType();
+      });
+    },
+    //关闭修改
+    editCloses() {
+      this.editStatus = false;
+    },
+    //常用意见添加
+    addStatus() {
+      let newData = Date.parse(new Date());
+      this.$prompt("请输入常用意见", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+      })
+        .then(({ value }) => {
+          let list = {
+            dictCode: "approval",
+            dataCode: newData,
+            dataName: value,
+            dictName: "审批意见",
+          };
+          this.geaddctType(list);
+          this.$message({
+            type: "success",
+            message: "常用意见添加成功",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "取消输入",
+          });
+        });
+    },
+    //常用意见删除
+    deleStatus(e) {
+      this.$confirm("此操作将删除此常用意见, 是否继续?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let list = {
+            dataCode: e.dataCode,
+            dictCode: "approval",
+          };
+          this.geDelectType(list);
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    //删除字典表常用意见
+    geDelectType(e) {
+      this.$http({
+        url: "/market/cfgDataDicts/del",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.getMetirialType();
+      });
+    },
+  },
+};
+</script>
+
+<style lang='scss' scoped>
+.flex-header-text-tree {
+  width: 50%;
+  text-align: center;
+}
+.flex-icon {
+  float: right;
+  margin-right: 20px;
+  color: #4277a1;
+}
+.flex-handle {
+  width: 100%;
+  padding: 30px;
+  display: flex;
+  .flex-right {
+    width: 50%;
+    border: 1px solid #e1e1e1;
+    margin-left: 20px;
+  }
+}
+.flex-left {
+  width: 50%;
+  display: flex;
+  flex-direction: column;
+  .flex-left-header {
+    display: flex;
+    justify-content: space-around;
+    .flex-path {
+      height: 280px;
+      border: 1px solid #e1e1e1;
+      width: 68%;
+    }
+  }
+}
+.flex-common {
+  padding: 10px 5%;
+  font-size: 18px;
+}
+.flex-left-header-text {
+  height: 40px;
+  line-height: 40px;
+  color: black;
+  padding-left: 10px;
+  background-color: #cde4f6;
+  font-size: 18px;
+  font-weight: bold;
+}
+.flex-path-list {
+  overflow-y: scroll;
+  overflow-x: hidden;
+  height: 14rem;
+}
+.flex-slide {
+  overflow-y: scroll;
+  overflow-x: hidden;
+}
+.active {
+  background-color: #f3faff;
+}
+.flex-opinion {
+  height: 280px;
+  border: 1px solid #e1e1e1;
+  width: 100%;
+  margin-top: 20px;
+}
+.flex-right-text {
+  margin-right: 20px;
+  width: 50%;
+}
+.flex-commons {
+  height: 280px;
+  border: 1px solid #e1e1e1;
+  width: 30%;
+}
+.flex-footer-botton {
+  display: flex;
+  justify-content: space-evenly;
+}
+.flex-button {
+  margin-top: 10px;
+  margin-bottom: 10px;
+  ::v-deep .el-button--primary {
+    width: 222px;
+  }
+}
+</style>

+ 662 - 0
src/components/workflowEntrance.vue

@@ -0,0 +1,662 @@
+<template>
+  <div>
+    <div class="flex-handle">
+      <!-- <button @click="qqq">123</button> -->
+      <div class="flex-left">
+        <div class="flex-left-header">
+          <div class="flex-path">
+            <div class="flex-left-header-text">
+              选择路径
+
+              <div class="flex-path-list">
+                <div @click="clickTransfer(1)">转派</div>
+                <div @click="clickTransfer(2)">结束</div>
+                <!-- <div
+                  v-for="(item, index) in node.nextShapes"
+                  :key="index"
+                  :class="seleIndex == index ? 'active' : ''"
+                  @click="clickGetTree(item, index)"
+                > 
+                  {{ item.properties.name }}
+                </div> -->
+              </div>
+            </div>
+          </div>
+          <div class="flex-commons">
+            <div class="flex-left-header-text">
+              常用意见
+              <span @click="clickEdit" class="flex-icon"
+                ><i class="el-icon-edit"></i>修改</span
+              >
+            </div>
+            <div class="flex-slide">
+              <div
+                v-for="(item, index) in commonlyList"
+                :key="index"
+                ref="common"
+                class="flex-common"
+                @click="clickCommonly($event)"
+              >
+                {{ item.dataName }}
+              </div>
+            </div>
+          </div>
+        </div>
+        <div class="flex-opinion">
+          <div class="flex-left-header-text">意见内容</div>
+          <el-input
+            type="textarea"
+            autosize
+            placeholder="请输入内容"
+            v-model="textarea"
+          >
+          </el-input>
+        </div>
+      </div>
+      <!-- :class="{ copyClass: CopyStatus }" -->
+      <!-- :class="{ 'flex-right-text': CopyStatus }" -->
+      <div class="flex-right">
+        <div class="flex-left-header-text">
+          本部门人员办理
+          <div style="display: flex">
+            <div class="flex-header-text-tree">
+              候选人
+              <deptTree
+                ref="defTree"
+                class="flex-slide"
+                :treeList="treeList"
+                @changeTree="changeTree"
+              />
+            </div>
+            <div class="flex-header-text-tree">
+              已选人员
+              <div class="">{{ selectUser }}</div>
+            </div>
+          </div>
+        </div>
+        <!-- <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
+          抄送人员
+          <div style="display: flex">
+            <div class="flex-header-text-tree">
+              抄送人
+              <deptTree
+                ref="defTrees"
+                class="flex-slide"
+                :treeList="treeCopyList"
+                @changeTree="changeTreeCopy"
+              />
+            </div>
+            <div class="flex-header-text-tree">
+              已选人员
+              <div class="">{{ copyUser }}</div>
+            </div>
+          </div>
+        </div> -->
+      </div>
+    </div>
+    <div class="flex-footer-botton">
+      <div class="flex-button">
+        <el-button type="primary" @click="submitWork()">提交</el-button>
+      </div>
+    </div>
+    <el-dialog
+      title="修改常用意见"
+      :visible.sync="editStatus"
+      width="100%"
+      :before-close="editCloses"
+      :modal="false"
+      :destroy-on-close="true"
+    >
+      <div style="overflow-y: scroll; overflow-x: hidden; height: 240px">
+        <div
+          v-for="(item, index) in commonlyList"
+          :key="index"
+          ref="common"
+          class="flex-common"
+        >
+          {{ item.dataName
+          }}<i class="el-icon-circle-close" @click="deleStatus(item)"></i>
+        </div>
+        <div class="flex-common">
+          <i class="el-icon-circle-plus-outline" @click="addStatus()"></i>
+        </div>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import deptTree from "./workDeptThree.vue";
+export default {
+  components: {
+    deptTree,
+  },
+  name: "workflow",
+  data() {
+    return {
+      transferStatus: false, //转派按钮控制
+      TransferStatus: false, //是否点击转派状态
+      copyStatus: false, //抄送按钮控制
+      CopyStatus: false, //是否点击抄送状态
+      node: [], //路径列表
+      seleIndex: "", //点击路径下标
+      commonlyList: [], //常用意见数组
+      textarea: "未填写意见", //意见内容字段
+      copyUser: "", //抄送人员列表
+      selectUser: "", //已选人员列表
+      treeList: [], // 待选人员列表
+      propsList: [],
+      nodes: [],
+      initialList: [], //第一次进入是加载节点
+      clicknextName: "", //获取的流程节点
+      backThree: [],
+      editStatus: false, //修改控制显示字段
+      treeCopyList: [],
+      demand: "",
+    };
+  },
+  props: {
+    //  表格数据和表格部分属性的对象
+    // eslint-disable-next-line vue/require-default-prop
+    list: {
+      type: Object,
+    },
+    requestForm: {
+      type: Object,
+    },
+  },
+  created() {
+    this.getNextPath(this.list.resourceId, 1);
+    this.getMetirialType();
+  },
+  methods: {
+    //生成需求决策编号接口
+    getDemand() {
+      this.$http({
+        url: "/market/waf/getBusi",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {},
+      }).then((res) => {
+        console.log(res);
+        this.demand = res.data;
+      });
+    },
+    submitWork() {
+      //生成需求决策编号
+      if (this.clicknextName === "起草人发送") {
+        this.getDemand();
+      }
+      if (!this.list.taskId) {
+        this.$message.error("请先保存表单后处理");
+        return false;
+      }
+      if (this.TransferStatus === true) {
+        if (this.backThree.length > 0) {
+          this.nextWork();
+        } else {
+          this.$message.error("请选择候选人");
+          return false;
+        }
+      } else {
+        let list = {
+          userId: JSON.parse(window.sessionStorage.userInfo).loginNo, //人员id
+          taskId: this.list.taskId, //表单标识
+          taskName: this.clicknextName, //流程节点
+          userCode: JSON.parse(window.sessionStorage.userInfo).loginNo, //人员code
+          content: this.textarea, //意见内容
+          // resolution: this.nodes.currentShape[0].condition.resolution, //流程图线节点
+          // nextDealMan: this.backThree[0].loginNoStr || '', //下一步处理人
+        };
+        if (this.treeCopyList.length) {
+          //抄送
+          list.copyman = this.treeCopyList[0].loginNoStrCopy;
+        }
+        if (this.nodes.currentShape) {
+          list.resolution = this.nodes.currentShape[0].condition.resolution;
+          list.approve = this.nodes.currentShape[0].condition.approve;
+        }
+        // if (this.clicknextName === "") {
+        //   this.$message.error("请选择流程节点");
+        //   return false;
+        // }
+
+        if (this.initialList.nextShapes[0].multi.multi === "true") {
+          if (this.backThree.length > 0) {
+            // list.nextDealManList = this.backThree[0].loginNoStr;
+            list.nextDealManList = "qiuyu,fanyan";
+          }
+        } else {
+          if (this.backThree.length > 0) {
+            list.nextDealMan = this.backThree[0].loginNoStr;
+          } else {
+            if (this.clicknextName === "流程结束") {
+            } else {
+              this.$message.error("请选择候选人");
+              return false;
+            }
+          }
+        }
+
+        // if (this.backThree.length > 0) {
+        //   list.nextDealMan = this.backThree[0].loginNoStr;
+        // } else {
+        //   if (this.clicknextName === "流程结束") {
+        //   } else {
+        //     this.$message.error("请选择候选人");
+        //     return false;
+        //   }
+        // }
+        this.nextWork(list);
+      }
+    },
+    async nextWork(list) {
+      //e:yes||no,list:传入数组,title:结束标签,res:驳回标签,id:工单更新id
+      let _this = this;
+      let obj = {
+        url: _this.$url.formList.nextWork, //下一步工作流接口
+        data: list,
+        status: "form",
+      };
+      if (_this.TransferStatus === true) {
+        let lists = {
+          userId: _this.backThree[0].loginNoStr,
+          taskId: _this.list.taskId,
+          content: _this.textarea,
+        };
+        obj.url = _this.$url.formList.transferTask + _this.list.taskId;
+        obj.data = lists;
+      }
+      await this.common.httpPost(obj, success);
+      function success(data) {
+        if (data != null) {
+          if (_this.TransferStatus === true) {
+            let list = {
+              taskId: data.taskid,
+              id: _this.list.id,
+            };
+
+            _this.setUpdate(list);
+          } else {
+            let list = {
+              taskId: data.taskid,
+              id: _this.list.id,
+              resourceId: _this.nodes.currentShape[0].resourceId,
+              taskName: _this.nodes.nextShapes[0].properties.name,
+            };
+            if (data.copytaskid) {
+              list.copytaskid = data.copytaskid;
+              list.copyman = _this.treeCopyList[0].loginNoStrCopy;
+            }
+            if (_this.demand) {
+              list.needNo = _this.demand;
+            }
+            _this.setUpdate(list);
+          }
+        } else {
+          let list = {
+            taskName: "结束",
+            id: _this.list.id,
+          };
+          _this.setUpdate(list);
+        }
+      }
+    },
+    // qqq() {
+    //   this.$emit("beforeClose", true);
+    // },
+    //更新工作流接口
+    setUpdate(e) {
+      this.$http({
+        url: "/market/waf/update",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.$emit("beforeClose", true);
+        // this.fromList.taskId = res.data.body.taskId;
+        // this.fromList.taskName = res.data.body.taskName;
+        // if (res.data.body.taskName === "起草") {
+        //   this.isSync = res.data.body.isSync;
+        // } else {
+        //   this.isSync = "1";
+        // }
+        // if (res.data.result === 0) {
+        //   this.$message.success("工作流更新成功");
+        // }
+      });
+    },
+    //查询路径接口
+    getNextPath(e, status) {
+      let list = {
+        // fresourceId: "bf79721c-33f3-11ed-ba0b-00505687dcd3", //测试环境
+        fresourceId: this.requestForm.fresourceId, // 本地环境
+        processId: this.requestForm.processDefinitionKey,
+        // fresourceId: "0d94de8a-0281-11ed-a302-4ae7da54db39", // 本地环境
+        // processId: "request_form_process",
+        // resourceId: e,
+      };
+      if (e) {
+        // this.propsList = [];
+        list.resourceId = e;
+      }
+      this.$http({
+        url: "/market/waf/queryPath",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: list,
+      }).then((res) => {
+        // if (status === 1) {
+        //   //第一次进入取路径
+        //   this.initialList = res.data.body;
+        //   if (
+        //     this.initialList.nextShapes[0].multi?.multi &&
+        //     res.data.body.nextShapes[0].multi.multi === "true"
+        //   ) {
+        //     this.transferStatus = true;
+        //   } else {
+        //     this.transferStatus = false;
+        //   }
+        //   if (
+        //     res.data.body.nextShapes[0].copy?.copy &&
+        //     res.data.body.nextShapes[0].copy.copy === "true"
+        //   ) {
+        //     this.CopyStatus = true;
+        //   } else {
+        //     this.CopyStatus = false;
+        //   }
+        //   // if (res.data.body.nextShapes[0].loop !== null) {
+        //   //   if (res.data.body.nextShapes[0].loop.loop === "true") {
+        //   //     this.transferStatus = true; //转派按钮生效
+        //   //   } else {
+        //   //     this.transferStatus = false;
+        //   //   }
+        //   // } else {
+        //   //   this.transferStatus = false;
+        //   // }
+        //   // if (res.data.body.nextShapes[0].copy !== null) {
+        //   //   if (res.data.body.nextShapes[0].copy.copy === "true") {
+        //   //     // this.copyStatus = true; //抄送按钮生效
+        //   //     this.CopyStatus = true;
+        //   //   } else {
+        //   //     this.copyStatus = false;
+        //   //   }
+        //   // } else {
+        //   //   this.copyStatus = false;
+        //   // }
+        //   res.data.body.currentShape.map((item, index) => {
+        //     this.getNextPath(item.resourceId, 2);
+        //   });
+        // }
+        if (status === 2) {
+          if (res.data.body.nextShapes[0].condition !== null) {
+            this.node = res.data.body;
+          } else {
+            this.getNextPath(res.data.body.nextShapes[0].resourceId, 2);
+          }
+        }
+        if (status === 3) {
+          this.nodes = res.data.body;
+          this.getTreeLists(res.data.body, 1);
+        }
+      });
+    },
+    //查询候选人接口
+    getTreeLists(e, status) {
+      let id = "";
+      if (status === 2) {
+        id = "copy." + e;
+      } else {
+        id =
+          e.nextShapes[0].properties.documentation == "createId" ||
+          e.nextShapes[0].properties.documentation == "createId-copy"
+            ? this.list.createId
+            : e.nextShapes[0].properties.documentation;
+      }
+
+      this.$http({
+        url: "/market/api/user/info/queryNodePers?params=" + id,
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: "",
+      }).then((res) => {
+        console.log(status);
+        if (status === 2) {
+          this.treeCopyList = res.data; //抄送
+          console.log(this.treeCopyList);
+          //  this.$refs.defTrees.treeList = res.data;
+        } else {
+          this.treeList = res.data; //抄送
+          // this.$refs.defTree.treeList = res.data;
+          console.log(this.treeList);
+        }
+      });
+    },
+    //转派按钮方法
+    clickTransfer(e) {
+      if (e == 1) {
+        // this.TransferStatus = true;
+      } else if (e == 2) {
+        this.CopyStatus = true;
+      }
+      this.getTreeLists(this.initialList, e);
+    },
+    //点击节点获取下一步的处理人字段
+    clickGetTree(e, index) {
+      // this.CopyStatus = false;
+      this.TransferStatus = false;
+      //   this.clickTaskName = e.properties.name;
+      this.clicknextName = e.properties.name;
+      this.seleIndex = index;
+      this.getNextPath(e.resourceId, 3); //1 为点击后获取线
+    },
+    //点击常用意见方法
+    clickCommonly(e) {
+      this.textarea = e.currentTarget.innerHTML;
+    },
+    //点击修改
+    clickEdit() {
+      console.log(123);
+      this.editStatus = true;
+    },
+    //选择树的回调
+    changeTree(e) {
+      console.log(e);
+      this.backThree = e;
+    },
+    //获取字典表常用意见
+    getMetirialType(e) {
+      this.$http({
+        url: "/market/cfgDataDict/queryList",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "approval",
+        },
+      }).then((res) => {
+        console.log(res);
+        this.commonlyList = res.data;
+      });
+    },
+    //添加字典表常用意见
+    geaddctType(e) {
+      this.$http({
+        url: "/market/cfgDataDict/add",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.getMetirialType();
+      });
+    },
+    //删除字典表常用意见
+    geDelectType(e) {
+      this.$http({
+        url: "/market/cfgDataDicts/del",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+      }).then((res) => {
+        this.getMetirialType();
+      });
+    },
+    //常用意见添加
+    addStatus() {
+      let newData = Date.parse(new Date());
+      this.$prompt("请输入常用意见", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+      })
+        .then(({ value }) => {
+          let list = {
+            dictCode: "approval",
+            dataCode: newData,
+            dataName: value,
+            dictName: "审批意见",
+          };
+          this.geaddctType(list);
+          this.$message({
+            type: "success",
+            message: "常用意见添加成功",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "取消输入",
+          });
+        });
+    },
+    //常用意见删除
+    deleStatus(e) {
+      this.$confirm("此操作将删除此常用意见, 是否继续?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let list = {
+            dataCode: e.dataCode,
+            dictCode: "approval",
+          };
+          this.geDelectType(list);
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    //关闭修改
+    editCloses() {
+      this.editStatus = false;
+    },
+  },
+};
+</script>
+
+<style lang='scss' scoped>
+.flex-header-text-tree {
+  width: 50%;
+  text-align: center;
+}
+.flex-icon {
+  float: right;
+  margin-right: 20px;
+  color: #4277a1;
+}
+.flex-handle {
+  width: 100%;
+  padding: 30px;
+  display: flex;
+  .flex-right {
+    width: 50%;
+    border: 1px solid #e1e1e1;
+    margin-left: 20px;
+  }
+}
+.flex-left {
+  width: 50%;
+  display: flex;
+  flex-direction: column;
+  .flex-left-header {
+    display: flex;
+    justify-content: space-around;
+    .flex-path {
+      height: 280px;
+      border: 1px solid #e1e1e1;
+      width: 68%;
+    }
+  }
+}
+.flex-common {
+  padding: 10px 5%;
+  font-size: 18px;
+}
+.flex-left-header-text {
+  height: 40px;
+  line-height: 40px;
+  color: black;
+  padding-left: 10px;
+  background-color: #cde4f6;
+  font-size: 18px;
+  font-weight: bold;
+}
+.flex-path-list {
+  overflow-y: scroll;
+  overflow-x: hidden;
+  height: 14rem;
+}
+.flex-slide {
+  overflow-y: scroll;
+  overflow-x: hidden;
+}
+.active {
+  background-color: #f3faff;
+}
+.flex-opinion {
+  height: 280px;
+  border: 1px solid #e1e1e1;
+  width: 100%;
+  margin-top: 20px;
+}
+.flex-right-text {
+  margin-right: 20px;
+  width: 50%;
+}
+.flex-commons {
+  height: 280px;
+  border: 1px solid #e1e1e1;
+  width: 30%;
+}
+.flex-footer-botton {
+  display: flex;
+  justify-content: space-evenly;
+}
+.flex-button {
+  margin-top: 10px;
+  margin-bottom: 10px;
+  ::v-deep .el-button--primary {
+    width: 222px;
+  }
+}
+</style>

+ 292 - 0
src/components/workflowUpload.vue

@@ -0,0 +1,292 @@
+<template>
+  <div v-loading="loading">
+    <el-upload
+      class="upload-demo"
+      :drag="fileInfo.type !== 'btn'"
+      multiple
+      :limit="fileInfo.limit"
+      ref="upload"
+      action="string"
+      :on-remove="handleRemove"
+      :before-remove="beforeRemove"
+      :on-exceed="handleExceed"
+      :on-preview="clickDownload"
+      :file-list="attList"
+      :auto-upload="true"
+      :show-file-list="fileInfo.type !== 'btn'"
+      :before-upload="deforeUp"
+      :http-request="signUpload"
+    >
+      <div v-if="fileInfo.type !== 'btn'">
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">点击上传</div>
+      </div>
+      <div v-if="fileInfo.type === 'btn'">
+        <el-button
+          :size="fileInfo.size ? fileInfo.size : 'medium'"
+          :type="fileInfo.btntype"
+          >{{ fileInfo.typename }}</el-button
+        >
+      </div>
+    </el-upload>
+  </div>
+</template>
+<script>
+export default {
+  props: ["fileInfo", "fileList", "type"],
+  data() {
+    return {
+      fileLists: [],
+      attList: [],
+      loading: false,
+      num: 0,
+      s: false,
+    };
+  },
+  methods: {
+    clickDownload() {
+      this.$emit("clickDownload", true);
+    },
+    signUpload() {},
+    //删除
+    handleRemove(file) {
+      console.log(file);
+      console.log(this.attList);
+      for (let i = 0; i < this.attList.length; i++) {
+        if (this.attList[i].name === file.name) {
+          this.attList.splice(i, 1);
+          console.log(55555);
+          this.$emit("delloadBack", this.attList);
+        }
+      }
+    },
+    beforeRemove(file) {
+      console.log(file);
+    },
+    //数量限制
+    handleExceed(files, fileList) {
+      this.$message.warning(
+        `当前限制选择 ${this.fileInfo.limit} 个文件,本次选择了 ${
+          files.length
+        } 个文件,共选择了 ${files.length + fileList.length} 个文件`
+      );
+    },
+    deforeUp(file) {
+      const isLt2M = file.size / 1024 / 1024 < 100;
+      if (!isLt2M) {
+        this.$message.error("上传文件大小不能超过 20MB!");
+        return false;
+      }
+      if (this.fileInfo.type == "img") {
+        const isImg = file.type.split("/")[0] == "image";
+        if (!isImg) {
+          this.$message.error("请上传图片格式文件!");
+          return false;
+        }
+      }
+      if (this.fileInfo.typexz == "ppt") {
+        const isImg = file.name.split(".")[1] == "pptx";
+        console.log(file.name.split(".")[1] == "pptx");
+        if (!isImg) {
+          this.$message.error("请上传ppt格式文件!");
+          return false;
+        }
+      }
+      if (this.fileInfo.typexz == "csv") {
+        const isImg = file.name.split(".")[1] == "csv";
+        if (!isImg) {
+          this.$message.error("请上传csv格式文件!");
+          return false;
+        }
+      }
+      if (this.fileInfo.typexz == "xlsx") {
+        const isImg = file.name.split(".")[1] == "xlsx";
+        if (!isImg) {
+          this.$message.error("请上传xlsx格式文件!");
+          return false;
+        }
+      }
+      this.loading = true;
+      let query = new FormData();
+      query.append("file", file);
+      if (this.fileInfo.typename == "新增素材") {
+        query.append("advType", this.fileInfo.advType);
+        query.append("advTypeName", this.fileInfo.advTypeName);
+      }
+      if (
+        this.fileInfo.url == "/market/cIllegalCallTask/importTempByProv" ||
+        this.fileInfo.url ==
+          "/market/cChannelInfo/cIllegalCallTask/importTempByProv"
+      ) {
+        query.append("taskId", this.fileInfo.taskId);
+        query.append("tempId", this.fileInfo.tempId);
+      }
+      //违规外呼
+      if (this.fileInfo.uploadType == "outCall") {
+        query.append("uploadType", "outCall");
+        query.append("relId", this.fileInfo.relId);
+      }
+      if (this.fileInfo.uploadType == "train") {
+        query.append("uploadType", "train");
+        query.append("relId", this.fileInfo.relId);
+      }
+      //运营类项目考核及结算
+      if (this.fileInfo.url == "/market/cmkAttachInfo/upload") {
+        query.append("uploadType", this.fileInfo.uploadType);
+      }
+      if (this.fileInfo.url == "/market/cStoreOutWo/importData") {
+        query.append("woNo", this.fileInfo.woNo);
+      }
+      if (this.fileInfo.url == "/market/cStoreScheTrainEva/importDataEva") {
+        query.append("evaId", this.fileInfo.evaId);
+      }
+      this.num++;
+      let _this = this;
+      this.$http({
+        url: this.fileInfo.url,
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: query,
+      })
+        .then((res) => {
+          if (this.fileInfo.type === "btn") {
+            this.$refs["upload"].clearFiles();
+            this.$emit("uploadBack", res);
+            if (res.data.result == 0) {
+              this.$emit("onSuccess", file);
+              _this.$message({
+                message: res.data.desc,
+                type: "success",
+              });
+            } else if (res.data.result == 1) {
+              _this.$message({
+                message: res.data.desc,
+                type: "error",
+              });
+            } else if (res.data.result == 2) {
+              _this.$message({
+                message: res.data.desc,
+                type: "warning",
+              });
+            } else if (res.data.result == 3) {
+              _this.$message({
+                message: res.data.desc,
+                type: "info",
+              });
+            } else {
+              _this.$message({
+                message: res.data.desc,
+                type: "success",
+              });
+            }
+            this.num--;
+            if (this.num == 0) {
+              this.loading = false;
+            }
+            return;
+          }
+          if (this.fileInfo.type === "voice") {
+            this.attList = res.data;
+          } else {
+            this.attList.push({
+              id: res.data.body.id,
+              name: res.data.body.fileName,
+              fileCode: res.data.body.fileCode,
+              opName: res.data.body.opName,
+              opNo: res.data.body.opNo,
+              opTime: res.data.body.opTime,
+              attchFileId: res.data.body.attchFileId,
+              type: res.data.body.type,
+            });
+          }
+          this.$emit("uploadBack", this.attList);
+          this.num--;
+          if (this.num == 0) {
+            this.loading = false;
+          }
+          return true;
+        })
+        .catch((res) => {
+          this.$message({
+            message: file.name + "上传失败",
+            type: "error",
+          });
+          this.num--;
+          if (this.num == 0) {
+            this.loading = false;
+          }
+          for (let i = 0; i < this.$refs["upload"].uploadFiles.length; i++) {
+            if (file.name == this.$refs["upload"].uploadFiles[i].name) {
+              this.$refs["upload"].uploadFiles.splice(i, 1);
+            }
+          }
+          return false;
+        });
+    },
+  },
+  mounted() {
+   console.log(this.$refs["upload"].name);
+    this.$refs["upload"].uploadFiles = [];
+    console.log(this.$refs["upload"]);
+    console.log(this.attList);
+    
+    // this.$refs.upload.clearFiles();
+  },
+  created() {
+    this.attList = [];
+    if (this.fileInfo.fileList != undefined) {
+      console.log(this.fileInfo.fileList);
+      for (let i = 0; i < this.fileInfo.fileList.length; i++) {
+        this.attList.push({
+          id: this.fileInfo.fileList[i].id,
+          name: this.fileInfo.fileList[i].fileName,
+          fileCode: this.fileInfo.fileList[i].fileCode,
+          opName: this.fileInfo.fileList[i].opName,
+          opNo: this.fileInfo.fileList[i].opNo,
+          opTime: this.fileInfo.fileList[i].opTime,
+          attchFileId: this.fileInfo.fileList[i].attchFileId,
+          type: this.fileInfo.fileList[i].type,
+        });
+      }
+    }
+
+    // let list = {
+    //   attchFileId: "",
+    //   fileCode: "202209271105276441",
+    //   name: "1231233333333333.xlsx",
+    //   id: "202209271105276441",
+    //   opName: "范岩",
+    //   opNo: "fanyan",
+    //   opTime: "2022-09-27 11:05:27",
+    //   type: undefined,
+    // };
+
+    // this.fileList.push(list)
+  },
+  watch: {
+    fileList: {
+      handler(newVal, oldVal) {
+        this.attList = [];
+        if (this.fileList != undefined) {
+          for (let i = 0; i < this.fileList.length; i++) {
+            this.attList.push({
+              id: this.fileList[i].id,
+              name: this.fileList[i].name,
+              fileCode: this.fileList[i].fileCode,
+              opName: this.fileList[i].opName,
+              opNo: this.fileList[i].opNo,
+              opTime: this.fileList[i].opTime,
+              attchFileId: this.fileList[i].attchFileId,
+              type: this.fileList[i].type,
+            });
+          }
+        }
+      },
+    },
+  },
+};
+</script>
+<style scoped lang="scss">
+</style>

+ 4 - 0
src/config/index.js

@@ -0,0 +1,4 @@
+'use strict'
+// 根据环境引入不同配置 process.env.ENV_CONFIG  ex:dev.conf.js
+const config = require('../../config/dev.env')
+module.exports = config

+ 53 - 0
src/http/api.js

@@ -0,0 +1,53 @@
+import axios from "./index.js"
+//page:分页页码  seach:搜索条件   idNo:工作流图流程key
+//通用方法待办
+export function getTodoBase(page, seach, idNo) {
+    return axios({
+        url: "/market/waf/queryTodoBase",
+        method: "post",
+        method: "post",
+        headers: {
+            "Content-Type": "application/json",
+            page: '{"pageNo":"' + page + '","pageSize":"10"}',
+        },
+        data: idNo,
+    })
+}
+//通用方法待办
+export function getDoneBase(page, seach, idNo) {
+    return axios({
+        url: "/market/waf/queryDoneBase",
+        method: "post",
+        method: "post",
+        headers: {
+            "Content-Type": "application/json",
+            page: '{"pageNo":"' + page + '","pageSize":"10"}',
+        },
+        data: idNo,
+    })
+}
+//通用方法待办
+export function getInitiateBase(page, seach, idNo) {
+    return axios({
+        url: "/market/waf/queryInitiateBase",
+        method: "post",
+        method: "post",
+        headers: {
+            "Content-Type": "application/json",
+            page: '{"pageNo":"' + page + '","pageSize":"10"}',
+        },
+        data: idNo,
+    })
+}
+//通用更新方法
+export function updateBase(e) {
+    return axios({
+        url: "/market/waf/updateBase",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: e,
+    })
+}
+export default { getTodoBase, getDoneBase, getInitiateBase,updateBase };

+ 9 - 1
src/main.js

@@ -11,12 +11,20 @@ import './assets/mc-inconfont/iconfont.css'
 import fullscreen from 'vue-fullscreen'
 import VueContextMenu from 'vue-contextmenu'
 
+import Urls from './assets/js/url.js' //路径共用
+import util from './assets/js/util.js'
+import common from './assets/js/common.js' //公共注册
+import http from './assets/js/http.js'
+
 import FormMaking from 'form-making'
 import 'form-making/dist/FormMaking.css'
 import VueEditor from "vue2-editor"
 Vue.use(VueEditor)
 Vue.use(FormMaking)
-
+Vue.prototype.$url = Urls
+Vue.prototype.$util = util
+Vue.prototype.common = common
+Vue.prototype.$axios = http //axios 设置
 Vue.use(fullscreen)
 Vue.use(VueCookie);
 Vue.use(VueContextMenu)

+ 92 - 0
src/pages/main/comWin/aproveStep.vue

@@ -0,0 +1,92 @@
+<template>
+    <div>
+        <el-dialog title="审核详情" v-if="visible" :visible.sync="visible" >
+            <el-row style="text-align: right; margin-bottom: 10px" v-if="showButton">
+                <el-button type="primary" @click="showProcessDiagram({procinstid: procinstid, taskid: taskid, programmecode: '审核详情'})" size="mini">流程轨迹</el-button>
+            </el-row>
+            <el-table
+                :data="tableData3"  :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+                border
+                stripe
+                highlight-current-row="true"
+                style="width: 100%"
+            >
+                <el-table-column align="center"  prop="procinstid" label="实例ID" ></el-table-column>
+                <el-table-column align="center"  prop="taskName" label="处理节点" ></el-table-column>
+                <el-table-column align="center"  prop="userName" label="处理人" ></el-table-column>
+                <el-table-column align="center"  prop="approveDetail" label="处理结果" >
+                    <template slot-scope="scope">
+                        <el-tag type="success" v-if="scope.row.approve=='yes'">{{scope.row.approveDetail}}</el-tag>
+                        <el-tag type="danger" v-if="scope.row.approve=='no'">{{scope.row.approveDetail}}</el-tag>
+                    </template>
+                </el-table-column>
+                <el-table-column align="center"  prop="content" label="处理意见" ></el-table-column>
+                <el-table-column align="center"  prop="time" label="处理时间" ></el-table-column>
+
+
+
+            </el-table>
+
+        </el-dialog>
+        <process-diagram-dialog ref="processDiagramDialog"></process-diagram-dialog>
+    </div>
+
+</template>
+
+<script>
+
+// import moment from 'moment';
+// //import util from '@/util'
+import ProcessDiagramDialog from '../../../components/ProcessDiagramDialog'
+export default {
+  data() {
+    return {
+      items:[],
+      visible:false,
+      tableData3: [],
+      selectedRows: [],
+      procinstid: '',
+      taskid: '',
+      showButton: false,
+    };
+  },
+  components: {
+      ProcessDiagramDialog
+  },
+  created() {},
+  methods: {
+     init(idList, status, procinstid, taskid){
+         this.procinstid = procinstid;
+         this.taskid = taskid;
+         this.visible = true;
+         this.showButton = false;
+         this.doSearch(idList, status);
+     },
+    doSearch(idList,status) {
+        let self = this;
+        if(!idList||status==0){
+          this.tableData3 = [];
+          return false;
+        }
+        var obj ={
+          url:this.$url.activeti.getCommentsByProcinstid,
+          data:{
+            data: idList
+          }
+        };
+        this.common.httpPost(obj,success);
+        function success(data){
+            self.tableData3 = data;
+            if (self.tableData3.length > 0) {
+                if (self.tableData3[0].approve !== 'yes' && self.tableData3[0].approve !== 'no'){
+                    self.showButton = true;
+                }
+            }
+        }
+    },
+      showProcessDiagram(row) {
+          this.$refs.processDiagramDialog.showProcessDiagram(row)
+      }
+  }
+};
+</script>

+ 368 - 0
src/pages/main/comWin/aproveWin.vue

@@ -0,0 +1,368 @@
+<template>
+  <el-dialog title="审核业务" :close-on-click-modal="true" v-if="visible" :visible.sync="visible" :before-close="handleDialogClose">
+    <el-form :model="model" ref="form1" label-width="120px">
+      <el-row :gutter="26">
+        <el-col :span="16" v-if="isLast">
+          <el-form-item label="审核角色" prop="data1" class="is-required">
+            <el-select filterable v-model="model.data1" :multiple="ismultiple" @remove-tag="removeTag" placeholder="请选择..." @change="role">
+              <el-option v-for="item in options1" :key="item.id" :label="item.name" :value="item.id"></el-option>
+            </el-select>
+          </el-form-item>
+        </el-col>
+        <el-col :span="16" v-if="isLast">
+          <el-form-item label="审核人" verify prop="nextDealMan" class="is-required">
+            <el-select filterable v-model="model.nextDealMan" :multiple="ismultiple" placeholder="请选择...">
+              <el-option v-for="item in options2" :key="item.id" :label="item.name" :value="item.id"></el-option>
+            </el-select>
+          </el-form-item>
+        </el-col>
+
+        <el-col :span="16" v-if="type==2">
+          <el-form-item label="审核意见" prop="content" verify :maxLength="100" class="is-required">
+            <el-input type="textarea" v-model="model.content"></el-input>
+          </el-form-item>
+        </el-col>
+        <el-col :span="16" v-if="type==2">
+          <el-form-item label="常用意见" prop="nextDealMan1">
+            <el-select filterable v-model="model.nextDealMan1" @change="changeContent" placeholder="请选择...">
+              <el-option v-for="item in options3" :key="item.adviceId" :label="item.adviceInfo" :value="item.adviceId"></el-option>
+            </el-select>
+          </el-form-item>
+        </el-col>
+        <el-col :span="16" v-if="isLast || type === 2">
+          <el-form-item>
+            <el-checkbox v-model="checked" @change="changeIsQRCodeTrack">同时短信通知</el-checkbox>
+          </el-form-item>
+        </el-col>
+          <el-col :span="16" v-if="!isLast && checked">
+              <el-form-item label="短信接收人名单">
+                  <div class="textarea" :disabled="false">
+                      <el-tag :key="tag.id" style="margin-left:6px;" v-for="tag in messageReceiveList">
+                          {{tag.name}}
+                      </el-tag>
+                  </div>
+              </el-form-item>
+          </el-col>
+      </el-row>
+
+    </el-form>
+
+    <span slot="footer" class="dialog-footer">
+      <el-button type="primary" v-if="type==2" @click="addSer()">添加到常用意见</el-button>
+      <el-button v-if="type==1||type==3" @click="visible = false">关闭</el-button>
+
+      <el-button v-if="type==2" @click="dataFormSubmit('no')">不同意</el-button>
+      <el-button type="primary" @click="dataFormSubmit('yes')">{{btn}}</el-button>
+
+    </span>
+  </el-dialog>
+</template>
+
+
+<script>
+export default {
+  data() {
+    return {
+      checked: false,
+      messageReceiveList: [],
+      formAction: 0, //0 add,//1,edit
+      visible: false,
+      title: '添加',
+      disabled: false,
+      btn: '提交',
+      ismultiple: false,
+      type: 1,
+      aproveVisible: false,
+      isLast: true,
+      taskId: '',
+      model: {
+        content: '',
+        nextDealMan: -1,
+        isAccount: 1,
+        isQRCodeTrack:'',
+      },
+
+      options1: [],
+      options2: [],
+      options3: [],
+      value5: [],
+    }
+  },
+  mounted() {
+    // this.model.data2 = this.$store.getters.getLogin("username");
+    // this.model.data4 = this.$store.getters.getLogin("userId")
+  },
+  activated() {},
+  methods: {
+    init(type, procdefkey, procinstid, resolution, taskId) {
+      //type1  申请  2 中间环节  3.驳回
+      console.log(arguments)
+      this.type = type
+      console.log(99, this.type)
+      this.model = {
+        content: '',
+        nextDealMan: -1,
+        isAccount: 1,
+      }
+      this.taskId = taskId
+      this.options1 = []
+      this.options2 = []
+      this.options3 = []
+      this.value5 = []
+      if (type == 1 || resolution != undefined || type == 3) {
+        this.btn = '提交'
+      } else {
+        this.btn = '同意'
+      }
+      this.procdefkey = procdefkey
+
+      this.procinstid = procinstid
+      this.resolution = resolution
+      this.visible = true
+      if (this.$refs.form1) {
+        this.$refs.form1.resetFields()
+      }
+      this.doSelect()
+      this.doserSelect()
+      if (procinstid !== null && procinstid !== undefined) {
+        this.doSelectMessageReceiveList()
+      }
+    },
+
+    dataFormSubmit(type) {
+      console.log(120, type)
+      if ((this.isLast && !this.model.data1) || (this.model.data1 && this.model.nextDealMan==-1)) return this.$message.error('审核角色或审核人不能为空!')
+      let self = this
+      // console.log(122,this.ismultiple)
+      var model = JSON.parse(JSON.stringify(this.model))
+      if (this.ismultiple) {
+        model.nextDealManList = model.nextDealMan.join(',')
+        model.nextDealMan = -1
+      }
+      console.log(128, model)
+      if (type == 'no') {
+        if (!model.content) {
+          this.$message('请填写驳回原因')
+          return false
+        }
+        model.approve = type
+        self.$parent.dataFormSubmit(model)
+        self.visible = false
+      } else {
+        self.$refs['form1'].validate((valid) => {
+          if (valid) {
+            model.approve = type
+            if(!self.isLast) {
+              model.nextDealMan = -1
+            }
+            self.$parent.dataFormSubmit(model)
+
+            self.visible = false
+          } else {
+            return false
+          }
+        })
+      }
+    },
+    handleDialogClose() {
+      // console.log(self.$parent)
+
+      this.$parent.visible = false
+      this.visible = false
+    },
+    doserSelect() {
+      let self = this
+      this.common.selectInit(this.$url.findAdvice.getList, success, { pageNum: 1, pageSize: 20 }, 'options3')
+      function success(data, str) {
+        self[str] = data.rows
+      }
+    },
+    doSelect() {
+      let self = this
+      let obj = {}
+
+      if (this.type == 1) {
+        obj = { procdefkey: this.procdefkey }
+      } else {
+        obj = { procinstid: this.procinstid, approve: 'yes' }
+        if (this.resolution || this.resolution == 0) {
+          obj.resolution = this.resolution
+        }
+        if (this.taskId) {
+          obj.taskId = this.taskId
+        }
+      }
+      console.log(186, obj)
+      this.common.selectInit(this.$url.activeti.getRole, success, obj, 'options1', error)
+      function error(data) {
+        // self.$parent.aproveVisible = false
+        // self.$message.error('错误,请重新审批!')
+      }
+
+      function success(data, str) {
+        //  multiple
+        console.log(190, data)
+        if (data) {
+          if (data.tasktype != 4) {
+            self.isLast = false
+          } else {
+            // data.activitybehavior = 'SequentialMultiInstanceBehavior'
+
+            if (data.activitybehavior == 'SequentialMultiInstanceBehavior' || data.activitybehavior == 'ParallelMultiInstanceBehavior') {
+              self.ismultiple = true
+              // console.log(199);
+              // console.log(200,data.rows[0].id)
+              self.model.data1 = [data.rows[0].id]
+
+              self.role([data.rows[0].id])
+            } else {
+              // console.log(200,data.rows[0].id)
+              // 如果返回审核角色和审核人 没有  加这层判断 解决前端报id为undefined的问题
+              if (data.rows.length != 0) {
+                self.ismultiple = false
+                self.model.data1 = data.rows[0].id
+
+                self.role(data.rows[0].id)
+              }
+              // self.ismultiple = false;
+              // self.model.data1 = data.rows[0].id;
+
+              // self.role(data.rows[0].id)
+            }
+            self[str] = data.rows
+            self.isLast = true
+          }
+        } else {
+          self.isLast = false
+          self.ismultiple = false
+        }
+      }
+    },
+    role(row) {
+      var str = ''
+
+      if (typeof row == 'object') {
+        if (row.length == 0) {
+          return false
+        }
+        str = row.join(',')
+      } else {
+        if (!row) {
+          return false
+        }
+        str = String(row)
+      }
+      let self = this
+      let obj = {
+        roleId: str,
+        excludeMeWhenSelectNextHandler: self.common.excludeMeWhenSelectNextHandler,
+        excludeFormerHanlder: self.common.excludeMeWhenSelectNextHandler,
+        procinstid: self.procinstid,
+      }
+      this.common.selectInit(this.$url.activeti.getUsersByRoleIds, success, obj, 'options2')
+
+      function success(data, str) {
+        if (data.length != 0) {
+          if (self.ismultiple) {
+            self.nextDeal(data[0].id)
+          } else {
+            self.model.nextDealMan = data[0].id
+          }
+          self[str] = data
+        } else {
+          self.model.nextDealMan = []
+          self.$message('该角色下审核人为空')
+        }
+
+        // if( self.ismultiple){
+        //   self.nextDeal(data[0].id);
+        // }else{
+
+        //   self.model.nextDealMan  = data[0].id;
+        // }
+        // self[str] = data;
+      }
+    },
+    removeTag() {
+      this.model.nextDealMan = -1
+    },
+    nextDeal(id) {
+      if (typeof this.model.nextDealMan != 'object') {
+        this.model.nextDealMan = []
+      }
+      var tag = this.model.nextDealMan.find((i) => {
+        return i == id
+      })
+      if (!tag) {
+        this.model.nextDealMan.push(id)
+      }
+    },
+    addSer() {
+      let self = this
+      if (!this.model.content) {
+        this.$message('审核意见为空')
+        return false
+      }
+      let urls = null
+
+      urls = this.$url.findAdvice.add
+
+      var obj = {
+        url: urls,
+        data: {
+          adviceInfo: this.model.content,
+        },
+      }
+      this.common.httpPost(obj, success)
+      function success(data) {
+        self.$message.success('已添加')
+        self.doserSelect()
+      }
+    },
+    changeContent(value) {
+      let obj = this.options3.find((element) => {
+        return element.adviceId == value
+      })
+      this.model.content = obj.adviceInfo
+    },
+    changeIsQRCodeTrack(checked) {
+          if(checked){
+              this.model.isQRCodeTrack = 1;
+          } else {
+              this.model.isQRCodeTrack = 0;
+          }
+     },
+      doSelectMessageReceiveList(){
+          let self = this;
+          var obj = {
+              url: self.$url.activeti.getMessageReceiveList,
+              data: {
+                  procinstid: self.procinstid,
+              },
+          }
+          self.common.httpPost(obj, success)
+          function success(data) {
+              console.log("获取短信接收人",data);
+              self.messageReceiveList = data.list;
+          }
+      },
+  },
+}
+</script>
+<style>
+.el-textarea__inner {
+  height: 100px;
+}
+.textarea {
+    padding: 4px;
+    min-height: 100px;
+    width: 100%;
+    color: #606266;
+    background-color: #fff;
+    background-image: none;
+    border: 1px solid #dcdfe6;
+    border-radius: 4px;
+    transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
+    box-sizing: border-box;
+}
+</style>

+ 192 - 0
src/pages/main/comWin/prosess.vue

@@ -0,0 +1,192 @@
+<template>
+  <el-dialog :title="title" v-if="visible" :visible.sync="visible">
+    <el-card>
+      <div class="table-title">{{tableData.no}}</div>
+      <el-row :span="18" :offset="3">
+        <el-table
+          :data="items2"
+          :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+          border
+          stripe
+          highlight-current-row="true"
+          style="width: 100%"
+        >
+          <el-table-column align="center" prop="createAt" label="询价时间"></el-table-column>
+          <el-table-column align="center" prop="quoteEndAt" label="截止时间"></el-table-column>
+          <el-table-column align="center" prop="address" label="发送方式">
+            <template slot-scope="scope">
+              <el-tag v-if="scope.row.byEmail==1" >邮件</el-tag>
+              <el-tag v-if="scope.row.bySms==1">短信</el-tag>
+            </template>
+          </el-table-column>
+        </el-table>
+      </el-row>
+    </el-card>
+    <el-card>
+      <div style>报价/询价人数:{{count}}人</div>
+      <el-table
+        :data="items"
+        :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+        border
+        stripe
+        highlight-current-row="true"
+        style="width: 100%"
+      >
+        <el-table-column align="center" prop="counterpartyName" label="报价银行"></el-table-column>
+        <el-table-column align="center" prop="realName" label="报价联络人"></el-table-column>
+        <el-table-column align="center" prop="address" label="是否已报价">
+          <template  slot-scope="scope">
+            <el-tag v-if="scope.row.status==1" type="success">已报价</el-tag>
+            <el-tag v-if="scope.row.status==2">暂不参与</el-tag>
+            <el-tag v-if="scope.row.status==0" type="danger">未报价</el-tag>
+          </template>
+        </el-table-column>
+        <el-table-column align="center" prop="email" label="邮件">
+          <template slot-scope="scope">
+            <span v-html="scope.row.email"></span>
+
+            <br>
+            <el-button type="text" v-if="model.status!=1" @click="doSend(scope.row,1)">发送邮件</el-button>
+          </template>
+        </el-table-column>
+        <el-table-column align="center" prop="mobile" label="手机号">
+
+          <template slot-scope="scope">
+            <span v-html="scope.row.mobile"></span>
+            <br>
+            <!-- <el-button type="text" @click="doSend(scope.row,12)">发送短信</el-button> -->
+          </template>
+        </el-table-column>
+      </el-table>
+    </el-card>
+    <span slot="footer" class="dialog-footer">
+      <!-- <el-button type="primary" @click="dataFormSubmit()">确定</el-button>
+      <el-button @click="visible = false">关闭</el-button> -->
+    </span>
+  </el-dialog>
+</template>
+
+<script>
+// import moment from 'moment';
+// //import util from '@/util'
+export default {
+  data() {
+    return {
+      items: [],
+      title:"查看",
+      visible: false,
+      model: {},
+      tableData: {},
+      items2: [],
+    };
+  },
+  computed: {
+    count() {
+      let a = 0;
+      this.items.forEach(element => {
+        if (element.status != 0) {
+          a++;
+        }
+      });
+      return a + "/" + this.items.length;
+    }
+  },
+  created() {},
+  methods: {
+    init(priceInquiryRow, type) {
+      priceInquiryRow = priceInquiryRow||{};
+      let priceinquiryId = priceInquiryRow.priceinquiryId;
+      let status = priceInquiryRow.status;
+      if(!priceinquiryId){
+        console.error("invalid priceinquiryId");
+        return;
+      }
+      this.visible = true;
+      this.tabActive = "userInfo";
+      let self = this;
+      if (this.$refs["form"]) {
+        this.$refs["form"].resetFields();
+      }
+
+      if (type == 1 || type == 2 || type == 3) {
+        this.model.priceInquiryId = priceinquiryId;
+        this.model.status = status;
+        if (type == 2) {
+          //如果是审核进来   type就==2
+          this.disabled = true;
+          this.formAction = 2;
+          this.btn = "审核";
+          this.title = "审核";
+        } else if (type == 1) {
+          self.formAction = 1;
+          this.title = "编辑";
+        } else {
+          this.disabled = true;
+          this.formAction = 3;
+          this.btn = "确定";
+          this.title = "查看";
+        }
+        let model = self.model;
+        var obj = {
+          url: this.$url.priceInquiry.getById,
+          data: {
+            priceinquiryId: priceinquiryId
+          }
+        };
+        this.common.httpPost(obj, success);
+        function success(data) {
+
+          self.tableData = JSON.parse(JSON.stringify(data));
+          self.items2 = [];
+          self.items2.push(JSON.parse(JSON.stringify(data)));
+          self.items = data.priceInquiryTos;
+        }
+      } else {
+        self.formAction = 0;
+      }
+    },
+    doSend(row,type){
+      let self = this;
+      let urls = '';
+      if(type==1){
+        if(self.tableData.messageEmailConfigId){
+          urls = this.$url.priceInquiry.sendPriceEmail
+        }else{
+          urls = this.$url.priceInquiry.sendEmail
+        }
+
+      }else{
+        urls = this.$url.priceInquiry.sendSms
+      }
+      var obj = {
+        url: urls,
+        data: {
+          priceinquiryId:this.model.priceInquiryId,
+          counterpartyContactId:row.counterpartycontactId,
+        }};
+      this.common.httpPost(obj, success);
+      function success(data) {
+         self.$message({
+           message:"已发送",
+           type:"success"
+         })
+      }
+
+    },
+    doSearch(value) {
+      this.form.page = value;
+
+      let self = this;
+      var obj = {
+        url: "/activiti/getMadelByPage",
+        data: this.form
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+        self.list = data.data.rows;
+        self.total = data.data.total;
+      }
+    }
+  }
+};
+</script>

+ 219 - 0
src/pages/main/leader/components/deptThree.vue

@@ -0,0 +1,219 @@
+<template>
+  <div class="treebox" v-loading="loading" style="height: 30rem">
+      <el-checkbox-group v-model="userList">
+          <div v-for="(item,index) in treeList" :key="index">
+              <el-checkbox :label="item" @change="checkChange(item)">{{item.loginNameStr}}</el-checkbox> </div>
+      </el-checkbox-group>
+    <!-- <el-input placeholder="输入关键字进行过滤" v-model="filterText"></el-input> -->
+<!--    <el-tree-->
+<!--      :highlight-current="true"-->
+<!--      :check-strictly="true"-->
+<!--      ref="tree"-->
+<!--      @check-change="handleCheckChange"-->
+<!--      :data="treeList"-->
+<!--      node-key="id"-->
+<!--      :default-checked-keys="defaultListc"-->
+<!--      :default-expanded-keys="defaultListc"-->
+<!--      @node-click="handleNodeClick"-->
+<!--      :filter-node-method="filterNode"-->
+<!--    >-->
+<!--      <span class="custom-tree-node" slot-scope="{ node }" @click="cs(node)">-->
+<!--        <em-->
+<!--          style="display: inline-block; width: 20px"-->
+<!--          v-if="node.data.haveUserFlag == 'N' && node.data.children.length == 0"-->
+<!--        ></em>-->
+<!--        <i-->
+<!--          class="el-icon-caret-right"-->
+<!--          v-if="node.data.haveUserFlag == 'Y' && node.data.children.length == 0"-->
+<!--        ></i>-->
+<!--        <el-checkbox-->
+<!--          style="margin-right: 10px"-->
+<!--          v-model="node.checked"-->
+<!--          v-if="node.data.type == 1"-->
+<!--        ></el-checkbox>-->
+<!--        <span>{{ node.label }}</span>-->
+<!--      </span>-->
+<!--    </el-tree>-->
+  </div>
+</template>
+
+<script>
+export default {
+    props: ["defaultList", "type", "closeList", "treeList"],
+    data() {
+        return {
+            userList:[],
+            // treeList: [],
+            opt: [],
+            defaultProps: {
+                children: "children",
+                label: "label",
+            },
+            defaultListc: [],
+            loading: false,
+            filterText: "",
+            list:[]
+        };
+    },
+    methods:{
+        checkChange(e){
+  
+  
+            // console.log(this.userList)
+            // let newList = []
+            // this.userList.map((item) =>{
+            //     let array =    {
+            //         userid:item,
+            //         taskid:e.id_,
+            //         nextid:e.id
+            //     }
+            //     newList.push(array)
+            //     // newList.map((items,i) =>{
+            //     //     if(item !== items.userid){
+            //     //         newList.splice(i,1)
+            //     //     }
+            //     //         })
+            //
+            // })
+            // this.list = newList
+            // this.userList.map((item) =>{
+            //     newList.map((items,i) =>{
+            //         if(item !==items.id){
+            //             newList.splice(i,1)
+            //         }
+            //     })
+            // })
+            // console.log(newList)
+            this.$emit('changeTree',this.userList)
+            this.$emit('changeUserName',e)
+
+
+        },
+    }
+}
+    // filterNode(value, data) {
+    //   if (!value) return true;
+    //   return data.label.indexOf(value) !== -1;
+    // },
+    // cs(v) {
+    //   // console.log(v)
+    // },
+    // getTree(v) {
+    //     this.loading = true;
+    //     this.$http({
+    //         url: "/sysmgr/csysdept/queryAllList",
+    //         method: "post",
+    //         headers: {
+    //             "Content-Type": "application/json",
+    //         },
+    //         data: {
+    //             parentorgid: '00440089000000000000',
+    //         },
+    //     }).then((res) => {
+    //         console.log(res);
+    //         // this.treeList = res.data;
+    //         // this.loading = false;
+    //     });
+    // },
+    // handleCheckChange(v) {
+    //     let opt = [];
+    //     let list = this.$refs.tree.getCheckedNodes();
+    //     for (let i = 0; i < list.length; i++) {
+    //         if (list[i].type == 1) {
+    //             opt.push({
+    //                 receiveNo: list[i].loginNoStr,
+    //                 receiveName: list[i].label,
+    //                 deptName: list[i].displayname,
+    //                 deptCode: list[i].groupId,
+    //                 id: list[i].id,
+    //                 type: list[i].type,
+    //                 label: list[i].label,
+    //             });
+    //         }
+    //     }
+    //     this.$emit("treeCheck", opt);
+    // },
+  //   handleNodeClick(v) {
+  //     console.log(v);
+  //     let s = false;
+  //     if (v.children && v.children.length == 0) {
+  //       s = true;
+  //     }
+  //     if (v.type) {
+  //       return;
+  //     }
+  //     if (
+  //       v.children &&
+  //       v.children.length > 0 &&
+  //       v.children[v.children.length - 1].type == 1
+  //     ) {
+  //       return;
+  //     }
+  //     this.$http({
+  //       url: "/sysmgr/sysuserinfo/queryList",
+  //       method: "post",
+  //       headers: {
+  //         "Content-Type": "application/json",
+  //       },
+  //       data: {
+  //         groupId: v.o,
+  //       },
+  //     }).then((res) => {
+  //       res.data.forEach((item) => {
+  //         v.children.push({
+  //           id: item.id,
+  //           label: item.loginNameStr,
+  //           type: 1,
+  //           displayname: v.displayname,
+  //           groupId: item.groupId,
+  //           loginNoStr: item.loginNoStr,
+  //         });
+  //       });
+  //     });
+  //     for (let i = 0; i < this.$refs.tree.store._getAllNodes().length; i++) {
+  //       if (s && v.o == this.$refs.tree.store._getAllNodes()[i].data.o) {
+  //         this.$refs.tree.store._getAllNodes()[i].expanded = true;
+  //         return;
+  //       }
+  //     }
+  //   },
+  // },
+//   created() {
+//     console.log(this.treeList);
+//     // this.getTree();
+//     this.defaultListc = this.defaultList;
+//   },
+//   watch: {
+//     filterText(val) {
+//       this.$refs.tree.filter(val);
+//     },
+//     type() {
+//       this.defaultListc = this.defaultList;
+//       this.$forceUpdate();
+//     },
+//     defaultList() {
+//       this.$forceUpdate();
+//     },
+//     closeList() {
+//       this.$refs.tree.setCheckedNodes(this.closeList);
+//     },
+//   },
+// };
+</script>
+
+<style scoped lang="scss">
+.el-icon-caret-right {
+  color: #ccc;
+  margin: 0 5px;
+}
+.treebox {
+  border: 1px solid #ddd;
+}
+    ::v-deep .el-checkbox-group{
+        display: flex;
+        flex-direction: column;
+        align-items: baseline;
+        /* font-size: 38px; */
+        margin-left: 20px;
+    }
+</style>

+ 102 - 0
src/pages/main/leader/components/export.vue

@@ -0,0 +1,102 @@
+<template>
+  <div class="flex-count">
+    <div class="flex-num">
+      <div class="time-title">已选({{ num }})项</div>
+      <div v-if="!approvalStatus" class="flex-time">
+        <div class="time-title">时间:</div>
+ <el-date-picker
+      v-model="seachList"
+      type="daterange"
+      start-placeholder="开始日期"
+      end-placeholder="结束日期"
+      value-format="yyyy-MM-dd"
+      :default-time="['00:00:00', '23:59:59']">
+      size="small"
+    </el-date-picker>
+        <el-button
+          type="primary"
+          @click="clickSeach"
+          plain
+          >搜索</el-button
+        >
+      </div>
+    </div>
+    <div class="flex-num" v-if="exportStatusList">
+      <!-- <el-button
+        type="primary"
+        @click="clickApproval"
+        v-if="approvalStatus"
+        plain
+        >批量审批</el-button
+      > -->
+      <el-button type="primary" @click="clickExport" v-if="exportStatus" plain
+        >批量导出</el-button
+      >
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  props: {
+    num: {
+      type: Number,
+      default: () => [],
+    },
+      exportStatusList: {
+          type:Boolean,
+          default: () => [],
+      },
+  },
+  data() {
+    return {
+      seachList:'',
+      approvalStatus: true,
+      exportStatus: true,
+    };
+  },
+  methods: {
+    clickExport() {
+      if (this.approvalStatus) {
+        this.approvalStatus = false;
+        this.$emit("clickexport", true);
+      } else {
+        this.$emit("export", true);
+      }
+    },
+    clickApproval() {
+        this.$emit('clickApproval',true)
+
+    },
+    clickSeach(){
+
+
+        this.$emit('seachExportList',this.seachList)
+    }
+  },
+  created() {
+
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.time-title {
+  margin-right: 20px;
+  height: 40px;
+  line-height: 40px;
+}
+.flex-count {
+  display: flex;
+  justify-content: space-between;
+  .flex-num {
+    margin: 1%;
+    display: flex;
+    .flex-time {
+      display: flex;
+      margin-left: 20px;
+      margin-right: 20px;
+    }
+  }
+}
+</style>

+ 121 - 0
src/pages/main/leader/components/form.vue

@@ -0,0 +1,121 @@
+<template>
+  <div>
+    <slot :name="list.name"></slot>
+    <el-table ref="table" style="width: 100%" :data="list.data" :height="list.height + 'px'"
+      :max-height="list.height + 'px'" @row-click="getRowData" @selection-change="selectionChange"
+      :cell-style="columnbackgroundStyle" empty-text="暂无数据" @cell-click="getRowList">
+      <!-- 是否多选 -->
+      <el-table-column v-if="list.isSelection" :selecttable="list" type="selection" :width="100" align="center" />
+
+      <!-- 是否需要序号 -->
+      <el-table-column v-if="list.isIndex" type="index" label="序号" width="55" align="center" />
+      <template v-for="item in list.titledata">
+        <el-table-column :key="item.prop" :prop="item.prop" :label="item.label" align="center" show-overflow-tooltip
+          :width="item.width || 100" />
+      </template>
+      <!-- 操作列 -->
+      <el-table-column v-if="list.isOperation" v-bind="list.data && list.data.length ? { fixed: 'right' } : null"
+        style="margin-right: 20px" class-name="handle-td" label-class-name="tc" :label="list.operation.label"
+        align="center">
+        <!-- UI统一一排放3个,4个以上出现更多 -->
+        <template slot-scope="scope">
+          <!-- 三个一排的情况,去掉隐藏的按钮后的长度 -->
+          <template v-if="list.operation.data.length > 0">
+            <div class="btn">
+              <div v-for="item in list.operation.data" :key="item.label">
+                <template v-if="item.type !== 'icon'">
+                  <el-button v-bind="item" :type="item.type ? item.type : ''" size="mini" @click.native.prevent="
+                    item.handleRow(scope.$index, scope.row, item.label)
+                  ">
+                    {{ item.label }}
+                  </el-button>
+                </template>
+                <template v-else>
+                  <i :class="[icon, item.icon]" v-bind="item"
+                    @click="item.handleRow(scope.$index, scope.row, item.label)" />
+                </template>
+              </div>
+            </div>
+          </template>
+        </template>
+      </el-table-column>
+    </el-table>
+    <div class="page">
+      <el-pagination style="display: flex; flex-direction: row-reverse" v-if="list.pageData.total > 0"
+        :current-page.sync="page" :page-sizes="list.pageData.pageSizes ? list.pageData.pageSizes : [10]"
+        :page-size="list.pageData.pageSize" layout="total, sizes, prev, pager, next, jumper"
+        :total="list.pageData.total" @size-change="handleSizeChange" @current-change="handleCurrentChange" />
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      page: 1,
+    };
+  },
+  props: {
+    //  表格数据和表格部分属性的对象
+    // eslint-disable-next-line vue/require-default-prop
+    list: {
+      type: Object,
+    },
+  },
+  created() {
+    console.log(this.list);
+    // this.columnbackgroundStyle()
+  },
+  mounted() {
+    console.log(this.list);
+  },
+  methods: {
+    columnbackgroundStyle({ row, column, rowIndex, columnIndex }) {
+      // console.log(row);
+      // console.log(column);
+      // console.log(rowIndex);
+      // console.log(columnIndex);
+      if (column.type == 'default') {
+        if (column.label === '需求名称') {
+          return 'color:#0682CD;'
+        }
+      }
+      //   if (columnIndex == 1) {
+      // 	//让下标为1的列数背景颜色显示为红色(颜色自定义根据大家需求来)
+      //     return 'color:#0682CD;'
+      // }
+    },
+    selectionChange(val) {
+      //多选数字回调
+      this.$emit("num", val);
+    },
+    handleAdd(name) {
+      this.$emit("toolMsg", name);
+    },
+    handleRow(index, row, lable) { },
+    handleSizeChange(val) {
+      this.$emit("changeSize", val);
+      console.log(`每页 ${val} 条`);
+    },
+    handleCurrentChange(val) {
+      this.$emit("changeNum", val);
+      console.log(`当前页: ${val}`);
+    },
+    // 点击行即可选中
+    getRowData(row) {
+      this.$refs.table.toggleRowSelection(row);
+    },
+    getRowList(row, column, event, cell) {
+      this.$emit("clickDemand", column.label, row);
+    },
+  },
+};
+</script>
+
+<style>
+.btn {
+  display: flex;
+  justify-content: center;
+}
+</style>

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1073 - 0
src/pages/main/leader/components/formTable.vue


+ 139 - 0
src/pages/main/leader/components/search.vue

@@ -0,0 +1,139 @@
+<!-- @2022 -6-13 @dalaoyang -->
+<!-- 搜索栏组件,后期可加判断 -->
+<!-- 支持input select 按钮显示-->
+
+
+<template>
+  <div class="flex-count">
+    <div class="flex-container">
+      <template v-if="list.elinput">
+        <div
+          class="flex-title"
+          v-for="item in list.elinput"
+          :key="'input'+item.key"
+        >
+          <div>{{ item.name }}</div>:
+          <el-input
+            v-model="seachList[item.key]"
+            :placeholder="item.name"
+            :style="{ width: item.width ? item.width + 'px' : '400px' }"
+            class="filter-item"
+            clearable
+          />
+        </div>
+      </template>
+      <template v-if="list.date">
+        <div
+          class="flex-title"
+         
+          v-for="(item, index) in list.date"
+          :key="'input'+index"
+        >
+          <div>{{ item.name }}</div>:
+          <div >
+            <el-date-picker
+              :key="'date'+index"
+              value-format="yyyy-MM-dd"
+             v-model="seachList[item.key]"
+              type="daterange"
+            :style="{ width: item.width ? item.width + '%' : '400px' }"
+              
+              range-separator="至"
+              start-placeholder="开始日期"
+              end-placeholder="结束日期"
+            >
+            </el-date-picker>
+          </div>
+        </div>
+      </template>
+      <template v-if="list.elselect">
+        <div
+          class="flex-title"
+          v-for="(item, index) in list.elselect"
+          :key="'select'+index"
+        >
+          {{ item.name }}:
+        </div>
+        <el-select
+          v-for="item in list.elselect"
+          :key="'select'+item.key"
+          v-model="seachList[item.key]"
+          :placeholder="item.name"
+          clearable
+          :style="{ width: item.width ? item.width + 'px' : '90px' }"
+          class="filter-item"
+        >
+          <el-option
+            v-for="i in item.option"
+            :key="i.key"
+            :label="i.value"
+            :value="i.value"
+          />
+        </el-select>
+      </template>
+    </div>
+    <div class="btn">
+      <el-button
+        v-if="list.sreach"
+        class="filter-item"
+        type="primary"
+        @click="handleSearch"
+      >
+        搜索
+      </el-button>
+      <el-button
+        v-if="list.reset"
+        class="filter-item"
+        type="warning"
+        @click="handleRest"
+      >
+        重置
+      </el-button>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  props: {
+    list: {
+      type: Object,
+      default: () => {},
+    },
+  },
+  data() {
+    return {
+      seachList: {},
+    };
+  },
+  methods: {
+    //搜索事件
+    handleSearch() {
+      this.$emit("seachList", this.seachList);
+    },
+    //重置事件
+    handleRest() {},
+  },
+};
+</script>
+
+<style  lang="scss" scoped>
+.flex-count {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+}
+.flex-container {
+  display: -webkit-box;
+}
+.flex-title {
+  height: 40px;
+  line-height: 40px;
+  margin-left: 40px;
+  margin-right: 15px;
+  display: flex;
+}
+.filter-item {
+  width: 9rem;
+}
+</style>

+ 55 - 0
src/pages/main/leader/components/tabs.vue

@@ -0,0 +1,55 @@
+<template>
+  <el-tabs v-model="activeName" @tab-click="handleClick">
+    <!-- <el-tab-pane
+    class="flex-tabs"
+      v-for="item in tabList"
+      :key="item.index"
+      :label="item.label"
+      :name="item.index"
+    >
+    </el-tab-pane> -->
+    <el-tab-pane v-for="item in tabList" :key="item.index" :name="item.index">
+      <span slot="label"
+        >{{ item.label }} <span v-if="item.number">({{ item.number }})</span>
+      </span>
+    </el-tab-pane>
+    <!-- <el-tab-pane label="用户管理" name="first">用户管理</el-tab-pane>
+    <el-tab-pane label="配置管理" name="second">配置管理</el-tab-pane>
+    <el-tab-pane label="角色管理" name="third">角色管理</el-tab-pane>
+    <el-tab-pane label="定时任务补偿" name="fourth">定时任务补偿</el-tab-pane> -->
+  </el-tabs>
+</template>
+
+<script>
+export default {
+  props: {
+    active: {
+      type: String,
+      default: "first",
+    },
+    tabList: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  data() {
+    return {
+      activeName: "first",
+    };
+  },
+  created() {
+  },
+  methods: {
+    handleClick(tab, event) {
+      this.$emit("status", tab._props.name);
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped >
+.flex-tabs {
+  background-color: red !important;
+  color: red !important;
+}
+</style>

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1597 - 0
src/pages/main/leader/demand/demandHome.vue


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 1682 - 0
src/pages/main/leader/demand/demandHomes.vue


+ 412 - 0
src/pages/main/leader/demand/reportForm.vue

@@ -0,0 +1,412 @@
+<template>
+  <div class="flex-header">
+    <Seach
+      style="margin-top: 20px"
+      :list="filterData"
+      @seachList="seachList"
+    ></Seach>
+    <div class="flex-export">
+      <el-button class="flex-button" type="primary" @click="clickExport"
+        >导出</el-button
+      >
+    </div>
+    <Table
+      ref="table"
+      :list="firstTable"
+      @changeNum="changeNum"
+      @changeSize="changeSize"
+    >
+    </Table>
+    <el-dialog
+      title="详细信息"
+      :visible.sync="dialogStatus"
+      width="100%"
+      :before-close="handleClose"
+      :modal="false"
+      :destroy-on-close="true"
+    >
+      <Table :list="twoTable" class="flex-form" ref="formTable" />
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import FormTable from "../components/formTable.vue";
+import Seach from "../components/search.vue";
+import Export from "../components/export.vue";
+import Tabs from "../components/tabs.vue";
+import Table from "../components/form.vue";
+import deptTree from "../components/deptThree.vue";
+export default {
+  components: {
+    Tabs,
+    Table,
+    Export,
+    Seach,
+    FormTable,
+    deptTree,
+  },
+  data() {
+    return {
+      seachLists: {},
+      firstTable: {
+        name: "first",
+        height: "700",
+        titledata: [
+          {
+            label: "需求决策编号",
+            prop: "needNo",
+            width: 200,
+          },
+          {
+            label: "需求名称",
+            prop: "needName",
+            width: 200,
+          },
+          {
+            label: "提出部门",
+            prop: "applyDept",
+            width: 200,
+          },
+          {
+            label: "提出人",
+            prop: "proposer",
+            width: 200,
+          },
+          {
+            label: "提出时间",
+            prop: "proposerTime",
+            width: 200,
+          },
+          {
+            label: "当前状态",
+            prop: "taskName",
+            width: 200,
+          },
+          {
+            label: "需求讨论确认时间",
+            prop: "tlTime",
+            width: 200,
+          },
+          {
+            label: "需求排期开始时间",
+            prop: "paiqiBegin",
+            width: 200,
+          },
+          {
+            label: "需求排期结束时间",
+            prop: "paiqiEnd",
+            width: 200,
+          },
+          {
+            label: "上线时间",
+            prop: "onlineTime",
+            width: 200,
+          },
+          {
+            label: "需求一级目录",
+            prop: "firstDirectory",
+            width: 200,
+          },
+          {
+            label: "需求二级目录",
+            prop: "secondDirectory",
+            width: 200,
+          },
+          {
+            label: "需求三级目录",
+            prop: "thirdDirectory",
+            width: 200,
+          },
+          {
+            label: "需求四级目录",
+            prop: "fourthDirectory",
+            width: 200,
+          },
+          {
+            label: "需求五级目录",
+            prop: "fifthDirectory",
+            width: 200,
+          },
+        ], //表格头
+        data: [], //内容数据
+        loading: true,
+        pageData: {
+          total: 100, // 总条数
+          pageSize: 10, // 每页数量
+          pageNum: 1, // 页码
+        },
+        isSelection: false, // 表格有多选时设置
+        isOperation: false, // 表格有操作列时设置
+        isIndex: false, // 列表序号
+        operation: {
+          // 表格有操作列时设置
+          label: "操作", // 列名
+          width: "50", // 根据实际情况给宽度
+          data: [
+            {
+              label: "操作", // 操作名称
+              type: "", //按钮类型
+              handleRow: (e, r, o) => {
+                this.getQueryList(r);
+              }, // 自定义事件
+            },
+          ],
+        },
+      },
+      twoTable: {
+        name: "first",
+        height: "300",
+        titledata: [
+          {
+            label: "需求决策编号",
+            prop: "needNo",
+            width: 200,
+          },
+          {
+            label: "业支需求编号",
+            prop: "reqNum",
+            width: 200,
+          },
+          {
+            label: "业支需求名称",
+            prop: "needName",
+            width: 200,
+          },
+          {
+            label: "需求负责人",
+            prop: "createUser",
+            width: 200,
+          },
+          {
+            label: "需求讨论确认时间",
+            prop: "tlTime",
+            width: 200,
+          },
+          {
+            label: "当前状态",
+            prop: "taskName",
+            width: 200,
+          },
+          {
+            label: "需求开发开始时间",
+            prop: "paigiBegin",
+            width: 200,
+          },
+          {
+            label: "需求开发结束时间",
+            prop: "paigiEnd",
+            width: 200,
+          },
+          {
+            label: "需求测试开始时间",
+            prop: "startTime",
+            width: 200,
+          },
+          {
+            label: "需求测试结束时间",
+            prop: "endTime",
+            width: 200,
+          },
+          {
+            label: "计划上线时间",
+            prop: "paiqiPlanOnlineTime",
+            width: 200,
+          },
+          {
+            label: "上线时间",
+            prop: "onlineTime",
+            width: 200,
+          },
+          {
+            label: "所属系统",
+            prop: "sysBelong",
+            width: 200,
+          },
+        ], //表格头
+        data: [], //内容数据
+        loading: true,
+        pageData: {
+          total: "", // 总条数
+          pageSize: 10, // 每页数量
+          pageNum: 1, // 页码
+        },
+        isSelection: false, // 表格有多选时设置
+        isOperation: false, // 表格有操作列时设置
+        isIndex: false, // 列表序号
+        operation: {
+          // 表格有操作列时设置
+          label: "操作", // 列名
+          width: "50", // 根据实际情况给宽度
+          data: [
+            {
+              label: "操作", // 操作名称
+              type: "", //按钮类型
+              handleRow: (e, r, o) => {
+                console.log(r);
+                this.dialogStatus = true;
+              }, // 自定义事件
+            },
+          ],
+        },
+      },
+      filterData: {
+        timeSelect: true, //是否显示日期控件
+        sreach: true,
+        restet: false,
+        elinput: [
+          {
+            name: "需求决策编号", //提示语275
+            key: "needNo", //字段名
+            width: 120, //宽度
+          },
+          {
+            name: "需求名称", //提示语275
+            key: "needName", //字段名
+            width: 120, //宽度
+          },
+        ],
+        date: [
+          {
+            name: "需求提出时间",
+            key: "time",
+            width: 40,
+          },
+        ],
+      },
+      dialogStatus: false,
+      page: 1,
+      size: 10,
+    };
+  },
+  created() {
+    this.getQueryLists();
+  },
+  methods: {
+    //报表导出
+
+    clickExport() {
+      this.$http({
+        url: "/market/waf/excelExport",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        responseType: "blob",
+        data: this.seachLists ? this.seachLists : {},
+      }).then((response) => {
+        if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+          let blob = new Blob([response.data.size], {
+            type: "application/vnd.ms-excel;",
+          });
+
+          // window.navigator.msSaveOrOpenBlob(blob, res + "需求申请单" + ".zip");
+
+          window.navigator.msSaveOrOpenBlob(blob, "需求管理报表" + ".xlsx");
+
+          //window.navigator.msSaveOrOpenBlob(blob, t his.form.needName);
+        } else {
+          /* 火狐谷歌的文件下载方式 */
+          var blob = new Blob([response.data]);
+          var downloadElement = document.createElement("a");
+          var href = window.URL.createObjectURL(blob);
+          downloadElement.href = href;
+
+          downloadElement.download =  "需求管理报表" + ".xlsx";
+
+          document.body.appendChild(downloadElement);
+          downloadElement.click();
+          document.body.removeChild(downloadElement);
+          window.URL.revokeObjectURL(href);
+        }
+      });
+    },
+    //报表首页接口
+    getQueryLists(e) {
+      this.$http({
+        url: "/market/waf/queryReport",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+          page: '{"pageNo":"' + this.page + '","pageSize":"' + this.size + '"}',
+        },
+        data: e || {},
+      }).then((res) => {
+        console.log(res);
+        this.firstTable.pageData.total = res.data.totalRecord;
+        this.firstTable.data = res.data.data;
+      });
+    },
+    getQueryList(e) {
+      if (e.needNo !== null) {
+        this.$http({
+          url: "/market/relation/getRelation",
+          method: "post",
+          headers: {
+            "Content-Type": "application/json",
+          },
+          data: {
+            needNo: e.needNo,
+          },
+        }).then((res) => {
+          this.twoTable.data = res.data.cwfInfo;
+          this.dialogStatus = true;
+        });
+      } else {
+        this.$message.error("暂无需求决策编号");
+      }
+    },
+    //子需求dialogStatus显示
+    handleClose() {
+      this.dialogStatus = false;
+      this.twoTable.data = [];
+    },
+    //搜索数据回调
+    seachList(e) {
+      this.$refs.table.page = 1;
+      this.page = 1;
+      this.size = 10;
+      this.seachLists = e;
+      if (e.time) {
+        e.stime = e.time[0];
+        e.etime = e.time[1];
+      } else {
+        e.stime = "";
+        e.etime = "";
+      }
+      this.getQueryLists(e);
+    },
+    changeNum(e) {
+      this.page = e;
+      this.getQueryLists(this.seachLists);
+    },
+    changeSize(e) {
+      this.size = e;
+      this.getQueryLists(this.seachLists);
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.flex-export {
+  margin: 10px 0 10px 0;
+  text-align: end;
+}
+.flex-button {
+  width: 6%;
+}
+.flex-header {
+  display: flex;
+  width: calc(100% - 40px);
+  border-radius: 20px;
+  background-color: #fff;
+  margin: 0 auto;
+  margin-top: 20px;
+  position: relative;
+  -webkit-box-orient: vertical;
+  -webkit-box-direction: normal;
+  -ms-flex-direction: column;
+  flex-direction: column;
+}
+</style>

+ 269 - 0
src/pages/main/leader/demand/supportState.vue

@@ -0,0 +1,269 @@
+<template>
+  <div class="flex-box">
+    <div class="flex-header">
+      <Table :list="firstTable" />
+    </div>
+    <div class="flex-count" v-for="(item, index) in listTable" :key="index">
+      <div>
+        <el-descriptions class="margin-top" :column="2" :size="size" border>
+          <template slot="extra"> </template>
+          <el-descriptions-item
+            labelStyle="text-align:center;width:10%;background-color:#F3FAFF;color:black;font-size: 15px;font-weight: bold;text-indent: 10px"
+          >
+            <template slot="label"> 子需求编号 </template>
+            {{ item.id }}
+          </el-descriptions-item>
+          <el-descriptions-item
+            labelStyle="text-align:center;width:10%;background-color:#F3FAFF;color:black;font-size: 15px;font-weight: bold;text-indent: 10px"
+          >
+            <template slot="label"> 需求负责人 </template>
+            {{ item.createUser }}
+          </el-descriptions-item>
+          <el-descriptions-item
+            labelStyle="text-align:center;width:10%;background-color:#F3FAFF;color:black;font-size: 15px;font-weight: bold;text-indent: 10px"
+          >
+            <template slot="label"> 需求名称 </template>
+            {{ item.needName }}
+          </el-descriptions-item>
+          <el-descriptions-item
+            labelStyle="text-align:center;width:10%;background-color:#F3FAFF;color:black;font-size: 15px;font-weight: bold;text-indent: 10px"
+          >
+            <template slot="label"> 系统分类 </template>
+            {{ item.reqNum }}
+          </el-descriptions-item>
+        </el-descriptions>
+      </div>
+      <div class="flex-state">
+        <div class="flex-title">进度状态</div>
+        <div class="flex-img">
+          <div
+            class="flex-img-count"
+            v-for="(items, index) in item.state"
+            :key="index"
+          >
+            <div class="flex-text">{{ items.name }}</div>
+            <div class="flex-time flex-text">{{ items.time }}</div>
+            <img :src="items.imgUrl" alt="" />
+          </div>
+          <!-- <img src="../../../../assets/jiantou.png" alt=""> -->
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import Table from "../components/form.vue";
+export default {
+  components: {
+    Table,
+  },
+
+  data() {
+    return {
+      size: "",
+      list: [],
+      firstTable: {
+        name: "first",
+        height: "120",
+        titledata: [
+          {
+            label: "需求决策编号",
+            prop: "needNo",
+            width: 250,
+          },
+          {
+            label: "需求名称",
+            prop: "needName",
+            width: 250,
+          },
+          {
+            label: "需求创建时间",
+            prop: "proposerTime",
+            width: 250,
+          },
+          {
+            label: "需求确认时间",
+            prop: "tlTime",
+            width: 250,
+          },
+          {
+            label: "需求排期开始时间",
+            prop: "paiqiBegin",
+            width: 300,
+          },
+          {
+            label: "需求排期结束时间",
+            prop: "paiqiEnd",
+            width: 250,
+          },
+          {
+            label: "计划上线时间",
+            prop: "paiqiPlanOnlineTime",
+            width: 200,
+          },
+          {
+            label: "实际上线时间",
+            prop: "onlineTime",
+            width: 200,
+          },
+        ], //表格头
+        data: [
+          // {
+          //   date: "2016-05-04",
+          //   name: "王小虎",
+          //   address: "上海市普陀区金沙江路 1517 弄",
+          // },
+          //   {
+          //     date: "2016-05-01",
+          //     name: "王小虎",
+          //     address: "上海市普陀区金沙江路 1519 弄",
+          //   },
+          //   {
+          //     date: "2016-05-03",
+          //     name: "王小虎",
+          //     address: "上海市普陀区金沙江路 1516 弄",
+          //   },
+        ], //内容数据
+        loading: true,
+        pageData: {
+          total: 0, // 总条数
+          pageSize: 10, // 每页数量
+          pageNum: 1, // 页码
+        },
+        isSelection: false, // 表格有多选时设置
+        isOperation: false, // 表格有操作列时设置
+        isIndex: false, // 列表序号
+        // operation: {
+        //   // 表格有操作列时设置
+        //   label: "操作", // 列名
+        //   width: "50", // 根据实际情况给宽度
+        //   data: [
+        //   ],
+        // },
+      },
+      listTable: [],
+      listImg: [
+        {
+          name: "创建时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img1.png"),
+        },
+        {
+          name: "确认时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img2.png"),
+        },
+        {
+          name: "排期时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img3.png"),
+        },
+        {
+          name: "开发完成时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img4.png"),
+        },
+        {
+          name: "测试完成时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img5.png"),
+        },
+        {
+          name: "上线时间",
+          time: "123123123",
+          imgUrl: require("../../../../assets/a_img6.png"),
+        },
+      ],
+      needNo: "",
+    };
+  },
+  created() {
+    this.needNo = this.$route.query.id;
+    this.getQueryList();
+  },
+  methods: {
+    getQueryList() {
+      this.$http({
+        url: "/market/relation/getRelation",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          needNo: this.needNo,
+        },
+      }).then((res) => {
+        this.firstTable.data.push(res.data);
+        this.listTable = res.data.cwfInfo;
+        this.listTable.map((item) => {
+          item.state.map((items, index) => {
+            if (items.status === false) {
+              items.imgUrl = require("../../../../assets/b_img" +
+                (index + 1) +
+                ".png");
+            } else {
+              items.imgUrl = require("../../../../assets/a_img" +
+                (index + 1) +
+                ".png");
+            }
+          });
+        });
+      });
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+//
+::v-deep .el-table {
+  border-radius: 10px;
+}
+.flex-box {
+  padding: 1%;
+  border-radius: 20px !important;
+  .flex-count {
+    width: 100%;
+    padding: 1%;
+    background-color: #fff;
+    margin-top: 20px;
+    border-radius: 10px;
+    margin-bottom: 40px;
+    .flex-state {
+      margin-top: 20px;
+      border: 1px solid #e8e8e8;
+      .flex-title {
+        height: 40px;
+        line-height: 40px;
+        background-color: #f3faff;
+        border-bottom: 1px solid #e8e8e8;
+        font-size: 15px;
+        font-weight: bold;
+        text-indent: 10px;
+      }
+      .flex-img {
+        display: flex;
+        margin: 30px;
+        background: url("../../../../assets/jiantou1.png");
+        background-repeat: no-repeat;
+        background-position: 30px 75%;
+        background-size: 97% 30%;
+        .flex-img-count {
+          margin-left: 20px;
+          width: 15%;
+          text-align: center;
+
+          .flex-text {
+            font-size: 16px;
+          }
+          .flex-time {
+            margin-top: 5px;
+            margin-bottom: 10%;
+          }
+        }
+      }
+    }
+  }
+}
+</style>

+ 298 - 305
src/pages/main/leader/leaderhomeTask.vue

@@ -2,9 +2,7 @@
   <div style="display: flex; justify-content: space-between">
     <div class="taskbox">
       <div class="tit">
-        <span class="span1" @click="tabboxclick1"
-          >我的待办 ({{ this.niticList.length }})</span
-        >
+        <span class="span1" @click="tabboxclick1">我的待办 ({{ this.daitotal }})</span>
         <span class="span2" @click="tabboxclick2">我的已办</span>
         <span class="span3" @click="tabboxclick3">我的发起</span>
         <!-- <span class="span" @click="more">更多>></span> -->
@@ -12,300 +10,173 @@
       <div class="fatherbox">
         <div class="tabbox">
           <!-- 我的待办列表 -->
-          <el-table
-            :header-cell-style="{
-              background: '#F2F2F2',
-              'text-align': 'center',
-            }"
-            :cell-style="{ background: '#FaFaFa' }"
-            v-if="tabbox1"
-            class="com-table"
-            ref="multipleTable"
-            :data="niticList"
-            tooltip-effect="dark"
-            size="small"
-            style="width: 100%; font-size: 16px; background: '#FaFaFa'"
-            height="442px"
-          >
-            <el-table-column
-              prop="woTitle"
-              label="工单标题"
-              align="left"
-              :show-overflow-tooltip="true"
-            >
+          <el-table :header-cell-style="{
+            background: '#F2F2F2',
+            'text-align': 'center',
+          }" :cell-style="{ background: '#FaFaFa' }" v-if="tabbox1" class="com-table" ref="multipleTable"
+            :data="niticList" tooltip-effect="dark" size="small"
+            style="width: 100%; font-size: 16px; background: '#FaFaFa'" height="442px">
+            <el-table-column prop="woTitle" label="工单标题" align="left" :show-overflow-tooltip="true">
               <template slot-scope="scope">
-                <span
-                  :title="scope.row.woTitle"
-                  @click="RowTitle(scope.row)"
-                  :style="
-                    scope.row.woTypeDesc == '预警工单'
-                      ? 'cursor: pointer;color:red;'
-                      : 'cursor: pointer;color:blue;'
-                  "
-                >
+                <span :title="scope.row.woTitle" @click="RowTitle(scope.row)" :style="
+                  scope.row.woTypeDesc == '预警工单'
+                    ? 'cursor: pointer;color:red;'
+                    : 'cursor: pointer;color:blue;'
+                ">
                   <!-- <span style="float: left; color: #afb2d8;margin-right:5px"
                   >•</span> -->
-                  {{ scope.row.woTitle }}</span
-                >
+                  {{ scope.row.woTitle }}
+                </span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="procName"
-              label="流程名称"
-              align="center"
-              width="180"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="procName" label="流程名称" align="center" width="180" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <span :title="scope.row.procName">{{
-                  scope.row.procName
+                    scope.row.procName
                 }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="assigneName"
-              label="上一步处理人"
-              align="center"
-              width="120"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="assigneName" label="上一步处理人" align="center" width="120" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <span :title="scope.row.assigneName">{{
-                  scope.row.assigneName
+                    scope.row.assigneName
                 }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="clsj"
-              label="上一步处理时间"
-              align="center"
-              width="140"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="clsj" label="上一步处理时间" align="center" width="135" :show-overflow-tooltip="true">
               <template slot-scope="scope">
-                <span>{{ scope.row.clsj }}</span>
+                <span  :title="scope.row.clsj">{{ scope.row.clsj }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="opName"
-              label="发起姓名"
-              align="center"
-              width="100"
-            >
+            <el-table-column prop="opName" label="发起人" align="center" width="100">
               <template slot-scope="scope">
                 <span>{{ scope.row.opName }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="createTime"
-              label="发起时间"
-              align="center"
-              width="120"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="createTime" label="发起时间" align="center" width="130" :show-overflow-tooltip="true">
               <template slot-scope="scope">
-                <span>{{ scope.row.createTime }}</span>
+                <span  :title="scope.row.createTime">{{ scope.row.createTime }}</span>
               </template>
             </el-table-column>
           </el-table>
-          <el-pagination
-            class="pageBox"
-            @current-change="currchangeDdaiban"
-            layout="total,prev, pager, next"
-            background
-            :page-size="pagesize"
-            :total="totalDaiban"
-            v-if="tabbox1"
-          >
+          <!-- <el-pagination class="pageBox" @current-change="currchangeDdaiban" layout="total,prev, pager, next" background
+            page-size="10" :total="totalDaiban" v-if="tabbox1">
+          </el-pagination> -->
+          <el-pagination @current-change="currchangeDdaiban" :current-page="daipage" :page-size="daisize"
+            layout="total,prev, pager, next" :total="daitotal" v-if="tabbox1">
           </el-pagination>
         </div>
         <div class="tabbox">
           <!-- 我的已办列表 -->
-          <el-table
-            :header-cell-style="{
-              background: '#F2F2F2',
-              'text-align': 'center',
-            }"
-            :cell-style="{ background: '#FaFaFa' }"
-            class="com-table"
-            ref="tableDatayj"
-            v-if="tabbox2"
-            :data="tableDatayj"
-            tooltip-effect="dark"
-            size="small"
-            style="width: 100%; font-size: 16px; background: '#FaFaFa'"
-            height="442px"
-          >
-            <el-table-column
-              prop="woTitle"
-              label="工单标题"
-              align="left"
-              :show-overflow-tooltip="true"
-            >
+          <el-table :header-cell-style="{
+            background: '#F2F2F2',
+            'text-align': 'center',
+          }" :cell-style="{ background: '#FaFaFa' }" class="com-table" ref="tableDatayj" v-if="tabbox2"
+            :data="tableDatayj" tooltip-effect="dark" size="small"
+            style="width: 100%; font-size: 16px; background: '#FaFaFa'" height="442px">
+            <el-table-column prop="woTitle" label="工单标题" align="left" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <!-- <span style="float: left; color: #afb2d8;margin-right:5px"
                   >•</span
                 > -->
-                <span
-                  @click="RowDoneTitle(scope.row)"
-                  :title="scope.row.woTitle"
-                  style="cursor: pointer; color: blue"
-                  >{{ scope.row.woTitle }}</span
-                >
+                <span @click="RowDoneTitle(scope.row)" :title="scope.row.woTitle"
+                  style="cursor: pointer; color: blue">{{ scope.row.woTitle }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="procName"
-              label="流程名称"
-              align="center"
-              width="180"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="procName" label="流程名称" align="center" width="180" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <span :title="scope.row.procName">{{
-                  scope.row.procName
+                    scope.row.procName
                 }}</span>
               </template>
             </el-table-column>
 
-            <el-table-column
-              prop="opName"
-              label="发起姓名"
-              align="center"
-              width="120"
-            >
+            <el-table-column prop="opName" label="发起人" align="center" width="120">
               <template slot-scope="scope">
                 <span>{{ scope.row.opName }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="createTime"
-              label="发起时间"
-              align="center"
-              width="180"
-            >
+            <el-table-column prop="createTime" label="发起时间" align="center" width="180">
               <template slot-scope="scope">
                 <span>{{ scope.row.createTime }}</span>
               </template>
             </el-table-column>
           </el-table>
-          <el-pagination
-            class="pageBox"
-            v-if="tabbox2"
-            @current-change="currchangeDone"
-            layout="total,prev, pager, next"
-            background
-            :total="totalDone"
-            :page-size="pagesize"
-          >
+          <!-- <el-pagination class="pageBox"  @current-change="currchangeDone"
+            layout="total,prev, pager, next" background :total="totalDone" page-size="10">
+          </el-pagination> -->
+          <el-pagination @current-change="currchangeDyiban" :current-page="yibanpage" :page-size="yibansize"
+            layout="total,prev, pager, next" :total="yibantotal" v-if="tabbox2">
           </el-pagination>
         </div>
         <div class="tabbox">
           <!-- 我的发起列表 -->
-          <el-table
-            :header-cell-style="{
-              background: '#F2F2F2',
-              'text-align': 'center',
-            }"
-            :cell-style="{ background: '#FaFaFa' }"
-            class="com-table"
-            ref="OpList"
-            :data="OpList"
-            v-if="tabbox3"
-            tooltip-effect="dark"
-            size="small"
-            style="width: 100%; font-size: 16px; background: '#FaFaFa'"
-            height="442px"
-          >
-            <el-table-column
-              prop="woTitle"
-              label="工单标题"
-              align="left"
-              :show-overflow-tooltip="true"
-            >
+          <el-table :header-cell-style="{
+            background: '#F2F2F2',
+            'text-align': 'center',
+          }" :cell-style="{ background: '#FaFaFa' }" class="com-table" ref="OpList" :data="OpList" v-if="tabbox3"
+            tooltip-effect="dark" size="small" style="width: 100%; font-size: 16px; background: '#FaFaFa'"
+            height="442px">
+            <el-table-column prop="woTitle" label="工单标题" align="left" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <!-- <span style="float: left; color: #afb2d8;margin-right:5px"
                   >•</span
                 > -->
-                <span
-                  :title="scope.row.woTitle"
-                  @click="RowlaunchTitle(scope.row)"
-                  style="cursor: pointer; color: blue"
-                  >{{ scope.row.woTitle }}</span
-                >
+                <span :title="scope.row.woTitle" @click="RowlaunchTitle(scope.row)"
+                  style="cursor: pointer; color: blue">{{ scope.row.woTitle }}</span>
               </template>
             </el-table-column>
-            <el-table-column
-              prop="procName"
-              label="流程名称"
-              align="center"
-              :show-overflow-tooltip="true"
-            >
+            <el-table-column prop="procName" label="流程名称" align="center" :show-overflow-tooltip="true">
               <template slot-scope="scope">
                 <span :title="scope.row.procName">{{
-                  scope.row.procName
+                    scope.row.procName
                 }}</span>
               </template>
             </el-table-column>
 
-            <el-table-column
-              prop="createTime"
-              label="发起时间"
+            <el-table-column prop="createTime" label="发起时间" align="center" width="180">
+              <template slot-scope="scope">
+                <span>{{ scope.row.createTime }}</span>
+              </template>
+            </el-table-column>
+             <el-table-column 
               align="center"
-              width="180"
+              width="80"
+              label="操作"
             >
               <template slot-scope="scope">
-                <span>{{ scope.row.createTime }}</span>
+                <el-button
+                  size="mini"
+                  
+                  :disabled="scope.row.flag == '1' ? true : false"
+                  @click="handleEdit(scope.$index, scope.row)">催办</el-button>
+                
               </template>
             </el-table-column>
+
           </el-table>
-          <el-pagination
-            class="pageBox"
-            @current-change="currchangeOp"
-            layout="total,prev, pager, next"
-            background
-            :total="totalOp"
-            v-if="tabbox3"
-            :page-size="pagesize"
-          >
+          <!-- <el-pagination class="pageBox" @current-change="currchangeOp" layout="total,prev, pager, next" background
+            :total="totalOp" v-if="tabbox3" page-size="10">
+          </el-pagination> -->
+          <el-pagination @current-change="currchangefaqi" :current-page="faqipage" :page-size="faqisize"
+            layout="total,prev, pager, next" :total="faqitotal" v-if="tabbox3">
           </el-pagination>
         </div>
       </div>
       <!-- 查看待办弹窗 -->
-      <el-dialog
-        title="查看"
-        :visible.sync="WorkOrderStatus"
-        width="50%"
-        :close-on-press-escape="false"
-        :show-close="true"
-        :destroy-on-close="true"
-        :modal-append-to-body="false"
-        :close-on-click-modal="false"
-      >
+      <el-dialog title="查看" :visible.sync="WorkOrderStatus" width="50%" :close-on-press-escape="false"
+        :show-close="true" :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
         <div>
           <el-form :inline="true" :model="StatusList" class="demo-form-inline">
             <el-form-item label="工单标题">
-              <el-input
-                v-model="StatusList.woTitle"
-                placeholder="工单标题"
-                disabled
-              />
+              <el-input v-model="StatusList.woTitle" placeholder="工单标题" disabled />
             </el-form-item>
             <el-form-item label="流程名称">
-              <el-input
-                v-model="StatusList.procName"
-                placeholder="流程名称"
-                disabled
-              />
+              <el-input v-model="StatusList.procName" placeholder="流程名称" disabled />
             </el-form-item>
           </el-form>
           <h3>流程轨迹</h3>
-          <el-table
-            :data="WorkOrderList"
-            style="width: 100%"
-            max-height="350"
-            height="300"
-          >
+          <el-table :data="WorkOrderList" style="width: 100%" max-height="350" height="300">
             <el-table-column prop="createTime" label="节点开始时间" />
             <el-table-column prop="stepName" label="节点名称" width="180" />
             <el-table-column prop="assigneeName" label="处理角色" width="180" />
@@ -317,40 +188,19 @@
         </div>
       </el-dialog>
       <!-- 查看已办弹窗 -->
-      <el-dialog
-        title="查看"
-        :visible.sync="DoneStatus"
-        width="50%"
-        :close-on-press-escape="false"
-        :show-close="true"
-        :destroy-on-close="true"
-        :modal-append-to-body="false"
-        :close-on-click-modal="false"
-      >
+      <el-dialog title="查看" :visible.sync="DoneStatus" width="50%" :close-on-press-escape="false" :show-close="true"
+        :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
         <div>
           <el-form :inline="true" :model="StatusList" class="demo-form-inline">
             <el-form-item label="工单标题">
-              <el-input
-                v-model="StatusList.woTitle"
-                placeholder="工单标题"
-                disabled
-              />
+              <el-input v-model="StatusList.woTitle" placeholder="工单标题" disabled />
             </el-form-item>
             <el-form-item label="流程名称">
-              <el-input
-                v-model="StatusList.procName"
-                placeholder="流程名称"
-                disabled
-              />
+              <el-input v-model="StatusList.procName" placeholder="流程名称" disabled />
             </el-form-item>
           </el-form>
           <h3>流程轨迹</h3>
-          <el-table
-            :data="DoneList"
-            style="width: 100%"
-            max-height="350"
-            height="300"
-          >
+          <el-table :data="DoneList" style="width: 100%" max-height="350" height="300">
             <el-table-column prop="createTime" label="节点开始时间" />
             <el-table-column prop="stepName" label="节点名称" width="180" />
             <el-table-column prop="assigneeName" label="处理角色" width="180" />
@@ -362,40 +212,19 @@
         </div>
       </el-dialog>
       <!-- 查看发起弹窗 -->
-      <el-dialog
-        title="查看"
-        :visible.sync="launchStatus"
-        width="50%"
-        :close-on-press-escape="false"
-        :show-close="true"
-        :destroy-on-close="true"
-        :modal-append-to-body="false"
-        :close-on-click-modal="false"
-      >
+      <el-dialog title="查看" :visible.sync="launchStatus" width="50%" :close-on-press-escape="false" :show-close="true"
+        :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
         <div>
           <el-form :inline="true" :model="StatusList" class="demo-form-inline">
             <el-form-item label="工单标题">
-              <el-input
-                v-model="StatusList.woTitle"
-                placeholder="工单标题"
-                disabled
-              />
+              <el-input v-model="StatusList.woTitle" placeholder="工单标题" disabled />
             </el-form-item>
             <el-form-item label="流程名称">
-              <el-input
-                v-model="StatusList.procName"
-                placeholder="流程名称"
-                disabled
-              />
+              <el-input v-model="StatusList.procName" placeholder="流程名称" disabled />
             </el-form-item>
           </el-form>
           <h3>流程轨迹</h3>
-          <el-table
-            :data="launchList"
-            style="width: 100%"
-            max-height="350"
-            height="300"
-          >
+          <el-table :data="launchList" style="width: 100%" max-height="350" height="300">
             <el-table-column prop="createTime" label="节点开始时间" />
             <el-table-column prop="stepName" label="节点名称" width="180" />
             <el-table-column prop="assigneeName" label="处理角色" width="180" />
@@ -404,25 +233,47 @@
         </div>
       </el-dialog>
       <!-- 处理弹窗 -->
-      <el-dialog
-        title="处理"
-        :visible.sync="WorkOrderStatus1"
-        width="40%"
-        :close-on-press-escape="false"
-        :show-close="true"
-        :destroy-on-close="true"
-        :modal-append-to-body="false"
-        :close-on-click-modal="false"
-      >
+      <el-dialog title="处理" :visible.sync="WorkOrderStatus1" width="40%" :close-on-press-escape="false"
+        :show-close="true" :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
         <div style="height: 450px">
-          <iframe
-            height="100%"
-            width="100%"
-            :src="dialogdiv"
-            frameborder="0"
-          ></iframe>
+          <iframe height="100%" width="100%" :src="dialogdiv" frameborder="0"></iframe>
         </div>
       </el-dialog>
+      <div>
+      <el-dialog title="有您的催办工单" :visible.sync="dialogTableVisible"  :modal="false" >
+        <el-table :data="gridData">
+          <el-table-column property="woTitle" 
+          label="工单标题" width="625" 
+          show-overflow-tooltip=true 
+           >
+           <template slot-scope="scope">
+                <span 
+                  @click="urgedDeal(scope.row)"
+                  :title="scope.row.woTitle"
+                  style="cursor: pointer; color: blue"
+                  >{{ scope.row.woTitle }}</span
+                >
+              </template>
+           </el-table-column>
+          
+          <el-table-column 
+              align="center"
+              width="100"
+              label="操作"
+            >
+            <!-- <el-form-item> -->
+              <template slot-scope="scope">
+                
+                <el-button
+                  size="mini"
+                  @click="handleEdit1(scope.$index, scope.row)">已阅</el-button>
+                
+              </template>
+              <!-- </el-form-item> -->
+            </el-table-column>
+        </el-table>
+      </el-dialog>
+    </div>
     </div>
   </div>
 </template>
@@ -432,6 +283,8 @@ export default {
   // props:["tableDatayj","niticList"],
   data() {
     return {
+      gridData:[],//催办列表
+      dialogTableVisible: false,//催办弹窗是否显示
       tabbox1: true, //待办
       tabbox2: false, //已办
       tabbox3: false, //发起
@@ -457,6 +310,15 @@ export default {
       pageSizeDone: 1,
       pageSizeDdaiban: 1,
       pageSizeOp: 1,
+      daipage: 1, //第几页
+      daisize: 10, //一页多少条
+      daitotal: 0, //总条目数
+      yibanpage: 1, //第几页
+      yibansize: 10, //一页多少条
+      yibantotal: 0, //总条目数
+      faqipage: 1, //第几页
+      faqisize: 10, //一页多少条
+      faqitotal: 0, //总条目数
     };
   },
   methods: {
@@ -471,7 +333,7 @@ export default {
     RowTitle(v) {
       this.StatusList = v;
       console.log(v.actionUrl);
-      if (v.procName) {
+      if (v.taskName) {
         this.WorkOrderStatus = true;
         this.$http({
           url: "/market/cwo/queryProcStepByWono",
@@ -510,7 +372,7 @@ export default {
     RowDoneTitle(v) {
       this.StatusList = v;
       console.log(v.actionUrl);
-      if (v.procName) {
+      if (v.taskName) {
         this.DoneStatus = true;
         this.$http({
           url: "/market/cwo/queryProcStepByWono",
@@ -550,7 +412,7 @@ export default {
     RowlaunchTitle(v) {
       this.StatusList = v;
       console.log(v.actionUrl);
-      if (v.procName) {
+      if (v.taskName) {
         this.launchStatus = true;
         this.$http({
           url: "/market/cwo/queryProcStepByWono",
@@ -564,16 +426,112 @@ export default {
         }).then((res) => {
           this.launchList = res.data;
         });
-      }else {
+      } else {
         this.$router.push(v.actionUrl);
       }
     },
+     //催办按钮
+     handleEdit(index, row) {
+        this.open(row);
+  
+      },
+      //已阅按钮
+     handleEdit1(index, row) {
+        this.haveRead(row);   //点已阅后返回数据给后台
+        
+      },
+      
+    //催办按钮弹窗
+    open(row) {
+        this.$confirm('催办此条工单, 是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          this.urgedDeal(row);
+          
+          this.$message({
+            type: 'success',
+            message: '催办成功!'
+          });
+        }).catch(() => {
+          this.$message({
+            type: 'info',
+            message: '已取消催办'
+          });          
+        });
+      },
+     
+     //催办向后台返回数据
+     urgedDeal(row) {
+      let list = {}
+      list.id = row.id;
+      list.woNo = row.woNo;
+      list.woTitle = row.woTitle;
+      list.nextNo = row.assigneeNo;
+      list.nextName = row.assigneeName;
+      list.sts = row.sts;
+      list.actionUrl = row.actionUrl;
+      console.log(row); 
+        this.$http({
+        url: "/market/remind/add",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+         },
+        data: list,
+      }).then((res) => {
+        
+      });
+     },
+     //已阅向后台返回数据
+     haveRead(row) {
+      let list = {}
+      list.id = row.id;
+      list.woNo = row.woNo;
+      list.woTitle = row.woTitle;
+      list.nextNo = row.assigneeNo;
+      list.nextName = row.assigneeName;
+      list.sts = row.sts;
+      console.log(row); 
+        this.$http({
+        url: "/market/remind/update",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+         },
+        data: list,
+      }).then((res) => {
+        this.popupWindow();
+      });
+     },
 
+      //接收数据判断是否弹窗
+    popupWindow(){
+       this.$http({
+        url: "/market/remind/queryListByNo",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+         },
+        
+      }).then((res) => {
+        console.log(res);
+        console.log(res.data.length);
+        if(res.data.length == 0){
+          this.dialogTableVisible = false;
+        }else{
+          this.dialogTableVisible = true;
+        }
+        this.gridData = res.data
+      });
+    },
     //更多按钮
     more() {
       console.log(11);
     },
 
+
     //待办列表初始化
     daiban(v, n) {
       this.pageSizeDdaiban = n;
@@ -582,12 +540,18 @@ export default {
         method: "post",
         headers: {
           "Content-Type": "application/json",
-          page: '{"pageNo":"' + n + '","pageSize":"10"}',
+          page: '{"pageNo":"' + '1' + '","pageSize":"100"}',
         },
-        data: '{"pageNo":"' + n + '","pageSize":"10"}',
+        data: '{"pageNo":"' + '1' + '","pageSize":"100"}',
       }).then((res) => {
-        this.niticList = res.data.data;
-        this.totalDaiban = res.data.totalRecord;
+       // this.niticList = res.data.data;
+       let data = JSON.parse(JSON.stringify(res.data.data))
+        this.niticList = data.splice(
+          (this.daipage - 1) * this.daisize,
+          this.daisize
+        );
+        this.daitotal = res.data.data.length
+        // this.totalDaiban = res.data.totalRecord;
       });
     },
 
@@ -600,27 +564,38 @@ export default {
         method: "post",
         headers: {
           "Content-Type": "application/json",
-          page: '{"pageNo":"' + n + '","pageSize":"10"}',
+          page: '{"pageNo":"' + '1' + '","pageSize":"100"}',
         },
-        data: '{"pageNo":"' + n + '","pageSize":"10"}',
+        data: '{"pageNo":"' + '1' + '","pageSize":"100"}',
       }).then((res) => {
-        this.tableDatayj = res.data.data;
-        this.totalDone = res.data.totalRecord;
+         // this.tableDatayj = res.data.data;
+        // this.totalDone = res.data.totalRecord;
+        let data = JSON.parse(JSON.stringify(res.data.data))
+        this.tableDatayj = data.splice(
+          (this.yibanpage - 1) * this.yibansize,
+          this.yibansize
+        );
+        this.yibantotal = res.data.data.length
       });
     },
     //待办分页
-    currchangeDdaiban(v) {
-      this.pageSizeDdaiban = v;
+    currchangeDdaiban(val) {
+      console.log("翻页,当前为第几页", val);
+      this.daipage = val;
+      // this.getTabelData2();
+      // this.pageSizeDdaiban = v;
       this.daiban(this.params, this.pageSizeDdaiban);
     },
     //已办分页
-    currchangeDone(v) {
-      this.pageSizeDone = v;
+    currchangeyiban(val) {
+      // this.pageSizeDone = v;
+      this.yibanpage = val;
       this.getListyj(this.params, this.pageSizeDone);
     },
     //发起分页
-    currchangeOp(v) {
-      this.pageSizeOp = v;
+    currchangefaqi(val) {
+      // this.pageSizeOp = v;
+      this.faqipage = val;
       this.getOPlist(this.params, this.pageSizeOp);
     },
     //我的发起列表初始化
@@ -631,12 +606,18 @@ export default {
         method: "post",
         headers: {
           "Content-Type": "application/json",
-          page: '{"pageNo":"' + n + '","pageSize":"10"}',
+          page: '{"pageNo":"' + '1' + '","pageSize":"100"}',
         },
-        data: '{"pageNo":"' + n + '","pageSize":"10"}',
+        data: '{"pageNo":"' + '1' + '","pageSize":"100"}',
       }).then((res) => {
-        this.OpList = res.data.data;
-        this.totalOp = res.data.totalRecord;
+      // this.OpList = res.data.data;
+        // this.totalOp = res.data.totalRecord;
+        let data = JSON.parse(JSON.stringify(res.data.data))
+        this.OpList = data.splice(
+          (this.faqipage - 1) * this.faqisize,
+          this.faqisize
+        );
+        this.faqitotal = res.data.data.length
       });
     },
     tabboxclick1() {
@@ -682,7 +663,9 @@ export default {
     this.getOPlist({}, 1);
     this.userInfo = JSON.parse(window.sessionStorage.userInfo);
   },
-  created() {},
+  created() {
+     this.popupWindow();
+  },
 };
 </script>
 
@@ -694,6 +677,7 @@ export default {
   //     justify-content: end;
   margin-top: 10px;
 }
+
 .taskbox {
   width: 100%;
   display: inline-block;
@@ -711,13 +695,16 @@ export default {
   border-top-left-radius: 5px;
   border-top-right-radius: 5px;
   justify-content: space-between;
+
   .com-table {
     background: "#FaFaFa";
   }
+
   .span {
     float: right;
     color: orange;
   }
+
   .span1 {
     display: inline-block;
     color: blue;
@@ -727,6 +714,7 @@ export default {
     width: 120px;
     border-bottom: 2px solid blue;
   }
+
   .span2 {
     display: inline-block;
     text-align: center;
@@ -734,6 +722,7 @@ export default {
     width: 120px;
     font-weight: 900;
   }
+
   .span3 {
     display: inline-block;
     text-align: center;
@@ -741,6 +730,7 @@ export default {
     width: 120px;
     font-weight: 900;
   }
+
   span {
     cursor: pointer;
   }
@@ -776,6 +766,7 @@ export default {
     margin-left: 20px;
   }
 }
+
 .fatherbox {
   background: #fafafa;
   padding: 10px;
@@ -784,11 +775,13 @@ export default {
   border-bottom-right-radius: 5px;
   width: 100%;
 }
-.pageBox {
-}
+
+.pageBox {}
+
 ::v-deep .gutter {
   background: #fafafa;
 }
+
 ::v-deep .is-scrolling-none {
   background: #fafafa;
 }

+ 1 - 1
src/pages/main/performance/components/dialog.vue

@@ -16,7 +16,7 @@
     <div slot="footer">
       <slot name="footer">
         <el-button @click="handleCancel" size="small">取消</el-button>
-        <el-button @click="handleConfirm" type="primary" size="small" :disabled="this.BtnDisabled"
+        <el-button @click="handleConfirm" type="primary" size="small" :disabled="BtnDisabled"
           >确定</el-button
         >
       </slot>

+ 420 - 0
src/pages/main/processinst/doDistribution.vue

@@ -0,0 +1,420 @@
+<template>
+  <el-dialog title="权限分配" width="90%" top="1%" v-if="visible" :visible.sync="visible"  append-to-body>
+    <el-row :gutter="20">
+      <el-col :span="12">
+        <el-card>
+          <el-button @click="loadSingleBpmn" type="primary">初始化</el-button>
+          <el-table
+            class="mb20"
+            :data="tableData3"
+            :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+
+            border
+            stripe
+            :highlight-current-row="true"
+            style="width: 100%"
+            @cell-click="cellClick"
+          >
+
+            <el-table-column align="center" prop="id" label="ID"></el-table-column>
+            <el-table-column align="center" prop="procdefkey" label="流程定义key"></el-table-column>
+            <el-table-column align="center" prop="procdefname" label="流程定义名称"></el-table-column>
+             <el-table-column align="center" prop="taskdefkey" label="任务key"></el-table-column>
+            <el-table-column align="center" prop="taskname" label="名称"></el-table-column>
+            <el-table-column align="center" prop="usergroup" label="角色"></el-table-column>
+            <el-table-column align="center" prop="candidateids" label="受理人"></el-table-column>
+
+          </el-table>
+        </el-card>
+      </el-col>
+
+      <el-col :span="12">
+        <el-card>
+          <el-button @click="doSure" type="primary">确认分配</el-button>
+          <div style="margin-top: 20px" v-if="comms">
+            <el-radio-group v-model="taskType"  size="small">
+              <el-radio label="1" border>固定受理人(唯一)</el-radio>
+              <el-radio label="2" border>固定候选人(多个)</el-radio>
+              <el-radio label="3" border>固定候选组(多个)</el-radio>
+              <!-- <el-radio label="4" border>动态指定人</el-radio> -->
+            </el-radio-group>
+          </div>
+
+          <el-form class="mt20" :model="model" v-if="taskType==1||taskType==2"  ref="form1" label-width="100px" >
+        <el-row :gutter="20">
+          <el-col :span="16" >
+            <el-form-item  label="审核角色"   prop="data1"  >
+              <el-select  v-model="model.data1" :multiple="taskType==2" @remove-tag ="removeTag"  placeholder="请选择..." @change="role">
+              <el-option
+                    v-for="item in tableData2"
+                    :key="item.id"
+                    :label="item.name"
+                    :value="item.id"
+                  ></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="16">
+            <el-form-item  label="审核人"  prop="nextDealMan">
+              <el-select  v-model="model.nextDealMan"  :multiple="taskType==2"  placeholder="请选择...">
+              <el-option
+                    v-for="item in options2"
+                    :key="item.id"
+                    :label="item.name"
+                    :value="item.id"
+                  ></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+
+
+        </el-row>
+
+      </el-form>
+          <el-table
+            v-if="taskType==4||taskType==3"
+            class="mb20 mt20"
+            :data="tableData2"
+            height="500px"
+            :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+            border
+            stripe
+            ref="roleTable"
+
+            :highlight-current-row="true"
+            style="width: 100%"
+          >
+            <el-table-column align="center" type="selection" width="55"></el-table-column>
+
+            <el-table-column align="center" prop="code" label="角色ID"></el-table-column>
+            <el-table-column align="center" prop="name" label="角色名称"></el-table-column>
+            <!-- <el-table-column align="center" prop="org" label="所属部门"></el-table-column> -->
+            <el-table-column align="center" prop="description" label="角色描述"></el-table-column>
+            <el-table-column align="center" prop="locked" label="角色状态">
+              <template slot-scope="scope">
+                <el-tag type="success" v-show="!scope.row.locked">启用</el-tag>
+                <el-tag type="danger" v-show="scope.row.locked">停用</el-tag>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-card>
+      </el-col>
+    </el-row>
+    <span slot="footer" class="dialog-footer">
+      <!-- <el-button type="primary" @click="doAprove()">确认</el-button> -->
+      <el-button @click="visible = false">关闭</el-button>
+    </span>
+  </el-dialog>
+</template>
+
+<script>
+// import moment from 'moment';
+// //import util from '@/util'
+export default {
+  data() {
+    return {
+      selectIndex:null,
+      comms:false,
+      items: [],
+      visible: false,
+      pageTotal: 0,
+      candidateids:"",
+      gid:null,
+      procdefkey: null,
+      taskType:'4',
+      processDefinitionId: null,
+      usergroup:"",
+      model:{
+        data1:'',
+        nextDealMan:[]
+      },
+      form: {
+        name: "",
+        pageNum: "1",
+        pageSize: "9999"
+      },
+      tableData3: [
+
+      ],
+      tableData2: [],
+      selectedRows: []
+    };
+  },
+  created() {},
+  watch:{
+    taskType(value){
+       var str = ''
+
+      if(value==1){
+        str = this.tableData2[0].id;
+      }else if(value==2){
+        str = [this.tableData2[0].id];
+        this.model.nextDealMan = [];
+      } else{
+        return false;
+      }
+
+      this.model.data1 = str
+      this.role(str)
+
+    }
+  },
+  methods: {
+    init(key, id) {
+      this.visible = true;
+
+      this.procdefkey = key;
+      this.processDefinitionId = id;
+      this.doSearch();
+    },
+
+    changeFun(){
+        var arr = [];
+
+
+        if(this.taskType==1){
+          this.candidateids = this.model.nextDealMan;
+        }else if(this.taskType==2){
+          this.candidateids = this.model.nextDealMan.join(",");
+        }else if(this.taskType==3){
+          let val = this.$refs.roleTable.selection;
+          val.forEach((element)=>{
+              arr.push(element.id)
+          })
+          this.candidateids = this.usergroup = arr.join(",");
+        }else if(this.taskType==4){
+          let val = this.$refs.roleTable.selection;
+          val.forEach((element)=>{
+              arr.push(element.id)
+          })
+          this.candidateids = this.usergroup = arr.join(",");
+        }
+    },
+    doSearch() {
+      let self = this;
+      var obj = {
+        url: this.$url.processinst.getUserTaskList,
+        data: {
+          procdefkey: this.procdefkey
+        }
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+        console.log(data)
+        if(data.data.length==0){
+           self.loadSingleBpmn();
+        }else{
+          if(data.data[0].taskdefkey.indexOf("multiNext")!=-1){
+            self.comms = true;
+            self.taskType='3';
+          }else{
+            self.comms = false;
+            self.taskType='4';
+            self.tableData3 = data.data;
+            self.gid = data.data[0].id;
+            self.usergroup = data.data[0].usergroup
+            self.doSearchRole(1);
+          }
+        }
+      }
+    },
+    doSearchRole(value) {
+      this.form.pageNum = value;
+
+      let self = this;
+      // var obj = {
+      //   url: this.$url.roleManag.getList,
+      //   data: this.form
+      // };
+      // this.common.httpPost(obj, success);
+      // function success(data) {
+      //   self.tableData2 = data.rows;
+      //   if(self.taskType==2){
+      //     self.model.data1 = [data.rows[0].id];
+      //   }else{
+      //     self.model.data1 = data.rows[0].id;
+      //   }
+
+      //   self.cheacked();
+      // }
+       this.$http({
+          url: this.$url.roleManag.getList,
+          method: "post",
+          headers: {
+              "Content-Type": "application/json",
+          },
+          data: this.form,
+      }).then((res) => {
+        console.log(res.data.data);
+        self.tableData2 = res.data.data.rows;
+        if(self.taskType==2){
+          self.model.data1 = [res.data.data.rows[0].id];
+        }else{
+          self.model.data1 = res.data.data.rows[0].id;
+        }
+
+        self.cheacked();
+      });
+    },
+    loadSingleBpmn() {
+      let self = this;
+      var obj = {
+        url: this.$url.processinst.loadSingleBpmn,
+        data: {
+          processDefinitionId: this.processDefinitionId
+        }
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+        self.doSearch();
+      }
+    },
+    doSure(){
+
+
+      this.changeFun();
+
+      let self = this;
+      var oob = {
+          id: this.gid,
+          tasktype:this.taskType,
+
+      }
+      if(this.taskType==4){
+        oob.usergroup=this.usergroup
+      }else if(this.taskType==3){
+        oob.candidateids=this.usergroup
+      }else{
+        oob.candidateids = this.candidateids
+      }
+      var obj = {
+        url: this.$url.processinst.setPermission,
+
+        data: oob
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+         self.$message({
+             message:"已分配",
+             type:"success"
+         })
+         self.doSearch();
+      }
+    },
+    cheacked(){
+
+        let self = this;
+        try {
+          self.$refs.roleTable.clearSelection();
+
+        } catch (error) {
+
+        }
+        if(!this.usergroup){
+          return false;
+        }
+        let arr = this.usergroup.split(",");
+        let arr1 = []
+        this.tableData2.forEach((elment,index)=>{
+          arr.forEach((i,o)=>{
+
+            if(elment.id==i){
+              arr1.push(index)
+            }
+          })
+
+        })
+        this.$nextTick(function () {
+
+          // if(arr1.length==0){
+          // }else{
+
+            arr1.forEach((ob)=>{
+              self.$refs.roleTable.toggleRowSelection(self.tableData2[ob],true);
+            })
+          // }
+        })
+    },
+    cellClick(row){
+
+      if(row.taskdefkey.indexOf("multiNext")!=-1){
+        this.comms = true;
+        if(row.taskType){
+
+          this.taskType=row.tasktype;
+        }else{
+          this.taskType = '1';
+        }
+      }else{
+         this.comms = false;
+          this.taskType = '4';
+
+
+      }
+
+      this.usergroup = row.usergroup;
+      this.gid = row.id;
+      this.cheacked();
+    },
+    role(row){
+      var str = ''
+
+        if(typeof row =="object"){
+          if(row.length==0){
+            return false;
+          }
+          str = row.join(",");
+        }else{
+          if(!row){
+            return false;
+          }
+          str = String(row)
+        }
+
+        let self = this;
+        let obj = {
+          roleId:str,
+          excludeMeWhenSelectNextHandler:self.common.excludeMeWhenSelectNextHandler,
+          excludeFormerHanlder:self.common.excludeMeWhenSelectNextHandler,
+          procinstid:self.procinstid
+        };
+       this.common.selectInit(this.$url.activeti.getUsersByRoleIds,success,obj,'options2');
+       function success(data,str){
+         self.$nextTick(()=>{
+
+            if( self.taskType==2){
+              self.nextDeal(data[0].id);
+            }else{
+
+              self.model.nextDealMan = data[0].id;
+            }
+            self[str] = data;
+         })
+
+      }
+    },
+    nextDeal(id){
+
+     if( typeof this.model.nextDealMan!="object"){
+       this.model.nextDealMan = [];
+     }
+     if(this.model.nextDealMan.length>0){
+
+       var tag = this.model.nextDealMan.find(i=>{
+           return i == id;
+         })
+         if(!tag){
+           this.model.nextDealMan.push(id);
+         }
+     }else{
+       this.model.nextDealMan.push(id);
+     }
+    },
+  }
+};
+</script>
+<style >
+ .mt20{
+   margin-top: 20px;
+ }
+</style>

+ 149 - 0
src/pages/main/processinst/index.vue

@@ -0,0 +1,149 @@
+<template>
+    <div class="container">
+        <div class="mod-role" style="height:100%;overflow:auto;">
+            <el-form :inline="true" @submit.native.prevent @keyup.enter.native="loadProcessDefList(1)" style="margin:20px 0px 0px 10px">
+                <el-form-item>
+                    <el-input v-model="form.searchKey" placeholder="流程定义key" clearable></el-input>
+                </el-form-item>
+                <el-form-item>
+                    <el-button icon="el-icon-search" type="search" @click="loadProcessDefList(1)">查询</el-button>
+                    <!-- <el-button icon="el-icon-search" type="search" @click="loadProcessDefList(1)">流程导入</el-button> -->
+                    <!-- <el-button icon="el-icon-upload2" type="primary" @click="doImport()">导入</el-button> -->
+                </el-form-item>
+            </el-form>
+            <el-table  @selection-change="handleSelectionChange" :data="list" border v-loading="loading">
+                <el-table-column align="center" prop="key" label="流程定义key"></el-table-column>
+                <el-table-column align="center" prop="name" label="流程名称"></el-table-column>
+
+                <el-table-column align="center" prop="deploymentTime" :formatter="$util.YYMM" label="部署时间"></el-table-column>
+                <el-table-column align="center" prop="diagramResourceName" label="资源名称"></el-table-column>
+
+                <el-table-column align="center" prop="version" label="版本" width="55"></el-table-column>
+                <el-table-column align="center" prop="deploymentId" label="部署ID"></el-table-column>
+                <el-table-column align="center" prop="id" label="流程定义ID"></el-table-column>
+                <el-table-column align="center" label="操作" fixed="left" width="250">
+                    <template slot-scope="scope">
+                        <!-- <el-button @click="doStart(scope)" type="text" size="small">启动</el-button> -->
+                        <el-button @click="doView(scope)" type="text" size="small">查看流程图</el-button>
+                        <el-button @click="doDistribution(scope.row)" type="text" size="small">分配权限</el-button>
+                        <el-button @click="doEexport(scope.row)" type="text" size="small">流程导出</el-button>
+                        <!-- <el-button @click="doCopy(scope)" type="text" size="small"></el-button> -->
+                        <!-- <el-button @click="doDesign(scope)" type="text" size="small">待办</el-button>
+            <el-button @click="doDeploy(scope)" type="text" size="small">跳转</el-button>-->
+                    </template>
+                </el-table-column>
+            </el-table>
+            <el-pagination style="margin:10px 10px 0px 10px;float:right" @current-change="loadProcessDefList"  :page-size="form.rows" layout="total, prev, pager, next, jumper" :total="total"></el-pagination>
+
+            <so-distribution v-if="soDistributionVisible" ref="soDistribution"  ></so-distribution>
+            <el-dialog title="查看" v-if="editFormVisible" :visible.sync="editFormVisible" width="80%" style="text-align:center"  append-to-body>
+                <div>
+                    <img :src="viewImg" alt />
+                </div>
+                <span slot="footer" class="dialog-footer">
+                    <el-button type="primary" @click="editFormVisible = false">确 定</el-button>
+                </span>
+            </el-dialog>
+        </div>
+    </div>
+</template>
+<script>
+// import UserOpenDialog from '@/page/components/userOpenDialog'
+import WfActivitySelect from './wfActivitySelect'
+import SoDistribution from './doDistribution'
+export default {
+    data() {
+        return {
+            multipleSelection: [],
+            loading:false,
+            editFormVisible: false,
+            soDistributionVisible: false,
+            checkededRows: [],
+            list: null,
+            viewImg: null,
+            processDefinationlist: [{}, {}],
+            startDateRange: null,
+            total: 0,
+            form: {
+                page: 1,
+                rows: 10,
+                searchKey: ''
+            },
+            importFormVisible: false
+        }
+    },
+    components: {
+        SoDistribution,
+        WfActivitySelect,
+    },
+    mounted() {
+        this.loadProcessDefList(1)
+    },
+    methods: {
+        handleSelectionChange(val){
+            this.multipleSelection = val;
+        },
+        onGotoDialogSelect(){
+
+        },
+        loadProcessDefList(value) {
+            this.importFormVisible = false
+            let self = this
+            this.form.page = value
+            console.log(this.form)
+            var obj = {
+                url: this.$url.processinst.getList,
+                data: this.form,
+                type: 'post'
+            }
+            this.common.httpPost(obj, success)
+            function success(data) {
+                self.list = data.data.rows
+                self.total = data.data.total
+            }
+            // tapp.services.wf_Model.getMadelList().then(function(result) {
+            //   self.processDefinationlist = result;
+            // })
+        },
+        onStartDateRangeChanged(val) {
+            this.form.startDateBegin = val[0]
+            this.form.startDateEnd = val[1]
+        },
+        //  流程导出
+        doEexport(row) {
+            console.log(`${this.$url.processinst.getExportFile}/${row.id}`)
+            window.location.href = `${this.$url.processinst.getExportFile}/${row.id}`
+        },
+        doTask(key, row) {
+            if (row.taskAssignee != null && row.taskAssignee.length > 0) {
+                //办理
+                this.$router.push({
+                    path: row.taskFormUrl
+                })
+                return
+            } else if (row.taskCandidate != null && row.taskCandidate.length > 0) {
+            } else {
+            }
+        },
+
+        doDistribution(row) {
+            this.soDistributionVisible = true
+            this.$nextTick(() => {
+                this.$refs.soDistribution.init(row.key, row.id)
+            })
+        },
+
+        doView(scope) {
+            this.editFormVisible = true
+            let row = scope.row
+            let self = this
+            this.viewImg = this.$url.processinst.view + '?resourceType=png&processDefinitionId=' + row.id
+        }
+    }
+}
+</script>
+<style lang="scss" scoped>
+::v-deep .el-table td, .el-table th{
+    padding: 3px 0px;
+}
+</style>

+ 30 - 0
src/pages/main/processinst/processHistory.vue

@@ -0,0 +1,30 @@
+
+<template>
+<div>
+  <wf-processtrack ref="processtrack" :procInstId="procInstId">
+  </wf-processtrack> 
+</div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      procInstId: null,
+    }
+  },
+  components: {},
+  created() {
+    this.procInstId = this.$route.query.procInstId;
+  },
+  activated() {
+
+  },
+  computed: {
+
+  },
+  methods: {
+
+  }
+}
+</script>

+ 64 - 0
src/pages/main/processinst/wfActivitySelect.vue

@@ -0,0 +1,64 @@
+
+<template>
+<el-dialog title="流程节点信息" v-if="visible" :visible.sync="visible" :append-to-body="true">
+  <el-form ref="form" @submit.native.prevent  @keyup.enter.native="dataFormSubmit()" label-width="80px">
+    <el-form-item label="流程节点">
+      <el-select filterable  placeholder="流程节点" v-model="selectedActivityId">
+        <el-option v-for="(item, index) in activitylist" :key='item.id' :label="item.name" :value="item.id"></el-option>
+      </el-select>
+    </el-form-item>
+  </el-form>
+  <span slot="footer" class="dialog-footer">
+      <el-button type="primary" @click="onOk()">确定</el-button>
+      <el-button @click="visible = false">关闭</el-button>
+    </span>
+</el-dialog>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      visible: false, title:"添加",
+      disabled:false,
+      btn:"提交",
+      aproveVisible: false,
+      processDefinationKey: null,
+      activitylist: {},
+      selectedActivityId: null,
+    }
+  },
+  created() {
+
+  },
+  activated() {
+
+  },
+  methods: {
+    // 初始化
+    init(processDefinationKey) {
+      this.visible = true
+      this.processDefinationKey = processDefinationKey;
+      let self = this;
+      // tapp.services.wf_Model.getProcessActivities(this.processDefinationKey).then(function(result) {
+      //   self.activitylist = result.filter(p => {
+      //     return p.implementation != undefined || p.assignee != undefined
+      //   });
+
+      // });
+    },
+    onOk() {
+      let self = this;
+      if (!this.selectedActivityId) {
+        self.$notify.error({
+          title: '错误',
+          message: '未选择流程节点!'
+        });
+        return false;
+      }
+      this.visible = false;
+      this.$emit('select', this.selectedActivityId);
+    },
+  }
+}
+</script>

+ 248 - 0
src/pages/main/processruns/doDistribution.vue

@@ -0,0 +1,248 @@
+<template>
+  <el-dialog title="权限分配" width="90%" top="1%" v-if="visible" :visible.sync="visible">
+    <el-row :gutter="20">
+      <el-col :span="12">
+        <el-card>
+          <el-button @click="loadSingleBpmn" type="primary">初始化</el-button>
+          <el-table
+            class="mb20"
+            :data="tableData3"
+            :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+            cell-click="cellClick"
+            border
+            stripe
+            highlight-current-row="true"
+            style="width: 100%"
+            @cell-click="cellClick"
+          >
+
+            <el-table-column align="center" prop="id" label="ID"></el-table-column>
+            <el-table-column align="center" prop="procdefkey" label="流程定义key"></el-table-column>
+            <el-table-column align="center" prop="procdefname" label="流程定义名称"></el-table-column>
+             <el-table-column align="center" prop="taskdefkey" label="任务key"></el-table-column>
+            <el-table-column align="center" prop="taskname" label="名称"></el-table-column>
+            <el-table-column align="center" prop="usergroup" label="角色"></el-table-column>
+
+          </el-table>
+        </el-card>
+      </el-col>
+
+      <el-col :span="12">
+        <el-card>
+          <el-button @click="doSure" type="primary">确认分配</el-button>
+ <!-- @selection-change="changeFun" -->
+          <el-table
+            class="mb20"
+            :data="tableData2"
+            height="500px"
+            :header-cell-style="{background:'#e0f3ff',color:'#5f95b7'}"
+            border
+            stripe
+            ref="roleTable"
+
+            highlight-current-row="true"
+            style="width: 100%"
+          >
+            <el-table-column align="center" type="selection" width="55"></el-table-column>
+
+            <el-table-column align="center" prop="code" label="角色ID"></el-table-column>
+            <el-table-column align="center" prop="name" label="角色名称"></el-table-column>
+            <el-table-column align="center" prop="org" label="所属部门"></el-table-column>
+            <el-table-column align="center" prop="description" label="角色描述"></el-table-column>
+            <el-table-column align="center" prop="locked" label="角色状态">
+              <template slot-scope="scope">
+                <el-tag type="success" v-show="!scope.row.locked">启用</el-tag>
+                <el-tag type="danger" v-show="scope.row.locked">停用</el-tag>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-card>
+      </el-col>
+    </el-row>
+    <span slot="footer" class="dialog-footer">
+      <!-- <el-button type="primary" @click="doAprove()">确认</el-button> -->
+      <el-button @click="visible = false">关闭</el-button>
+    </span>
+  </el-dialog>
+</template>
+
+<script>
+// import moment from 'moment';
+// //import util from '@/util'
+export default {
+  data() {
+    return {
+      selectIndex:null,
+      items: [],
+      visible: false,
+      pageTotal: 0,
+      gid:null,
+      procdefkey: null,
+      processDefinitionId: null,
+      usergroup:"",
+      form: {
+        name: "",
+        pageNum: "1",
+        pageSize: "9999"
+      },
+      tableData3: [
+        {
+          date: "2016-05-03",
+          name: "王小虎",
+          address: "上海市普陀区金沙"
+        }
+      ],
+      tableData2: [],
+      selectedRows: []
+    };
+  },
+  created() {},
+  methods: {
+    init(key, id) {
+      this.visible = true;
+
+      this.procdefkey = key;
+      this.processDefinitionId = id;
+      this.doSearch();
+    },
+
+    cellClick(row, column, cell, event) {
+      // let self = this;
+      // var obj ={
+      //   url:this.$url.workflowdef.getList,
+      //   data:this.form
+      // }
+      // this.common.httpPost(obj,success);
+      // function success(data){
+      //     self.list = data.data.rows
+      //     self.total = data.data.total
+      // }
+    },
+    changeFun(){
+        var arr = [];
+        let val = this.$refs.roleTable.selection;
+        val.forEach((element)=>{
+            arr.push(element.id)
+        })
+        this.usergroup = arr.join(",")
+    },
+    doSearch() {
+      let self = this;
+      var obj = {
+        url: this.$url.processinst.getUserTaskList,
+        data: {
+          procdefkey: this.procdefkey
+        }
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+        if(data.data.length==0){
+           self.loadSingleBpmn();
+        }else{
+
+          self.tableData3 = data.data;
+          self.gid = data.data[0].id;
+          self.usergroup = data.data[0].usergroup
+          self.doSearchRole(1);
+        }
+      }
+    },
+    doSearchRole(value) {
+      this.form.pageNum = value;
+
+      let self = this;
+      // var obj = {
+      //   url: this.$url.roleManag.getList,
+      //   data: this.form
+      // };
+      // this.common.httpPost(obj, success);
+      // function success(data) {
+      //   self.tableData2 = data.rows;
+      //   self.cheacked();
+      // }
+      this.$http({
+          url: this.$url.roleManag.getList,
+          method: "post",
+          headers: {
+              "Content-Type": "application/json",
+          },
+          data: this.form,
+      }).then((res) => {
+          self.tableData2 =  res.data.rows;
+          self.cheacked();
+      });
+    },
+    loadSingleBpmn() {
+      let self = this;
+      var obj = {
+        url: this.$url.processinst.loadSingleBpmn,
+        data: {
+          processDefinitionId: this.processDefinitionId
+        }
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+        self.doSearch();
+      }
+    },
+    doSure(){
+
+
+      this.changeFun();
+
+        let self = this;
+        console.log(this.gid)
+      var obj = {
+        url: this.$url.processinst.setPermission,
+
+        data: {
+          id: this.gid,
+          usergroup:this.usergroup
+        }
+      };
+      this.common.httpPost(obj, success);
+      function success(data) {
+         self.$message({
+             message:"已分配",
+             type:"success"
+         })
+         self.doSearch();
+      }
+    },
+    cheacked(){
+
+        let self = this;
+        self.$refs.roleTable.clearSelection();
+        if(!this.usergroup){
+          return false;
+        }
+        let arr = this.usergroup.split(",");
+        let arr1 = []
+        this.tableData2.forEach((elment,index)=>{
+          arr.forEach((i,o)=>{
+
+            if(elment.id==i){
+              arr1.push(index)
+            }
+          })
+
+        })
+        this.$nextTick(function () {
+
+          // if(arr1.length==0){
+          // }else{
+
+            arr1.forEach((ob)=>{
+              self.$refs.roleTable.toggleRowSelection(self.tableData2[ob],true);
+            })
+          // }
+        })
+    },
+    cellClick(row){
+      this.usergroup = row.usergroup;
+      this.gid = row.id;
+      this.cheacked();
+    }
+  }
+};
+</script>

+ 30 - 0
src/pages/main/processruns/processHistory.vue

@@ -0,0 +1,30 @@
+
+<template>
+<div>
+  <wf-processtrack ref="processtrack" :procInstId="procInstId">
+  </wf-processtrack> 
+</div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      procInstId: null,
+    }
+  },
+  components: {},
+  created() {
+    this.procInstId = this.$route.query.procInstId;
+  },
+  activated() {
+
+  },
+  computed: {
+
+  },
+  methods: {
+
+  }
+}
+</script>

+ 326 - 0
src/pages/main/processruns/processruns.vue

@@ -0,0 +1,326 @@
+<template>
+    <div class="container">
+        <div class="mod-role" style="height:100%;overflow:auto;">
+            <el-form :inline="true" @submit.native.prevent @keyup.enter.native="loadProcessDefList(1)" style="margin:20px 0px 0px 10px">
+                <el-form-item>
+                    <el-input v-model="form.procdefkey" placeholder="流程定义key" clearable></el-input>
+                </el-form-item>
+                  <el-form-item>
+                    <el-input v-model="form.processInstanceId" placeholder="实例ID" clearable></el-input>
+                </el-form-item>
+                <el-form-item>
+                    <el-button icon="el-icon-search" type="search" @click="loadProcessDefList(1)">查询</el-button>
+                </el-form-item>
+                <el-form-item>
+                    <el-button icon="el-icon-position" type="search" @click="doView()">重发待办</el-button>
+                </el-form-item>
+                <el-form-item>
+                    <el-button icon="el-icon-refresh-left" type="search" @click="doRecall()">召回</el-button>
+                </el-form-item>
+            </el-form>
+
+            <el-table :data="list" border  v-loading="loading" style="width: 100%">
+                <!-- <el-table-column align="center" label="选择" :selectable="chkstu" width="80" type="selection"></el-table-column> -->
+                <el-table-column type="expand">
+                    <template slot-scope="props">
+                        <el-table @selection-change="checkedChange" @select="select" ref="multipleTable" @select-all="selectAll" :data="props.row.taskList" :header-cell-style="{ background: '#e0f3ff', color: '#5f95b7' }" border stripe highlight-current-row="true" style="width: 100%">
+                            <!-- :selectable="chkstu" 禁止选用-->
+                            <el-table-column align="center" label="选择"  width="80" type="selection"></el-table-column>
+                            <el-table-column align="center" prop="taskId" label="任务id"></el-table-column>
+                            <el-table-column align="center" prop="taskName" label="名称"></el-table-column>
+                            <el-table-column align="center" prop="userName" label="任务处理人"></el-table-column>
+                            <el-table-column align="center" prop="assignee" label="任务处理人id"></el-table-column>
+                        </el-table>
+                    </template>
+                </el-table-column>
+                <el-table-column align="center" prop="processInstanceId" label="实例ID"></el-table-column>
+                <el-table-column align="center" prop="processDefinitionKey" label="流程定义key"></el-table-column>
+                <el-table-column align="center" prop="processDefinitionId" label="流程定义id"></el-table-column>
+
+                <el-table-column align="center" prop="processDefinitionName" label="流程名称"></el-table-column>
+            </el-table>
+            <el-pagination style="margin:10px 10px 0px 10px;float:right" @current-change="loadProcessDefList"  :page-size="form.rows" layout="total, prev, pager, next, jumper" :total="total"></el-pagination>
+
+            <so-distribution v-if="soDistributionVisible" ref="soDistribution" @select="onGotoDialogSelect"></so-distribution>
+            <el-dialog title="重发代办" v-if="editFormVisible" :visible.sync="editFormVisible" width="40%" @close="closeEliminateData" style="text-align:left">
+                <div style="padding:20px">
+                    <el-form label-position="left" label-width="80px" :inline="true" @submit.native.prevent @keyup.enter.native="doSearch(1)">
+                        <el-row>
+                            <el-col :span="24">
+                                <el-form-item label="处理节点:">
+                                    {{ taskname }}
+                                </el-form-item>
+                            </el-col>
+                            <el-col :span="24">
+                                <el-form-item label="审核角色:">
+                                    <el-select v-model="userRole" @change="changeUser" placeholder="请选择...">
+                                        <el-option v-for="item in userArr" :key="item.id" :label="item.name" :value="item.id"> </el-option>
+                                    </el-select>
+                                </el-form-item>
+                            </el-col>
+                            <el-col :span="24">
+                                <el-form-item label="审核人:">
+                                    <el-select v-model="userMan" @change="userIdchange" placeholder="请选择...">
+                                        <el-option v-for="item in userArr1" :key="item.id" :label="item.name" :value="item.id"> </el-option>
+                                    </el-select>
+                                </el-form-item>
+                            </el-col>
+                        </el-row>
+                    </el-form>
+                </div>
+                <span slot="footer" class="dialog-footer">
+                    <el-button type="primary" @click="addSend">确 定</el-button>
+                </span>
+            </el-dialog>
+        </div>
+    </div>
+</template>
+<script>
+// import UserOpenDialog from '@/page/components/userOpenDialog'
+import WfActivitySelect from './wfActivitySelect'
+import SoDistribution from './doDistribution'
+import { processDefinitionKey as getService } from '@/components/components/approvalDialog/index-mixins.js'
+export default {
+  data() {
+    return {
+      loading:false,
+      editFormVisible: false,
+      soDistributionVisible: false,
+      checkededRows: [],
+      list: null,
+      viewImg: null,
+      processDefinationlist: [{}, {}],
+      startDateRange: null,
+      total: 0,
+      form: {
+        page: 1,
+        rows: 10,
+        procdefkey: '',
+        processInstanceId: ''
+      },
+      tableData3: [],
+      userId: '',
+      userArr: [],
+      userArr1: [],
+      userRole: '', //审核角色
+      userMan: '',
+      taskname: '',
+
+      taskId: '',
+      userId: '',
+      // 上一个选中的表格组件
+      previousTableCom: null
+      // activeti.getUsersByRoleIds
+    }
+  },
+  components: {
+    SoDistribution,
+    WfActivitySelect
+  },
+  mounted() {
+    this.loadProcessDefList(1)
+  },
+  methods: {
+    loadProcessDefList(value) {
+      let self = this
+      this.form.page = value
+
+      var obj = {
+        url: this.$url.workflowdef.getruns,
+        data: this.form,
+        type: 'post'
+      }
+      this.common.httpPost(obj, success)
+      function success(data) {
+        data.data.rows.forEach(el => {
+          el.taskList.forEach(element => {
+            element.processDefinitionKey = el.processDefinitionKey
+          })
+        })
+        self.list = data.data.rows
+        self.list.forEach(el => {
+          el.taskList.map(item => {
+            item.processInstanceId = el.processInstanceId
+            item.processDefinitionKey = el.processDefinitionKey
+          })
+        })
+        self.total = data.data.total
+      }
+    },
+    onStartDateRangeChanged(val) {
+      this.form.startDateBegin = val[0]
+      this.form.startDateEnd = val[1]
+    },
+    chkstu(row, index) {
+      return row.assignee ? false : true
+    },
+    // 禁用全选按钮
+    selectAll() {
+      this.$refs.multipleTable.clearSelection()
+    },
+    async addSend() {
+      // console.log(this.userId)
+      // console.log(this.taskId)
+      if (!(this.userId && this.taskId)) return this.$message.error('请选择审核角色或审核人!')
+      var obj = {
+        url: this.$url.processinst.setPermission1,
+        data: {
+          userId: this.userId + '',
+          taskId: this.taskId
+        }
+      }
+      const { data: res } = await this.common.postRequest(obj)
+      // console.log(res)
+      if (res.code !== 1) return this.$message.error(res.message)
+      this.$message.success(res.message)
+      this.editFormVisible = false
+      this.loadProcessDefList(1)
+    },
+    // 召回
+    doRecall() {
+      if (!(this.deleteList && this.deleteList.length > 0)) return this.$message.error('选择要召回的待办!')
+      this.$confirm('此操作将把待办召回, 是否继续?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      })
+        .then(async () => {
+            console.log( this.deleteList[0]);
+          let { businessKey, processInstanceId } = this.deleteList[0]
+          let service = getService(this.deleteList[0].processDefinitionKey, true)
+          let url = eval('`' + this.$url.activeti.recallProcess + '`')
+          console.log(this.deleteList[0])
+
+          let obj = {
+            url,
+            data: {
+              id: businessKey,
+              processInstanceId
+            }
+          }
+          const res = await this.common.postRequest(obj)
+          if (res.code !== '1') return this.$message.error('召回失败!')
+          this.$message.success('召回成功!')
+          this.loadProcessDefList(1)
+        })
+        .catch(err => {
+          this.$message({
+            type: 'info',
+            message: '已取消召回!'
+          })
+        })
+    },
+    // 只能选择一个
+    select(selection, row) {
+      // console.log(this.$refs.multipleTable)
+      // console.log('---------------')
+      // if (this.previousTableCom) {
+      //     this.previousTableCom.clearSelection()
+      // }
+      // this.previousTableCom = this.$refs.multipleTable
+      // console.log('当用户手动勾选数据行的 Checkbox 时触发的事件', selection, row)
+
+      // 选择项大于1时
+
+      if (selection.length > 1) {
+        let del_row = selection.shift()
+
+        // console.log('把数组的第一个元素从其中删除后', selection);
+
+        this.$refs.multipleTable.toggleRowSelection(del_row, false) // 用于多选表格,切换某一行的选中状态,如果使用了第二个参数,则是设置这一行选中与否(selected 为 true 则选中)
+      }
+    },
+    userIdchange(value) {
+      this.userId = value
+      // console.log(this.taskId)
+      // console.log(this.userId)
+    },
+    // 关闭事件
+    closeEliminateData() {
+      // this.taskId = ''
+      this.userArr = []
+      this.userArr1 = []
+      this.userRole = ''
+      this.userMan = ''
+      this.userId = ''
+      this.taskname = ''
+    },
+    doTask(key, row) {
+      if (row.taskAssignee != null && row.taskAssignee.length > 0) {
+        //办理
+        this.$router.push({
+          path: row.taskFormUrl
+        })
+        return
+      } else if (row.taskCandidate != null && row.taskCandidate.length > 0) {
+      } else {
+      }
+    },
+
+    doDistribution(row) {
+      this.soDistributionVisible = true
+      this.$nextTick(() => {
+        this.$refs.soDistribution.init(row.key, row.id)
+      })
+    },
+
+    async doView() {
+      // this.userArr = []
+      // this.userArr1 = []
+
+      // this.userId = ''
+      if (!(this.deleteList && this.deleteList.length > 0)) return this.$message.error('选择要发起的流程!')
+      this.editFormVisible = true
+      var obj = {
+        url: this.$url.processinst.getUserTask,
+        data: {
+          procdefkey: this.deleteList[0].processDefinitionKey,
+          taskdefkey: this.deleteList[0].taskDefinitionKey
+        }
+      }
+      const { data: res } = await this.common.postRequest(obj)
+      if (res.code !== 1) return this.$message.error(res.message)
+      this.taskname = res.data[0].taskname
+      let arrTemp = res.data[0].usergroup ? res.data[0].usergroup.split(',') : []
+      if (arrTemp.length > 0) {
+        arrTemp.forEach(id => {
+          this.getuser_info(id)
+        })
+      }
+    },
+    async getuser_info(id) {
+      var obj = {
+        url: this.$url.roleManag.getById,
+        data: {
+          id
+        }
+      }
+      const { data: res } = await this.common.postRequest(obj)
+      this.userArr.push(res)
+    },
+
+    checkedChange(value) {
+      console.log(value)
+      if (value.length > 0) {
+        this.taskId = value[0].taskId
+        this.deleteList = value
+      } else {
+        this.deleteList = value
+      }
+    },
+    // 选择角色事件
+    async changeUser(value) {
+      var obj = {
+        url: this.$url.activeti.getUsersByRoleIds,
+        data: {
+          excludeMeWhenSelectNextHandler: this.common.excludeMeWhenSelectNextHandler,
+          excludeFormerHanlder: this.common.excludeMeWhenSelectNextHandler,
+          roleId: value + ''
+        }
+      }
+      const { data: res } = await this.common.postRequest(obj)
+      this.userArr1 = res
+    }
+  }
+}
+</script>

+ 64 - 0
src/pages/main/processruns/wfActivitySelect.vue

@@ -0,0 +1,64 @@
+
+<template>
+<el-dialog title="流程节点信息" v-if="visible" :visible.sync="visible" :append-to-body="true">
+  <el-form ref="form" @submit.native.prevent  @keyup.enter.native="dataFormSubmit()" label-width="80px">
+    <el-form-item label="流程节点">
+      <el-select filterable  placeholder="流程节点" v-model="selectedActivityId">
+        <el-option v-for="(item, index) in activitylist" :key='item.id' :label="item.name" :value="item.id"></el-option>
+      </el-select>
+    </el-form-item>
+  </el-form>
+  <span slot="footer" class="dialog-footer">
+      <el-button type="primary" @click="onOk()">确定</el-button>
+      <el-button @click="visible = false">关闭</el-button>
+    </span>
+</el-dialog>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      visible: false, title:"添加",
+      disabled:false,
+      btn:"提交",
+      aproveVisible: false,
+      processDefinationKey: null,
+      activitylist: {},
+      selectedActivityId: null,
+    }
+  },
+  created() {
+
+  },
+  activated() {
+
+  },
+  methods: {
+    // 初始化
+    init(processDefinationKey) {
+      this.visible = true
+      this.processDefinationKey = processDefinationKey;
+      let self = this;
+      // tapp.services.wf_Model.getProcessActivities(this.processDefinationKey).then(function(result) {
+      //   self.activitylist = result.filter(p => {
+      //     return p.implementation != undefined || p.assignee != undefined
+      //   });
+
+      // });
+    },
+    onOk() {
+      let self = this;
+      if (!this.selectedActivityId) {
+        self.$notify.error({
+          title: '错误',
+          message: '未选择流程节点!'
+        });
+        return false;
+      }
+      this.visible = false;
+      this.$emit('select', this.selectedActivityId);
+    },
+  }
+}
+</script>

+ 2 - 2
src/pages/main/terminal/advertisement.vue

@@ -24,10 +24,10 @@
                     <div class="adv-tit" @click="jumpinfo">
                         <span>广告设计费明细</span>
                     </div>
-                    <div class="adv-tit adv-add" @click="advadd">
+                    <!-- <div class="adv-tit adv-add" @click="advadd">
                         <i class="el-icon-plus"></i>
                         <span>申请</span>
-                    </div>
+                    </div> -->
                 </div>
             </div>
         </div>

+ 641 - 0
src/pages/main/terminals/advchecks.vue

@@ -0,0 +1,641 @@
+<template>
+  <fullscreen :fullscreen.sync="fullscreen" class="container">
+    <div class="container-box">
+      <toolList @iconCli="iconCli" :tooltit="tooltit"></toolList>
+      <div class="search">
+        <el-select v-model="advstatus" @change="advchange">
+          <el-option v-for="items in advopt" :key="items.id" :label="items.name" :value="items.id">
+          </el-option>
+        </el-select>
+      </div>
+      <div class="tabbox">
+        <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
+          tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+          <el-table-column prop="process_id" label="工单编号">
+          </el-table-column>
+          <el-table-column prop="need_name" label="工单标题"> </el-table-column>
+          <el-table-column prop="createId" label="发起人"> </el-table-column>
+          <el-table-column prop="proposer" label="发起人姓名">
+          </el-table-column>
+          <el-table-column prop="proposer_time" label="发起时间">
+          </el-table-column>
+          <el-table-column prop="taskName" label="状态"> </el-table-column>
+          <el-table-column label="操作" width="120px" align="center">
+            <template slot-scope="scope">
+              <el-button size="mini" type="primary" @click="dialogCheck(scope.row, 1)">查看</el-button>
+              <!--<el-button size="mini" type="danger" v-if="scope.row.sts==3"-->
+              <el-button size="mini" v-if="scope.row.status === '1'" type="danger" @click="dialogCheck(scope.row, 2)">审核
+              </el-button>
+              <!-- <el-button
+                v-if="
+                  userInfo.loginName == scope.row.opName && scope.row.sts == '3'
+                "
+                size="mini"
+                type="primary"
+                @click="advSure(scope.row)"
+                >归档
+              </el-button> -->
+            </template>
+          </el-table-column>
+        </el-table>
+        <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+          :total="total">
+        </el-pagination>
+      </div>
+      <el-dialog title="广告管理" v-if="dialogStatus" :visible.sync="dialogStatus" width="80%" :destroy-on-close="true"
+        :modal-append-to-body="false" :close-on-click-modal="false">
+        <div>
+          <advert v-if="typestatsu === 2" @closeEdio="closeEdio" :componentInfo="componentInfo"
+            :componentStatus="componentStatus" :changeinfo="changeinfo" :saveStatus="saveStatus"></advert>
+        </div>
+      </el-dialog>
+
+      <el-dialog title="定稿素材" :visible.sync="dialogStatusc" width="50%" :destroy-on-close="true"
+        :modal-append-to-body="false" :close-on-click-modal="false">
+        <!-- <el-form>
+                    <el-form-item class="info-line online">
+                        <span>素材类型</span>
+                        <el-select :popper-append-to-body="false" v-model="advtype" placeholder="素材类型">
+                            <el-option v-for="item in typeList" :key="item.dataCode" :label="item.dataName"
+                                :value="item.dataCode">
+                            </el-option>
+                        </el-select>
+                    </el-form-item>
+                </el-form> -->
+        <div slot="footer" class="dialog-footer">
+          <el-button @click="dialogCli(1)" type="primary">确 定</el-button>
+          <el-button @click="dialogCli(2)">取 消</el-button>
+        </div>
+      </el-dialog>
+    </div>
+  </fullscreen>
+</template>
+<script>
+import {
+  getTodoBase,
+  getDoneBase,
+  getInitiateBase,
+} from "../../../http/api.js";
+import mySearch from "../../../components/search.vue";
+import toolList from "../../../components/toolList.vue";
+import advert from "./components/adverts.vue";
+
+export default {
+  components: {
+    mySearch,
+    toolList,
+    advert,
+  },
+  data() {
+    return {
+      clickStatus: '',
+      tooltit: "广告管理",
+      auditStatus: false,
+      fullscreen: false,
+      total: 0,
+      pageSize: 1,
+      tableData: [{}],
+      dialogStatus: false,
+      disableStatus: false,
+      infolist: {},
+      userInfo: {},
+      params: {},
+      typestatsu: 1,
+      options: [],
+      typeopt: [],
+      componentInfo: {},
+      componentStatus: false,
+      dialogStatusc: false,
+      loading: false,
+      changeinfo: false,
+      saveStatus: false,
+      advstatus: "",
+      advopt: [
+        {
+          id: "0",
+          name: "待审批",
+        },
+        {
+          id: "1",
+          name: "已审批",
+        },
+        {
+          id: "2",
+          name: "我发起的",
+        },
+        {
+          id: "3",
+          name: "定稿 ",
+        },
+      ],
+      btnctrlStatus: false,
+      typeList: [],
+      advtype: "",
+      dgid: "",
+      singleTable: {},
+      shParam: {},
+      // isBtnShow: false,
+      isGDClick: false,
+      tableName: "ggsj_process",
+    };
+  },
+  methods: {
+    //我的待办
+    getQueryList() {
+      let list = {
+        tableName: this.tableName,
+      };
+      getTodoBase(this.pageSize, "", list).then((res) => {
+        this.tableData = res.data.data;
+        this.tableData.map((item) => {
+          item.status = "1";
+        });
+        this.total = res.data.totalRecord;
+        this.loading = false;
+      });
+
+      // console.log(this.$utilflow);
+      // let res = this.$utilflow.getQueryList()
+      // console.log(res);
+      // this.$http({
+      //   url: "/market/waf/queryTodoBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //     page: '{"pageNo":"' + this.pageSize + '","pageSize":"10"}',
+      //   },
+      //   data: { tableName: this.tableName },
+      // }).then((res) => {
+      //   // console.log(res);
+      //   this.tableData = res.data.data;
+      //   // let data = res.data.list;
+      //   this.tableData.map((item) => {
+      //     // status === 1 需要审核
+      //     item.status = "1";
+      //   });
+      //   console.log(this.tableData);
+      //   this.total = res.data.totalRecord;
+      //   this.loading = false;
+      //   // this.isGDClick = false;
+      //   // if(this.advstatus==0){
+      //   // 	data.forEach(item => {
+      //   //         item.isBtnShow = false;
+      //   //         this.getSts(item)
+      //   // 	});
+      //   // }
+      //   // this.tableData = data;
+      // });
+    },
+    //我的已办
+    getQueryDone() {
+      let list = {
+        tableName: this.tableName,
+      };
+      getDoneBase(this.pageSize, "", list).then((res) => {
+        this.tableData = res.data.data;
+        this.tableData.map((item) => {
+          item.status = "2";
+        });
+        this.total = res.data.totalRecord;
+        this.loading = false;
+      });
+      // this.$http({
+      //   url: "/market/waf/queryDoneBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //     page: '{"pageNo":"' + this.pageSize + '","pageSize":"10"}',
+      //   },
+      //   data: { tableName: this.tableName },
+      // }).then((res) => {
+      //   console.log(res);
+      //   this.tableData = res.data.data;
+      //   // let data = res.data.list;
+      //   this.tableData.map((item) => {
+      //     // status === 2 不需要审核
+      //     item.status = "2";
+      //   });
+      //   this.total = res.data.totalRecord;
+      //   this.loading = false;
+      //   // this.isGDClick = false;
+      //   // if(this.advstatus==0){
+      //   // 	data.forEach(item => {
+      //   //         item.isBtnShow = false;
+      //   //         this.getSts(item)
+      //   // 	});
+      //   // }
+      //   // this.tableData = data;
+      // });
+    },
+    //我发起的
+    getMeLaunch() {
+      let list = {
+        tableName: this.tableName,
+      };
+      getInitiateBase(this.pageSize, "", list).then((res) => {
+        this.tableData = res.data.data;
+        this.tableData.map((item) => {
+          if (item.taskName === "起草") {
+            item.status = "1";
+          } else {
+            item.status = "2";
+          }
+        });
+        this.total = res.data.totalRecord;
+        this.loading = false;
+      });
+      // this.$http({
+      //   url: "/market/waf/queryInitiateBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //     page: '{"pageNo":"' + this.pageSize + '","pageSize":"10"}',
+      //   },
+      //   data: { tableName: this.tableName },
+      // }).then((res) => {
+      //   // let size = this.isNaNStatus(res.data);
+      //   this.tableData = res.data.data;
+      //   this.tableData.map((item) => {
+      //     if (item.taskName === "起草") {
+      //       item.status = "1";
+      //     } else {
+      //       item.status = "2";
+      //     }
+      //   });
+      //   // let data = res.data.list;
+      //   this.total = res.data.totalRecord;
+      //   this.loading = false;
+      // });
+    },
+    //定稿
+    getFinalized() {
+      this.$http({
+        url: "/market/ggsj/queryDone",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+          page: '{"pageNo":"' + this.pageSize + '","pageSize":"10"}',
+        },
+        data: {},
+      }).then((res) => {
+        console.log(res);
+        // let size = this.isNaNStatus(res.data);
+        this.tableData = res.data.data;
+        this.tableData.map((item) => {
+          item.status = "2";
+        });
+        // let data = res.data.list;
+        this.total = res.data.totalRecord;
+        this.loading = false;
+      });
+    },
+    //获取列表
+    getList(e) {
+      console.log(e);
+      switch (e) {
+        //我的待办
+        case "0":
+          this.auditStatus = true;
+          this.getQueryList();
+          break;
+        //我的已办
+        case "1":
+          this.getQueryDone();
+          break;
+        //我发起的
+        case "2":
+          this.getMeLaunch();
+          break;
+        //定稿
+        case "3":
+          this.getFinalized();
+          break;
+      }
+      // this.pageSize = n;
+      // let _this = this;
+      // this.tableData = [];
+      // this.loading = true;
+      // let param = {
+      //   tableName: "ggsj_process",
+      // };
+      // this.$http({
+      //   url: "/market/waf/queryTodoBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //     page: '{"pageNo":"' + n + '","pageSize":"10"}',
+      //   },
+      //   data: param,
+      // }).then((res) => {
+      //   console.log(res);
+      //   this.tableData = res.data.data;
+      //   // let data = res.data.list;
+      //   this.total = res.data.totalRecord;
+      //   this.loading = false;
+      //   // this.isGDClick = false;
+      //   // if(this.advstatus==0){
+      //   // 	data.forEach(item => {
+      //   //         item.isBtnShow = false;
+      //   //         this.getSts(item)
+      //   // 	});
+      //   // }
+      //   // this.tableData = data;
+      // });
+      // this.$http({
+      //   url: "/market/waf/queryDoneBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //     page: '{"pageNo":"' + n + '","pageSize":"10"}',
+      //   },
+      //   data: param,
+      // }).then((res) => {
+      //   // console.log(res);
+      //   // this.tableData = res.data.data;
+      //   // // let data = res.data.list;
+      //   // this.total = res.data.totalRecord;
+      //   // this.loading = false;
+      //   // this.isGDClick = false;
+      //   // if(this.advstatus==0){
+      //   // 	data.forEach(item => {
+      //   //         item.isBtnShow = false;
+      //   //         this.getSts(item)
+      //   // 	});
+      //   // }
+      //   // this.tableData = data;
+      // });
+    },
+    async getSts(v) {
+      await this.$http({
+        url: "/bpm/api/taskInit",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          taskId: v.taskId,
+          woNo: v.id,
+        },
+      }).then((res) => {
+        this.shParam = res.data;
+        //  this.dialogCli(1);
+        // callback&&callback()
+        if (this.isGDClick) {
+          this.dialogCli(1);
+          return;
+        }
+        if (res.data.taskName == "需求部门") {
+          v.sts = "3";
+          return;
+        }
+        if (res.data.assigneeNo == this.userInfo.loginNo) {
+          v.sts = "0";
+          v.isBtnShow = true;
+          return;
+        }
+      });
+    },
+    // 分页
+    currchange(v) {
+      this.pageSize = v;
+      this.getList(this.advstatus);
+    },
+    advchange(e) {
+      this.pageSize = 1
+      this.total = 0
+      this.getList(e);
+
+    },
+    //处理申请
+    dialogCheck(n, v) {
+
+      if (v == 1) {
+        console.log(n);
+        this.changeinfo = false;
+        this.saveStatus = false
+      } else {
+        if (n.taskName == '起草') {
+          this.saveStatus = true;
+        }else{
+          this.saveStatus = false
+        }
+        this.changeinfo = true;
+      }
+      this.typestatsu = 2;
+      this.dialogStatus = true;
+      let params = {
+        woNo: n.id,
+        taskId: n.taskId,
+      };
+      this.componentInfo = n;
+      this.componentStatus = true;
+    },
+    // 归档
+    advSure(v) {
+      let _this = this;
+      // this.dialogStatusc = true;
+      this.isGDClick = true;
+      this.dgid = v.id;
+
+      this.getSts(v);
+    },
+    dialogCli(v) {
+      let _this = this;
+
+      if (v == 1) {
+        // let advTypeName = '';
+        // for (let i = 0; i < this.typeList.length; i++) {
+        //     if (this.typeList[i].dataCode == this.advtype) {
+        //         advTypeName = this.typeList[i].dataName;
+        //     }
+        // }
+        // let param = {
+        //     woNo: this.dgid,
+        //     advTypeName: advTypeName,
+        //     advType: this.advtype
+        // }
+        let gdParam = {
+          woNo: this.dgid,
+          // advTypeName: advTypeName,
+          // advType: this.advtype
+        };
+
+        this.shParam.params.terminalRes = JSON.stringify(
+          Object.assign(JSON.parse(this.shParam.params.terminalRes), gdParam)
+        );
+
+        let param = this.shParam;
+        this.$http({
+          // url: "/market/cadv/mkConfirmAdv",
+          url: "/bpm/api/submitTask",
+          method: "post",
+          headers: {
+            "Content-Type": "application/json",
+          },
+          data: param,
+        }).then((res) => {
+          if (res.data.result === 1) {
+            _this.$message({
+              message: res.data.desc,
+              type: "error",
+            });
+          } else {
+            _this.$message({
+              message: "成功",
+              type: "success",
+            });
+            _this.getList(_this.params, _this.pageSize);
+          }
+        });
+      }
+      // this.dialogStatusc = false;
+      // this.advtype = '';
+      return;
+    },
+    closeEdio() {
+      this.getList(this.params, this.pageSize);
+      this.typestatsu = 1;
+      this.dialogStatus = false;
+      this.componentStatus = false;
+    },
+    gettype() {
+      this.$http({
+        url: "/sysmgr/cfgDataDicts/queryMap",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "materType",
+        },
+      }).then((res) => {
+        this.typeList = res.data.body.materType;
+      });
+    },
+    //功能栏
+    iconCli(v) {
+      if (v === 1) {
+        this.getList(this.params, this.pageSize);
+      }
+      if (v === 2) {
+        this.fullscreen = !this.fullscreen;
+      }
+    },
+    ctrlbtn() {
+      let v = JSON.parse(window.sessionStorage.childrenMenus);
+      for (let i = 0; i < v.length; i++) {
+        if (v[i].jspUrl == this.$route.path && v[i].systemflag == "1") {
+          this.btnctrlStatus = true;
+          return;
+        }
+      }
+    },
+  },
+  mounted() {
+    this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+    this.advstatus = String(this.$route.query.type);
+    this.clickStatus = this.$route.query.type;
+    this.getList(this.advstatus);
+
+    this.ctrlbtn();
+    this.gettype();
+  },
+  created() { },
+};
+</script>
+<style scoped lang="scss">
+.approval {
+  .roval-box {
+    padding: 0 20px;
+    margin-top: 20px;
+    margin-bottom: 10px;
+
+    .el-input {
+      width: calc(100% - 200px);
+      display: inline-block;
+    }
+
+    span {
+      display: inline-block;
+      width: 80px;
+      font-size: 14px;
+      margin-right: 20px;
+
+      .el-input {
+        width: 100%;
+        display: inline-block;
+      }
+    }
+  }
+}
+
+.onetab {
+  margin-bottom: 20px;
+  padding: 0 20px;
+}
+
+.titbox {
+  div {
+    float: right;
+
+    i {
+      font-size: 22px;
+      margin-left: 20px;
+      cursor: pointer;
+    }
+  }
+}
+
+.tabbox {
+  margin-top: 15px;
+}
+
+.pageBox {
+  text-align: right;
+  margin-top: 10px;
+}
+
+.info-line {
+  width: 100%;
+  display: block;
+  padding-left: 20px;
+
+  div {
+    width: 50%;
+    display: inline-block;
+  }
+
+  span {
+    width: 80px;
+    display: inline-block;
+    text-align: left;
+
+    i {
+      color: red;
+      display: inline-block;
+      padding-right: 5px;
+    }
+  }
+
+  .el-select,
+  .el-input {
+    width: calc(100% - 100px);
+  }
+}
+
+.online {
+  width: 100%;
+
+  .el-select {
+    width: calc(100% - 100px);
+  }
+
+  span {
+    vertical-align: top;
+  }
+
+  .el-textarea {
+    width: calc(100% - 100px);
+  }
+}
+</style>

+ 308 - 0
src/pages/main/terminals/advdetailed.vue

@@ -0,0 +1,308 @@
+<template>
+    <fullscreen :fullscreen.sync="fullscreen" class="container">
+        <div class="container-box">
+            <toolList :tooltit='tooltit'></toolList>
+            <div class="search">
+				<mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+                <el-button class="btn-check" size="medium" type="primary" @click="outlist">导出
+                </el-button>
+            </div>
+            <div class="tabbox">
+                <table cellspacing='0' style="width: auto;">
+                    <tr>
+                        <th colspan="8">广告设计费</th>
+                    </tr>
+                    <tr>
+                        <th>序号</th>
+                        <th>文件编号</th>
+                        <th>文件名称</th>
+                        <th>提供物料</th>
+                        <th>折后单价(含税,元)</th>
+                        <th>数量</th>
+                        <th>结算费用(含税,元)</th>
+                    </tr>
+                    <tr v-for="(item,index) in tabList">
+                        <td>
+                            <div style="text-align: left">{{index+1}}</div>
+                        </td>
+                        <td>
+                            <div style="text-align: left;">{{item.code}}</div>
+                        </td>
+                        <td>
+                            <div style="text-align: left;">{{item.name}}</div>
+                        </td>
+                        <td>
+                            <div class="tab-f" style="text-align: left;" v-for="items in item.wl">{{items}}</div>
+                        </td>
+                        <td>
+                            <div class="tab-f" style="text-align: left;" v-for="items in item.dj">{{items}}</div>
+                        </td>
+                        <td>
+                            <div class="tab-f" style="text-align: left;" v-for="items in item.sl">{{items}}</div>
+                        </td>
+                        <td>
+                            <div class="tab-f" style="text-align: left;" v-for="items in item.fy">{{items}}</div>
+                        </td>
+                        <!-- <td rowspan="11" v-if="index == 0">
+                            <el-input v-model="factoryName" :disabled="disableStatus"
+                                style="text-align: left;width: 200px;">
+                            </el-input>
+                        </td> -->
+                    </tr>
+                </table>
+                <div style="text-align: right;padding-top: 10px;padding-right: 20px;">
+                    <span style="margin-right: 20px;">合计数量:{{allNum}}</span>
+                    <span>结算费用:{{allPrice}}</span>
+                </div>
+            </div>
+        </div>
+    </fullscreen>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+    import toolList from "../../../components/toolList.vue";
+
+    export default {
+        components: {
+            mySearch,
+            toolList
+        },
+        data() {
+
+            return {
+				searchList: [{
+					type: 'input',
+					tit: '供应商名称',
+					value: '',
+					width: '98%',
+				},
+    //             {
+				// 	type: 'date',
+				// 	tit: '开始时间',
+				// 	value: '',
+				// 	width: '32%',
+				// }, {
+				// 	type: 'date',
+				// 	tit: '结束时间',
+				// 	value: '',
+				// 	width: '32%',
+				// },
+                ],
+                tooltit: '广告设计费明细',
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [],
+                dialogStatus: false,
+                disableStatus: false,
+                titname: '终端',
+                infolist: {},
+                typeOptions: [{
+                    dataCode: 1,
+                    dataName: 111,
+                }],
+                userInfo: {},
+                params: {},
+                infoApply: [],
+                tabList:[],
+                allPrice:0,
+                allNum:0,
+            }
+        },
+        methods: {
+			//搜索数据
+			searchInfo(v) {
+				this.params = {};
+				v[0] ? this.params.supplier = v[0] : '';
+				v[1] ? this.params.contractStartTimeFrom = this.$formatDate(v[1] , "YYYY-MM-DD") : '';
+				v[2] ? this.params.contractStartTimeTo = this.$formatDate(v[2] , "YYYY-MM-DD") : '';
+				this.getList(this.params, this.pageSize);
+			},
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                let _this = this;
+                this.$http({
+                    url: "/market/cDesignSupplier/queryList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tabList = res.data;
+                    this.allPrice = res.data[res.data.length-1].amountPrice;
+                    this.allNum = res.data[res.data.length-1].numTotal;
+                    this.tabList.pop();
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+
+            // =======================
+            outlist() {
+                this.$http({
+                    url: "/market/cDesignSupplier/download",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    responseType: "blob",
+                    data: {supplier:this.params.supplier},
+                }).then((response) => {
+                    if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+                        let blob = new Blob([response.data], {
+                            type: 'application/vnd.ms-excel'
+                        })
+                        window.navigator.msSaveOrOpenBlob(blob,
+                            new Date().getTime() + '.xlsx')
+                    } else {
+                        /* 火狐谷歌的文件下载方式 */
+                        var blob = new Blob([response.data])
+                        var downloadElement = document.createElement('a')
+                        var href = window.URL.createObjectURL(blob)
+                        downloadElement.href = href
+                        downloadElement.download = new Date().getTime() + '.xlsx'
+                        document.body.appendChild(downloadElement)
+                        downloadElement.click()
+                        document.body.removeChild(downloadElement)
+                        window.URL.revokeObjectURL(href)
+                    }
+                });
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .onetab {
+        margin-bottom: 20px;
+        padding: 0 20px;
+    }
+
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .tabbox {
+        margin-top: 15px;
+        height: calc(100vh - 300px);
+        overflow-y: scroll;
+
+        table {
+            border-bottom: 1px solid #ddd;
+            border-right: 1px solid #ddd;
+            text-align: center;
+            width: 100%!important;
+        }
+
+        tr {
+            // width: 100%;
+        }
+
+        th {
+            border: 1px solid #ddd;
+            border-bottom: 0;
+            border-right: 0;
+            padding: 5px 10px;
+            font-size: 14px;
+        }
+
+        td {
+            border: 1px solid #ddd;
+            border-bottom: 0;
+            border-right: 0;
+            // padding: 5px 10px;
+            font-size: 12px;
+            width: 10%;
+            div{
+                padding-left: 10px;
+            }
+        }
+    }
+    .tab-f{
+        padding: 10px 0;
+        border-bottom: 1px solid #ddd;
+    }
+    .tab-f:last-child{
+        border-bottom: 0;
+    }
+</style>

+ 894 - 0
src/pages/main/terminals/advertincreases.vue

@@ -0,0 +1,894 @@
+<template>
+  <div>
+    <!-- :rules="rules" -->
+    <div class="container">
+      <el-form :model="infolist" ref="infolist" class="container-box">
+        <h2 style="display: block; margin-bottom: 20px">广告申请</h2>
+        <div style="height: calc(100% - 160px); overflow-y: scroll">
+          <div class="info-line">
+            <el-form-item prop="need_name">
+              <span>文件标题</span>
+              <el-input
+                v-model="infolist.need_name"
+                placeholder="文件标题"
+                :disabled="disableStatus"
+              ></el-input>
+            </el-form-item>
+            <el-form-item prop="applydept">
+              <span>申请部门</span>
+              <el-input
+                v-model="infolist.applydept"
+                placeholder="申请部门"
+              ></el-input>
+              <!-- <el-select clearable v-model="infolist.dept" placeholder="申请部门">
+                                <el-option v-for="items in terminalopt" :key="items.procId" :label="items.procName"
+                                    :value="items.procId">
+                                </el-option>
+                            </el-select> -->
+            </el-form-item>
+            <el-form-item prop="proposer">
+              <span>申请人</span>
+              <el-input
+                v-model="infolist.proposer"
+                placeholder="申请人"
+              ></el-input>
+            </el-form-item>
+            <el-form-item prop="tel">
+              <span>联系电话</span>
+              <el-input
+                v-model="infolist.tel"
+                placeholder="联系电话"
+              ></el-input>
+            </el-form-item>
+            <!-- <el-form-item prop="time">
+                            <span>申请时间</span>
+                            <el-date-picker v-model="infolist.time" type="date" placeholder="申请时间">
+                            </el-date-picker>
+                        </el-form-item> -->
+            <el-form-item prop="filenum">
+              <span>文件编号</span>
+              <el-input
+                v-model="infolist.filenum"
+                placeholder="文件编号"
+                :disabled="true"
+              ></el-input>
+            </el-form-item>
+            <el-form-item prop="donetime">
+              <span>完成时间</span>
+              <el-date-picker
+                v-model="infolist.donetime"
+                type="date"
+                placeholder="完成时间"
+                :pickerOptions="pickerOptions"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item prop="importance">
+              <span>紧急程度</span>
+              <el-select
+                :popper-append-to-body="false"
+                clearable
+                v-model="infolist.importance"
+                placeholder="紧急程度"
+              >
+                <el-option
+                  v-for="items in fireopt"
+                  :key="items.dataCode"
+                  :label="items.dataName"
+                  :value="items.dataCode"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item prop="sourcetype">
+              <span>素材类型</span>
+              <el-select
+                :popper-append-to-body="false"
+                clearable
+                v-model="infolist.sourcetype"
+                placeholder="素材类型"
+              >
+                <el-option
+                  v-for="items in materTypeopt"
+                  :key="items.dataCode"
+                  :label="items.dataName"
+                  :value="items.dataCode"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </div>
+
+          <div class="tgqd">
+            <span class="qd-tit">推广渠道</span>
+            <div class="qd-box">
+              <div class="zy">
+                <span>自有渠道</span>
+                <div style="display: flex">
+                  <el-checkbox-group v-model="spreadchannelzList">
+                    <el-checkbox label="实体渠道"></el-checkbox>
+                    <el-checkbox label="门户网站"></el-checkbox>
+                    <el-checkbox label="移动旗舰店app"></el-checkbox>
+                    <el-checkbox label="官方网站"></el-checkbox>
+                    <el-checkbox label="官方微信"></el-checkbox>
+                    <el-checkbox label="电视营业厅(魔百和)"></el-checkbox>
+                    <el-checkbox label="其他"></el-checkbox>
+                  </el-checkbox-group>
+                  <el-input
+                    v-model="infolist.rest"
+                    size="mini"
+                    style="margin-left: 20px"
+                  ></el-input>
+                </div>
+              </div>
+              <div class="zy">
+                <span>外部渠道</span>
+                <div>
+                  <el-checkbox-group v-model="spreadchannelwList">
+                    <el-checkbox label="广播"></el-checkbox>
+                    <el-checkbox label="电视"></el-checkbox>
+                    <el-checkbox label="报纸"></el-checkbox>
+                    <el-checkbox label="互联网"></el-checkbox>
+                    <el-checkbox label="户外"></el-checkbox>
+                    <el-checkbox label="社会渠道"></el-checkbox>
+                    <el-checkbox label="手机卖场"></el-checkbox>
+                  </el-checkbox-group>
+                </div>
+              </div>
+              <div class="zy">
+                <span style="width: 60px; text-align: right">其他</span>
+                <div>
+                  <el-input v-model="infolist.other" size="mini"></el-input>
+                </div>
+              </div>
+            </div>
+          </div>
+
+          <el-form-item class="info-line online" prop="sellingpoint">
+            <span>产品及卖点</span>
+            <el-input
+              v-model="infolist.sellingpoint"
+              placeholder="产品及卖点"
+              type="textarea"
+              :rows="3"
+            >
+            </el-input>
+          </el-form-item>
+          <el-form-item class="info-line online" prop="procontent">
+            <span>宣传内容</span>
+            <el-input
+              v-model="infolist.procontent"
+              placeholder="宣传内容"
+              type="textarea"
+              :rows="3"
+            ></el-input>
+          </el-form-item>
+          <div style="padding-left: 80px">
+            <myUpload
+              @uploadBack="uploadBack"
+              :fileInfo="fileInfo"
+              :fileList="fileInfo.fileList"
+            >
+            </myUpload>
+          </div>
+        </div>
+        <div class="t-footer">
+          <el-button type="primary" @click="clickCheckexa">处 理</el-button>
+          <el-button type="primary" @click="clickSave">保 存</el-button>
+          <el-button @click="dialogCli(1)">取 消</el-button>
+        </div>
+      </el-form>
+    </div>
+    <el-dialog
+      title="选择审批人"
+      :visible.sync="checkexa"
+      width="100%"
+      :destroy-on-close="true"
+      :modal-append-to-body="false"
+      :close-on-click-modal="false"
+    >
+      <Workflow
+        :list="infolist"
+        :requestForm="requestForm"
+        @updateForm="updateForm"
+      />
+      <!-- <div>
+        <el-form :model="infolist" ref="infolist">
+          <el-form-item prop="visiblec" class="info-line online">
+            <span>审批人员</span>
+            <deptTreeOnly
+              class="tree"
+              @treeCheck="treeCheckonly"
+              :defaultList="defaultList"
+              :type="depttype"
+              :closeList="closeList"
+            ></deptTreeOnly>
+            <div class="tree treeUser">
+              <p>
+                {{ treeListonly.leaderAuditName }}
+                <i
+                  v-if="treeListonly.leaderAuditName"
+                  @click="deletes()"
+                  class="el-icon-error"
+                ></i>
+              </p>
+            </div>
+          </el-form-item>
+        </el-form>
+
+        <div slot="footer" style="text-align: right; padding-bottom: 20px">
+          <el-button type="primary" @click="dialogCli(2)">确 定</el-button>
+          <el-button @click="checkexa = false">取 消</el-button>
+        </div>
+      </div> -->
+    </el-dialog>
+  </div>
+</template>
+<script>
+import Qs from "qs";
+import { updateBase } from "../../../http/api.js";
+import Workflow from "../../../components/workflowBase";
+import mySearch from "../../../components/search.vue";
+import myUpload from "../../../components/upload.vue";
+import deptTreeOnly from "../../../components/deptTreeOnly.vue";
+
+export default {
+  components: {
+    mySearch,
+    myUpload,
+    deptTreeOnly,
+    Workflow,
+  },
+  data() {
+    // const tit = (rule, value, callback) => {
+    //   if (!this.infolist.tit) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const dept = (rule, value, callback) => {
+    //   if (!this.infolist.dept) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const opName = (rule, value, callback) => {
+    //   if (!this.infolist.opName) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const phone = (rule, value, callback) => {
+    //   if (!this.infolist.phone) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const time = (rule, value, callback) => {
+    //   if (!this.infolist.time) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const num = (rule, value, callback) => {
+    //     if (!this.infolist.num) {
+    //         callback(new Error('不能为空'))
+    //     } else {
+    //         callback()
+    //     }
+    // }
+    // const overtime = (rule, value, callback) => {
+    //   if (!this.infolist.overtime) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const urgent = (rule, value, callback) => {
+    //   if (!this.infolist.urgent) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const materType = (rule, value, callback) => {
+    //   if (!this.infolist.materType) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const propaganda = (rule, value, callback) => {
+    //   if (!this.infolist.propaganda) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    // const explain = (rule, value, callback) => {
+    //   if (!this.infolist.explain) {
+    //     callback(new Error("不能为空"));
+    //   } else {
+    //     callback();
+    //   }
+    // };
+    return {
+      // rules: {
+      //   tit: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: tit,
+      //     },
+      //   ],
+      //   dept: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: dept,
+      //     },
+      //   ],
+      //   opName: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: opName,
+      //     },
+      //   ],
+      //   phone: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: phone,
+      //     },
+      //   ],
+      //   time: [
+      //     {
+      //       required: true,
+      //       trigger: "change",
+      //       validator: time,
+      //     },
+      //   ],
+      //   // num: [{
+      //   //     required: true,
+      //   //     trigger: 'blur',
+      //   //     validator: num
+      //   // }],
+      //   overtime: [
+      //     {
+      //       required: true,
+      //       trigger: "change",
+      //       validator: overtime,
+      //     },
+      //   ],
+      //   urgent: [
+      //     {
+      //       required: true,
+      //       trigger: "change",
+      //       validator: urgent,
+      //     },
+      //   ],
+      //   materType: [
+      //     {
+      //       required: true,
+      //       trigger: "change",
+      //       validator: materType,
+      //     },
+      //   ],
+      //   propaganda: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: propaganda,
+      //     },
+      //   ],
+      //   explain: [
+      //     {
+      //       required: true,
+      //       trigger: "blur",
+      //       validator: explain,
+      //     },
+      //   ],
+      // },
+      fullscreen: false,
+      total: 0,
+      pageSize: 1,
+      tableData: [{}],
+      disableStatus: false,
+      titname: "终端",
+      infolist: {},
+      terminal: "688225294361509888",
+      terminalopt: [
+        {
+          procId: "111",
+          procName: "1111",
+        },
+      ],
+      userInfo: {},
+      params: {},
+      infoApply: [],
+      options: [],
+      fireopt: [],
+      typeopt: [],
+
+      materTypeopt: [],
+      attList: [],
+      fileInfo: {
+        type: "img",
+        limit: 50,
+        url: "/market/ggsj/upload",
+        fileList: [],
+      },
+      checkList: [],
+      spreadchannelzList: [],
+      checkList1: "",
+      checkList2: [],
+      spreadchannelwList: [],
+      checkList3: "",
+      checkexa: false,
+      treeListonly: {},
+      defaultList: [],
+      closeList: false,
+      visionchonly: false,
+      depttype: 0,
+      request_form: {
+        userId: "",
+        userName: "",
+        path: this.$router.currentRoute.name,
+        userCode: JSON.parse(window.sessionStorage.userInfo).loginNo,
+        title: "",
+        businessKey: "",
+        processDefinitionKey: "ggsj_process",
+      },
+      requestForm: {
+          fresourceId: "99e7da22-5f04-11ed-b399-e00084564cce", //线上环境
+        // fresourceId: "e817fc35-5a51-11ed-8912-00505687dcd3", //测试环境
+        // fresourceId: "3c9baf21-3e43-11ed-ad6b-d6cd97160e00",//本地环境
+        processDefinitionKey: "ggsj_process",
+      },
+    };
+  },
+  computed: {
+    pickerOptions: function () {
+      return {
+        disabledDate(time) {
+          // if(time.getTime() < Date.now() - 8.64e7 || (time.getTime() > Date.now() && time.getTime() < Date.now() + 8.64e7*3) ){
+          //     return true
+          // }
+          if (time.getTime() < Date.now() + 8.64e7 * 3) {
+            return true;
+          }
+        },
+      };
+    },
+  },
+  methods: {
+    clickCheckexa() {
+      if (this.infolist.process_id) {
+        this.checkexa = true;
+      } else {
+        this.$message.error("请先保存工单");
+      }
+    },
+    updateForm(e) {
+      if (e) {
+        this.$router.push({
+          path: "/advchecks",
+          query: { type: 2 },
+        });
+      }
+    },
+    getUserIds() {
+      this.$http({
+        url: "/market/waf/queryRoleByName",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          userCode: JSON.parse(window.sessionStorage.userInfo).loginNo,
+        },
+      }).then((res) => {
+        this.request_form.title = this.userInfo.need_name;
+        this.request_form.userName = res.data.data.rows[0].name;
+        this.request_form.userId = res.data.data.rows[0].userCode;
+      });
+    },
+    //保存工单启动工作流
+    clickSave() {
+      if (this.spreadchannelzList !== []) {
+        this.infolist.spreadchannelzList = this.spreadchannelzList;
+      }
+      if (this.spreadchannelwList !== []) {
+        this.infolist.spreadchannelwList = this.spreadchannelwList;
+      }
+      if (this.attList !== []) {
+        this.infolist.mkFileShareAttachList = this.attList;
+      }
+      this.getUserIds();
+      this.$http({
+        url: "/market/ggsj/add",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: this.infolist,
+      }).then((res) => {
+        this.request_form.businessKey = res.data.body;
+        this.clickHandle(res.data.body);
+      });
+    },
+    async clickHandle(e) {
+      let _this = this;
+      let obj = {
+        url: this.$url.formList.startWork, //开始工作流接口
+        data: _this.request_form,
+        status: "form",
+        headers: {
+          "Content-Type": "application/x-www-form-urlencoded",
+        },
+      };
+
+      let res = await this.common.httpPost(obj, success);
+      function success(data) {
+        // _this.fromList.taskId = data.data;
+        // _this.taskId = data.data;
+        let list = {
+          id: e,
+          tableName: _this.request_form.processDefinitionKey,
+          // taskId:_this.formId,
+          processId: data.data,
+          // resourceId: _this.nextPath.currentShape[0].resourceId,
+        };
+        _this.setUpdate(list);
+      }
+    },
+    //更新工作流接口
+    setUpdate(e) {
+      updateBase(e).then((res) => {
+        this.infolist = res.data.body[0];
+      });
+      // this.$http({
+      //   url: "/market/waf/updateBase",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //   },
+      //   data: e,
+      // }).then((res) => {
+      //   this.infolist = res.data.body[0];
+      //   console.log(this.infolist);
+      //   // this.fromList.taskId = res.data.body.taskId;
+      //   // this.fromList.taskName = res.data.body.taskName;
+      //   // if (res.data.body.taskName === "起草") {
+      //   //   this.isSync = res.data.body.isSync;
+      //   // } else {
+      //   //   this.isSync = "1";
+      //   // }
+      //   // if (res.data.result === 0) {
+      //   //   this.$message.success("工作流更新成功");
+      //   // }
+      // });
+    },
+    deletes() {
+      this.treeListonly = {};
+      this.closeList = !this.closeList;
+    },
+    treeCheckonly(v) {
+      this.treeListonly = v;
+    },
+    //添加
+    dialogCli(v) {
+      if (v === 1) {
+        this.fileInfo.fileList = [];
+        this.infolist = {};
+        this.$router.go(-1);
+        return;
+      }
+      let _this = this;
+      let info = {};
+      info.opTime = _this.$formatDate(new Date(), "YYYY-MM-DD");
+      info.opNo = this.userInfo.loginNo;
+      info.opName = this.userInfo.loginName;
+      info.woTitle = this.infolist.tit;
+
+      this.infolist.time = info.opTime;
+
+      info.params = {};
+      info.params.terminalRes = this.infolist;
+      for (let i = 0; i < this.checkList.length; i++) {
+        this.checkList[i] == "其他";
+        this.checkList[i] = this.checkList1;
+      }
+      info.params.terminalRes.checkList = this.checkList;
+      info.params.terminalRes.checkList2 = this.checkList2;
+      info.params.terminalRes.checkList3 = this.checkList3;
+
+      info.procId = this.terminal;
+      for (let i = 0; i < this.options.length; i++) {
+        if (this.terminal == this.options[i].procId) {
+          info.procName = this.options[i].procName;
+          info.procVersion = this.options[i].procVersion;
+        }
+      }
+
+      let attList = [];
+      for (let i = 0; i < this.attList.length; i++) {
+        attList.push({
+          id: this.attList[i].id,
+          fileCode: this.attList[i].fileCode,
+          fileName: this.attList[i].fileName,
+          opName: this.attList[i].opName,
+          opNo: this.attList[i].opNo,
+          opTime: this.attList[i].opTime,
+          woNo: this.infolist.woNo,
+          attchFileId: this.attList[i].attchFileId,
+        });
+      }
+
+      info.params.assigneeNo = this.treeListonly.leaderAuditNo;
+      info.params.assigneeName = this.treeListonly.leaderAuditName;
+
+      info.params.attList = JSON.stringify(attList);
+      info.params.terminalRes = JSON.stringify(info.params.terminalRes);
+
+      this.submitInfo("/bpm/api/startProc", info);
+    },
+    submitInfo(u, v) {
+      let _this = this;
+      this.$refs.infolist.validate((valid) => {
+        if (valid) {
+          this.$http({
+            url: u,
+            method: "post",
+            headers: {
+              "Content-Type": "application/json",
+            },
+            data: v,
+          }).then((res) => {
+            if (res.data.result === 1) {
+              _this.$message({
+                message: res.data.desc,
+                type: "error",
+              });
+            } else {
+              _this.$message({
+                message: "成功",
+                type: "success",
+              });
+              _this.$router.push({
+                path: "/advchecks",
+                query: {
+                  type: 0,
+                },
+              });
+              // _this.setabList("广告管理列表", "/advcheck?type="+0);
+            }
+          });
+        }
+      });
+    },
+    //流程
+    getTermianl() {
+      this.$http({
+        url: "/bpm/api/queryBpmProcList",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+          page: '{"pageNo":"' + 1 + '","pageSize":"100"}',
+        },
+        data: {},
+      }).then((res) => {
+        this.options = res.data.data;
+      });
+    },
+    getlist() {
+      this.$http({
+        url: "/sysmgr/cfgDataDicts/queryMap",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "materType,jjcd,tgqd",
+        },
+      }).then((res) => {
+        this.materTypeopt = res.data.body.materType;
+        this.fireopt = res.data.body.jjcd;
+        this.extensionopt = res.data.body.tgqd;
+      });
+    },
+    getUser() {
+      this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+      this.infolist.proposer = this.userInfo.loginName;
+      // this.infolist.phone = this.userInfo.phoneNo;
+      this.infolist.applydepartment = this.userInfo.groupName;
+    },
+    uploadBack(v) {
+      this.attList = v;
+      console.log(this.attList);
+    },
+  },
+  mounted() {
+    this.getTermianl();
+    this.getUser();
+    this.getlist();
+    var _this = this;
+    let yy = new Date().getFullYear();
+    let mm = new Date().getMonth() + 1;
+    let dd = new Date().getDate();
+    let hh = new Date().getHours();
+    let mf =
+      new Date().getMinutes() < 10
+        ? "0" + new Date().getMinutes()
+        : new Date().getMinutes();
+    let ss =
+      new Date().getSeconds() < 10
+        ? "0" + new Date().getSeconds()
+        : new Date().getSeconds();
+    _this.gettime = yy + "" + mm + "" + dd + "" + hh + "" + mf + "" + ss;
+    this.infolist.filenum = _this.gettime;
+  },
+  created() {},
+};
+</script>
+<style scoped lang="scss">
+.t-footer {
+  text-align: right;
+  padding-right: 20px;
+  margin-top: 20px;
+}
+
+.onetab {
+  padding: 20px;
+  height: calc(100% - 180px);
+}
+
+.titbox {
+  div {
+    float: right;
+
+    i {
+      font-size: 22px;
+      margin-left: 20px;
+      cursor: pointer;
+    }
+  }
+}
+
+.tabbox {
+  margin-top: 15px;
+}
+
+.pageBox {
+  text-align: right;
+  margin-top: 10px;
+}
+
+.info-line {
+  width: 100%;
+  display: block;
+  padding-left: 20px;
+
+  div {
+    width: 50%;
+    display: inline-block;
+  }
+
+  span {
+    width: 80px;
+    display: inline-block;
+    text-align: left;
+
+    i {
+      color: red;
+      display: inline-block;
+      padding-right: 5px;
+    }
+  }
+
+  .el-select,
+  .el-input {
+    width: calc(100% - 100px);
+  }
+
+  .el-checkbox-group {
+    border: 1px solid #ddd;
+    padding-left: 20px;
+    height: 40px;
+    width: calc(100% - 100px);
+    border-radius: 5px;
+  }
+}
+
+.online {
+  width: 100%;
+
+  .el-select {
+    width: calc(100% - 100px);
+  }
+
+  span {
+    vertical-align: top;
+  }
+
+  .el-textarea {
+    width: calc(100% - 100px);
+  }
+  .tree {
+    width: calc(50% - 60px);
+    display: inline-block;
+    margin-right: 20px;
+    height: 300px;
+    overflow-y: scroll;
+
+    .el-icon-error {
+      float: right;
+      font-size: 20px;
+      margin-top: 9px;
+      cursor: pointer;
+    }
+  }
+
+  .treeUser {
+    margin: 0;
+    border: 1px solid #ddd;
+
+    p {
+      background: #f4f4f4;
+      padding: 0 20px;
+      margin-bottom: 5px;
+    }
+  }
+
+  .treeUserb {
+    width: calc(100% - 100px);
+    border: 1px solid #ddd;
+    background: #f4f4f4;
+    border-radius: 3px;
+    height: auto;
+    overflow: hidden;
+
+    p {
+      display: inline-block;
+      padding: 0 20px;
+      margin-bottom: 5px;
+    }
+  }
+}
+
+.tgqd {
+  margin-bottom: 20px;
+
+  .qd-tit {
+    display: inline-block;
+    width: 100px;
+    padding-left: 20px;
+    vertical-align: top;
+  }
+
+  .qd-box {
+    border: 1px solid #ddd;
+    border-radius: 5px;
+    display: inline-block;
+    width: calc(100% - 120px);
+    min-height: 120px;
+    .zy {
+      display: flex;
+      line-height: 40px;
+      span {
+        display: inline-block;
+        margin: 0 20px;
+      }
+      .el-input {
+        width: 200px;
+      }
+    }
+  }
+}
+</style>

+ 241 - 0
src/pages/main/terminals/advertisement.vue

@@ -0,0 +1,241 @@
+<template>
+  <div>
+    <div class="container">
+      <div class="container-box">
+        <h2 class="font-ui">素材库</h2>
+        <div class="adv-type">
+          <div
+            v-for="item in typeList"
+            :key="item.dataCode"
+            @click="advmaterial(item)"
+          >
+            <span><i class="el-icon-folder-opened"></i></span>
+            <span>{{ item.dataName }}</span>
+          </div>
+        </div>
+        <h2 class="font-ui" style="margin-top: 20px">广告管理</h2>
+        <div class="adv-box">
+          <div class="adv-tit" @click="jumpadv('0')">
+            <i class="el-icon-time"></i>
+            <span
+              >待审批 
+              <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('1')">
+            <i class="el-icon-time"></i>
+            <span
+              >已审批 
+              <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('2')">
+            <i class="el-icon-time"></i>
+            <span
+              >我发起的
+               <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+               </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('3')">
+            <i class="el-icon-notebook-1"></i>
+            <!-- <span>定稿 <em>{{info.designNum||0}}</em></span> -->
+            <span
+              >定稿 
+              <!-- <em>{{ info.finalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpinfo">
+            <span>广告设计费明细</span>
+          </div>
+          <div class="adv-tit" @click="advadd">
+            <i class="el-icon-plus"></i>
+            <span>申请</span>
+          </div>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+<script>
+export default {
+  components: {},
+  data() {
+    return {
+      info: {},
+      typeList: [],
+    };
+  },
+  methods: {
+    jumpinfo() {
+      this.$router.push({
+        path: "/advdetailed",
+      });
+      this.setabList("广告设计费明细", "/advdetailed");
+    },
+    advadd() {
+      this.$router.push({
+        path: "/advertincrease",
+      });
+      this.setabList("广告申请", "/advertincrease");
+    },
+    jumpadv(v) {
+      this.$router.push({
+        path: "/advcheck",
+        query: {
+          type: v,
+        },
+      });
+      this.setabList("广告管理列表", "/advcheck?type=" + v);
+    },
+    advmaterial(v) {
+      this.$router.push({
+        path: "/advertmaterial",
+        query: {
+          type: v.dataCode,
+        },
+      });
+      this.setabList("素材库", "/advertmaterial?type=" + v.dataCode);
+    },
+    setabList(n, p) {
+      let params = {
+        children: "",
+        name: n,
+        rountPath: p,
+        target: "_self",
+      };
+      for (let i = 0; i < this.$store.state.tabList.length; i++) {
+        if (this.$store.state.tabList[i].name === params.name) {
+          this.$store.state.tabList[i] = params;
+        }
+      }
+      let set = new Set([...this.$store.state.tabList, params]);
+      set.add(params);
+      this.$store.commit("setDefaultActive", params.rountPath);
+      this.$store.commit("setTabList", Array.from(set));
+    },
+    getlist() {
+      this.$http({
+        url: "/market/cadv/queryMkAdvStsNum",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {},
+      }).then((res) => {
+        this.info = res.data;
+      });
+    },
+    gettype() {
+      this.$http({
+        url: "/sysmgr/cfgDataDicts/queryMap",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "materType",
+        },
+      }).then((res) => {
+        this.typeList = res.data.body.materType;
+      });
+    },
+    getUser() {
+      this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+    },
+  },
+  mounted() {
+    this.gettype();
+    // this.getUser();
+    this.getlist();
+  },
+  created() {},
+};
+</script>
+<style scoped lang="scss">
+.container-box {
+  padding: 0 30px;
+  height: calc(100% - 40px);
+  overflow-y: scroll;
+  padding-bottom: 20px;
+}
+.adv-box {
+  margin-top: 20px;
+  display: flex;
+  flex-wrap: wrap;
+  justify-content: space-between;
+
+  div {
+    display: inline-block;
+    cursor: pointer;
+    .el-card {
+      width: 100%;
+    }
+    i {
+      margin-right: 10px;
+    }
+  }
+
+  .adv-tit {
+    width: 28%;
+    border: 1px solid transparent;
+    border-radius: 5px;
+    height: 60px;
+    line-height: 60px;
+    padding-left: 20px;
+    box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+    overflow: hidden;
+    em {
+      float: right;
+      margin-right: 20px;
+      font-style: normal;
+      color: #0074d9;
+    }
+  }
+  .adv-tit:hover {
+    border: 1px solid #cfe8fc;
+    background: #cfe8fc;
+  }
+
+  .adv-add {
+    width: 100px;
+  }
+}
+.adv-type {
+  margin-top: 20px;
+  display: flex;
+  justify-content: space-between;
+  flex-wrap: wrap;
+  // border: 1px solid #ddd;
+  border-radius: 5px;
+  padding: 20px;
+  box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+  div {
+    width: 24%;
+    text-align: center;
+    height: 80px;
+    overflow: hidden;
+    min-width: 100px;
+    cursor: pointer;
+    padding-top: 10px;
+    margin: 10px 0;
+  }
+  div:hover {
+    background: #cfe8fc;
+    border-radius: 5px;
+  }
+  span {
+    width: 100%;
+    display: inline-block;
+    height: 40px;
+    // line-height: 40px;
+    i {
+      color: #0074d9;
+      font-size: 36px;
+    }
+  }
+}
+</style>

+ 241 - 0
src/pages/main/terminals/advertisements.vue

@@ -0,0 +1,241 @@
+<template>
+  <div>
+    <div class="container">
+      <div class="container-box">
+        <h2 class="font-ui">素材库</h2>
+        <div class="adv-type">
+          <div
+            v-for="item in typeList"
+            :key="item.dataCode"
+            @click="advmaterial(item)"
+          >
+            <span><i class="el-icon-folder-opened"></i></span>
+            <span>{{ item.dataName }}</span>
+          </div>
+        </div>
+        <h2 class="font-ui" style="margin-top: 20px">广告管理</h2>
+        <div class="adv-box">
+          <div class="adv-tit" @click="jumpadv('0')">
+            <i class="el-icon-time"></i>
+            <span
+              >待审批 
+              <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('1')">
+            <i class="el-icon-time"></i>
+            <span
+              >已审批 
+              <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('2')">
+            <i class="el-icon-time"></i>
+            <span
+              >我发起的
+               <!-- <em>{{ info.approvalNum || 0 }}</em> -->
+               </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpadv('3')">
+            <i class="el-icon-notebook-1"></i>
+            <!-- <span>定稿 <em>{{info.designNum||0}}</em></span> -->
+            <span
+              >定稿 
+              <!-- <em>{{ info.finalNum || 0 }}</em> -->
+              </span
+            >
+          </div>
+          <div class="adv-tit" @click="jumpinfo">
+            <span>广告设计费明细</span>
+          </div>
+          <div class="adv-tit" @click="advadd">
+            <i class="el-icon-plus"></i>
+            <span>申请</span>
+          </div>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+<script>
+export default {
+  components: {},
+  data() {
+    return {
+      info: {},
+      typeList: [],
+    };
+  },
+  methods: {
+    jumpinfo() {
+      this.$router.push({
+        path: "/advdetailed",
+      });
+      this.setabList("广告设计费明细", "/advdetailed");
+    },
+    advadd() {
+      this.$router.push({
+        path: "/advertincreases",
+      });
+      this.setabList("广告申请", "/advertincreases");
+    },
+    jumpadv(v) {
+      this.$router.push({
+        path: "/advchecks",
+        query: {
+          type: v,
+        },
+      });
+      this.setabList("广告管理列表", "/advchecks?type=" + v);
+    },
+    advmaterial(v) {
+      this.$router.push({
+        path: "/advertmaterial",
+        query: {
+          type: v.dataCode,
+        },
+      });
+      this.setabList("素材库", "/advertmaterial?type=" + v.dataCode);
+    },
+    setabList(n, p) {
+      let params = {
+        children: "",
+        name: n,
+        rountPath: p,
+        target: "_self",
+      };
+      for (let i = 0; i < this.$store.state.tabList.length; i++) {
+        if (this.$store.state.tabList[i].name === params.name) {
+          this.$store.state.tabList[i] = params;
+        }
+      }
+      let set = new Set([...this.$store.state.tabList, params]);
+      set.add(params);
+      this.$store.commit("setDefaultActive", params.rountPath);
+      this.$store.commit("setTabList", Array.from(set));
+    },
+    getlist() {
+      this.$http({
+        url: "/market/cadv/queryMkAdvStsNum",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {},
+      }).then((res) => {
+        this.info = res.data;
+      });
+    },
+    gettype() {
+      this.$http({
+        url: "/sysmgr/cfgDataDicts/queryMap",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {
+          dictCodePks: "materType",
+        },
+      }).then((res) => {
+        this.typeList = res.data.body.materType;
+      });
+    },
+    getUser() {
+      this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+    },
+  },
+  mounted() {
+    this.gettype();
+    // this.getUser();
+    this.getlist();
+  },
+  created() {},
+};
+</script>
+<style scoped lang="scss">
+.container-box {
+  padding: 0 30px;
+  height: calc(100% - 40px);
+  overflow-y: scroll;
+  padding-bottom: 20px;
+}
+.adv-box {
+  margin-top: 20px;
+  display: flex;
+  flex-wrap: wrap;
+  justify-content: space-between;
+
+  div {
+    display: inline-block;
+    cursor: pointer;
+    .el-card {
+      width: 100%;
+    }
+    i {
+      margin-right: 10px;
+    }
+  }
+
+  .adv-tit {
+    width: 28%;
+    border: 1px solid transparent;
+    border-radius: 5px;
+    height: 60px;
+    line-height: 60px;
+    padding-left: 20px;
+    box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+    overflow: hidden;
+    em {
+      float: right;
+      margin-right: 20px;
+      font-style: normal;
+      color: #0074d9;
+    }
+  }
+  .adv-tit:hover {
+    border: 1px solid #cfe8fc;
+    background: #cfe8fc;
+  }
+
+  .adv-add {
+    width: 100px;
+  }
+}
+.adv-type {
+  margin-top: 20px;
+  display: flex;
+  justify-content: space-between;
+  flex-wrap: wrap;
+  // border: 1px solid #ddd;
+  border-radius: 5px;
+  padding: 20px;
+  box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+  div {
+    width: 24%;
+    text-align: center;
+    height: 80px;
+    overflow: hidden;
+    min-width: 100px;
+    cursor: pointer;
+    padding-top: 10px;
+    margin: 10px 0;
+  }
+  div:hover {
+    background: #cfe8fc;
+    border-radius: 5px;
+  }
+  span {
+    width: 100%;
+    display: inline-block;
+    height: 40px;
+    // line-height: 40px;
+    i {
+      color: #0074d9;
+      font-size: 36px;
+    }
+  }
+}
+</style>

+ 513 - 0
src/pages/main/terminals/advertmaterial.vue

@@ -0,0 +1,513 @@
+<template>
+    <div>
+        <div class="container">
+            <div class="container-box">
+                <h2>素材库</h2>
+                <div class="adv-type">
+                    <div class="search-list-box">
+                    <el-select v-model="infotype" @change="changeType" class="search-box">
+                        <el-option v-for="items in typeList" :key="items.dataCode" :label="items.dataName"
+                            :value="items.dataCode">
+                        </el-option>
+                    </el-select>
+                    <el-input v-model="fileNameSearch" placeholder="文件名称" @input="searchInput" class="file-name-search search-box"></el-input>
+                    <el-select v-model="timeSort" @change="timeSortChange" class="search-box">
+                        <el-option v-for="item in sortList" :key="item.sortCode" :label="item.sortName"
+                            :value="item.sortCode">
+                        </el-option>
+                    </el-select>
+                    <div class="block search-box search-box1">
+                        <el-date-picker
+                        v-model="dateSearch"
+                        type="daterange"
+                        range-separator="至"
+                        start-placeholder="开始日期"
+                        end-placeholder="结束日期"
+                        @change="dateSearchChange"
+                        class="search-inner-box">
+                        </el-date-picker>
+                    </div>
+                    
+                    </div>
+                    <span>
+                        <myUpload style="float: left;" @uploadBack="uploadBack" :fileInfo="fileInfot"
+                            :fileList="fileInfot.fileList"></myUpload>
+                        <el-button type="primary" @click="mstatuschange" size="medium">{{mstatus?'取消多选':'多选'}}
+                        </el-button>
+                        <el-button type="primary" @click="dialogCli(1)" size="medium" :disabled="!mstatus">导出
+                        </el-button>
+                        <el-button type="danger" @click="dialogCli(2)" size="medium" :disabled="!mstatus">删除</el-button>
+                    </span>
+                </div>
+
+                <div class="img-box">
+                    <div class="boximg">
+                        <div v-for="(item,index) in imgList" :key="item.id" class="img-list">
+                            <div class="img-content">
+                                <img :src="item.fileBase64" alt="" @click="checkimg(item,index)">                           
+                                <el-checkbox v-if="mstatus" v-model="item.checked" @change="checkAdd(item)"></el-checkbox>
+                            </div>
+                            <input type="text" class="file-name" v-model="item.fileName" :readonly="!item.isRename" @dblclick="renameFile(item)" :style="{'border':!item.isRename ? 'none' : '1px solid #ddd'}" @blur="submitFileName(item)">
+                        </div>
+                    </div>
+                    <el-pagination :page-size="20" class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                        :total="total">
+                    </el-pagination>
+                </div>
+            </div>
+            <div v-if="bigImgs" class="bigimgcheck">
+                <i class="el-icon-close close" @click="bigImgs = false"></i>
+                <img :src="checksrc" alt="">
+            </div>
+        </div>
+    </div>
+</template>
+<script>
+    import myUpload from "../../../components/upload";
+    export default {
+        components: {
+            myUpload
+        },
+        data() {
+            return {
+                info: {},
+                delbox: [],
+                infotype: "",
+                typeList: [],
+                fileInfot: {
+                    type: 'btn',
+                    typename: '新增素材',
+                    btntype: 'success',
+                    limit: 10,
+                    url: '/market/cadvMaterial/upload',
+                    fileList: [],
+                    advType: '',
+                    advTypeName: '',
+                },
+                total: 0,
+                pageSize: 1,
+                imgList: [],
+                bigImgs: false,
+                checksrc: null,
+                mstatus: false,
+                checkList: [],
+                params:{},
+                fileNameSearch: '',
+                isRename: true,
+
+                //时间排序
+                sortList:[
+                    {
+                        sortCode: '1',
+                        sortName: '倒序'
+                    },
+                    {
+                        sortCode: '2',
+                        sortName: '正序'
+                    }
+                ],
+                timeSort:'倒序',
+                isDesc: "desc",
+                dateSearch:[],
+                createTimeFrom: '',
+                createTimeTo:''
+            }
+        },
+        methods: {
+            changeType(v) {
+                for (let i = 0; i < this.typeList.length; i++) {
+                    if (this.typeList[i].dataCode == v) {
+                        this.fileInfot.advType = v;
+                        this.fileInfot.advTypeName = this.typeList[i].dataName;
+                        // this.infotype = v
+                        this.getlist(this.pageSize);
+                    }
+                }
+            },
+            timeSortChange(v){
+                if(v==1){
+                    this.isDesc = 'desc'
+                    this.getlist(this.pageSize);
+                }else if(v==2){
+                    this.isDesc = ''
+                    this.getlist(this.pageSize);
+                }
+            },
+            dateSearchChange(v){
+                this.createTimeFrom = this.$formatDate(v[0],"YYYY-MM-DD")
+                this.createTimeTo = this.$formatDate(v[1],"YYYY-MM-DD")
+                this.getlist(this.pageSize);
+                
+
+            },
+            searchInput(v){
+                this.fileNameSearch = v
+                this.getlist(this.pageSize);
+            },
+            uploadBack(v) {
+                this.getlist(this.pageSize);
+            },
+            dialogCli(v) {
+                let params = [];
+                let paramsf = [];
+                for (let i = 0; i < this.checkList.length; i++) {
+                    params.push({
+                        id: this.checkList[i].id
+                    })
+                    paramsf.push({
+                        compressFileId: this.checkList[i].compressFileId,
+                        fileName: this.checkList[i].fileName
+                    })
+                }
+                let _this = this;
+                if (v == 2) {
+                    this.$http({
+                        url: "/market/cadvMaterial/delBatchAdvMaterial",
+                        method: "post",
+                        headers: {
+                            "Content-Type": "application/json",
+                        },
+                        data: params,
+                    }).then((res) => {
+                        if (res.data.result === 1) {
+                            _this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            _this.$message({
+                                message: '成功',
+                                type: 'success'
+                            });
+                            _this.getlist(_this.pageSize);
+                        }
+                    });
+                }else if(v == 1){
+                    this.$http({
+                        url: "/market/cadvMaterial/exportAdvMaterialZip",
+                        method: "post",
+                        responseType: 'blob',
+                        headers: {
+                            "Content-Type": "application/json",
+                        },
+                        data: paramsf,
+                    }).then((response) => {
+                        if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+                            let blob = new Blob([response.data], {
+                                type: response.data.type
+                            });
+                            window.navigator.msSaveOrOpenBlob(blob, 'adv.zip');
+                        } else {
+                            /* 火狐谷歌的文件下载方式 */
+                            console.log(response.data.type)
+                            var blob = new Blob([response.data])
+                            var downloadElement = document.createElement('a')
+                            var href = window.URL.createObjectURL(blob);
+                            downloadElement.href = href;
+                            downloadElement.download = 'adv.zip';
+                            document.body.appendChild(downloadElement);
+                            downloadElement.click();
+                            document.body.removeChild(downloadElement);
+                            window.URL.revokeObjectURL(href);
+                        }
+                    });
+                }
+            },
+            renameFile(v){
+                this.$set(v,'isRename',true)
+            },
+            submitFileName(v){
+                v.isRename = false;
+                let params = {
+                    id: v.id,
+                    fileName: v.fileName
+                }
+                this.$http({
+                    url: "/market/cadvMaterial/updateMkAdvFileName",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: params,
+                }).then((res) => {
+                    if (res.data.result === 1) {
+                            this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            this.$message({
+                                message: '成功',
+                                type: 'success'
+                            });
+                            this.getlist(this.pageSize);
+                        }
+                });
+               
+            },
+            getlist(v) {
+                let params = {
+                    advType: this.infotype,
+                    fileName: this.fileNameSearch,
+                    isDesc: this.isDesc,
+                    createTimeFrom: this.createTimeFrom,
+                    createTimeTo: this.createTimeTo,
+                };
+                if (this.infotype == '08') {
+                    params.advType = ''
+                }
+                this.$http({
+                    url: "/market/cadvMaterial/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + v + '","pageSize":"20"}'
+                    },
+                    data: params,
+                }).then((res) => {
+                    this.total = res.data.totalRecord;
+                    this.imgList = [];
+                    this.imgListold = res.data.data;
+                    res.data.data.forEach(item => {
+                        item.checked = false;
+                        this.imgList.push(item)
+                    })
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getlist(this.pageSize);
+            },
+            gettype() {
+                this.$http({
+                    url: "/sysmgr/cfgDataDicts/queryMap",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {
+                        dictCodePks: 'materType'
+                    },
+                }).then((res) => {
+                    this.typeList = res.data.body.materType;
+                    this.infotype = this.$route.query.type;
+                    this.changeType(this.infotype);
+                });
+            },
+            //切换状态
+            mstatuschange() {
+                this.mstatus = !this.mstatus;
+                this.checkList = [];
+                this.imgList = [];
+                for (let i = 0; i < this.imgListold.length; i++) {
+                    let item = this.imgListold[i];
+                    item.checked = false;
+                    this.imgList.push(item)
+                }
+            },
+            //点击图片
+            checkimg(v, i) {
+                if (this.mstatus) {
+                    this.imgList[i].checked = !this.imgList[i].checked;
+                    this.checkAdd(v);
+                    return
+                }
+                // this.bigImgs = true;
+                // this.checksrc = v.fileBase64;
+                this.$http({
+                    url: "/market/cadvMaterial/previewAdvMaterial?compressFileId=" + v.fileId,
+                    method: "post",
+                    responseType: 'blob',
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {},
+                }).then((res) => {
+                    let _this = this;
+                    if (res && res.data && res.data.size) {
+                        const dataInfo = res.data
+                        let reader = new window.FileReader()
+                        reader.readAsArrayBuffer(dataInfo)
+                        reader.onload = function(e) {
+                            const result = e.target.result
+                            const contentType = dataInfo.type;
+                            const blob = new Blob([result], {
+                                type: contentType
+                            })
+                            const url = window.URL.createObjectURL(blob)
+                            _this.bigImgs = true;
+                            _this.checksrc = url;
+                        }
+                    }
+                });
+            },
+            //选中图片
+            checkAdd(v) {
+                let s = true;
+                for (let i = 0; i < this.checkList.length; i++) {
+                    if (this.checkList[i].id == v.id) {
+                        s = false;
+                        this.checkList.splice(i, 1)
+                        return
+                    }
+                }
+                if (s) {
+                    this.checkList.push(v);
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+            },
+        },
+        mounted() {
+            this.gettype();
+            this.getUser();
+            // this.getlist(this.pageSize);
+        },
+        created() {
+
+        },
+    }
+</script>
+<style scoped lang="scss">
+    .container-box {
+        h2 {
+            margin-bottom: 20px;
+        }
+
+        .adv-type {
+            display: flex;
+            justify-content: space-between;
+            align-items: center;
+            .file-name-search{
+                width: 30%;
+            }
+            span {
+                display: inline-block;
+
+            }
+        }
+
+        .img-box {
+            height: 90%;
+
+            .boximg {
+                height: calc(100% - 190px);
+                overflow-y: scroll;
+                display: flex;
+                flex-wrap: wrap;
+                // justify-content: space-between;
+                margin-top: 20px;
+
+                .img-list {
+                    display: inline-block;
+                    width: 18%;
+                    margin-right: 2%;
+                    margin-bottom: 20px;
+                    overflow: hidden;
+                    // border: 1px solid #ddd;
+                    border-radius: 3px;
+                    background: #fff;
+                    position: relative;
+                    height: 50%;
+                    
+                   
+                    .img-content{
+                        border: 1px solid #ddd;
+                        display: flex;
+                        align-items: center;
+                        width: 100%;
+                        height: 80%;
+                        text-align: center;
+                        img {
+                        // width: 100%;
+                            display: block;
+                            max-width: 100%;
+                            max-height: 100%;
+                            // position: absolute;
+                            // top: 0;
+                            // bottom: 0;
+                            margin: auto;
+                            // height: 100%;
+                        }
+
+                        .el-checkbox {
+                            position: absolute;
+                            top: 0;
+                            right: 0;
+                            display: inline-block;
+                        }
+
+                        span {}
+                    }
+                    .file-name{
+                        margin-top: 5px;
+                        border: none;
+                        outline: none;
+                        width: 100%;
+                        white-space: nowrap;
+                        text-overflow: ellipsis;
+                        overflow: hidden;
+                    }
+                    
+                }
+            }
+        }
+
+        .pageBox {
+            text-align: right;
+            margin-top: 10px;
+        }
+    }
+
+    .bigimgcheck {
+        position: absolute;
+        top: 0;
+        left: 0;
+        width: 100vw;
+        height: 100vh;
+        z-index: 10000;
+        background: rgba(0, 0, 0, .6);
+
+        img {
+            position: absolute;
+            top: 0;
+            left: 0;
+            bottom: 0;
+            right: 0;
+            margin: auto;
+            max-width: 90vw;
+        }
+
+        .close {
+            position: absolute;
+            top: 40px;
+            right: 40px;
+            font-size: 28px;
+            color: #fff;
+            background: rgba(0, 0, 0, .5);
+            border-radius: 50%;
+            padding: 5px;
+            cursor: pointer;
+        }
+    }
+    .search-list-box{
+        display: flex;
+        flex-wrap: wrap;
+        max-width: 50%;
+        .search-box{
+            width: 30%;
+            margin-right: 10px;
+            margin-bottom: 10px;
+            .search-inner-box{
+                width: 100%
+            }
+        }
+        .search-box1{
+            width: 80%;
+        }
+
+    }
+    
+</style>

+ 837 - 0
src/pages/main/terminals/components/adverts.vue

@@ -0,0 +1,837 @@
+<template>
+  <div>
+    <div style="height: 50vh; overflow-y: scroll">
+      <el-form :model="infoApply" ref="infoApply">
+        <div class="info-line">
+          <el-form-item prop="need_name">
+            <span>申请标题</span>
+            <el-input :disabled="!saveStatus" v-model="infoApply.need_name" placeholder="申请标题"></el-input>
+          </el-form-item>
+          <el-form-item prop="applydept">
+            <span>申请流程</span>
+            <el-input disabled v-model="applydept" placeholder="广告申请"></el-input>
+          </el-form-item>
+        </div>
+        <div class="info-line">
+          <el-form-item prop="applydept">
+            <span>申请部门</span>
+            <el-input :disabled="!saveStatus" v-model="infoApply.applydept" placeholder="申请部门"></el-input>
+            <!-- <el-select disabled clearable v-model="infoApply.dept" placeholder="申请部门">
+                            <el-option v-for="items in terminalopt" :key="items.id" :label="items.ou" :value="items.id">
+                            </el-option>
+                        </el-select> -->
+          </el-form-item>
+          <el-form-item prop="proposer">
+            <span>申请人</span>
+            <el-input disabled v-model="infoApply.proposer" placeholder="申请人"></el-input>
+          </el-form-item>
+        </div>
+        <div class="info-line">
+          <el-form-item>
+            <span>申请时间</span>
+            <el-date-picker disabled v-model="infoApply.time" type="date" placeholder="申请时间">
+            </el-date-picker>
+          </el-form-item>
+          <el-form-item prop="tel">
+            <span>联系电话</span>
+            <el-input :disabled="!saveStatus" v-model="infoApply.tel" placeholder="联系电话"></el-input>
+          </el-form-item>
+        </div>
+        <div class="info-line">
+          <el-form-item prop="filenum">
+            <span>文件编号</span>
+            <el-input disabled v-model="infoApply.filenum" placeholder="文件编号">
+            </el-input>
+          </el-form-item>
+          <el-form-item>
+            <span>完成时间</span>
+            <el-date-picker :disabled="!saveStatus" v-model="infoApply.donetime" type="date" placeholder="完成时间"
+              :pickerOptions="pickerOptions">
+            </el-date-picker>
+          </el-form-item>
+        </div>
+
+        <div class="info-line">
+          <el-form-item>
+            <span>紧急程度</span>
+            <el-select :disabled="!saveStatus" clearable v-model="infoApply.importance" placeholder="紧急程度">
+              <el-option v-for="items in fireopt" :key="items.dataCode" :label="items.dataName" :value="items.dataCode">
+              </el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item>
+            <span>素材类型</span>
+            <el-select :disabled="!saveStatus" clearable v-model="infoApply.sourcetype" placeholder="素材类型">
+              <el-option v-for="items in materTypeopt" :key="items.dataCode" :label="items.dataName"
+                :value="items.dataCode">
+              </el-option>
+            </el-select>
+          </el-form-item>
+        </div>
+
+        <!-- <el-form-item class="info-line online">
+                    <span>自有渠道</span>
+                    <el-input disabled v-model="infoApply.checkList"></el-input>
+                </el-form-item>
+                <el-form-item class="info-line online">
+                    <span>外部渠道</span>
+                    <el-input disabled v-model="infoApply.checkList2"></el-input>
+                </el-form-item>
+                <el-form-item class="info-line online">
+                    <span>其他</span>
+                    <el-input disabled v-model="infoApply.checkList3"></el-input>
+                </el-form-item> -->
+
+        <el-form-item class="info-line online">
+          <span>宣传内容</span>
+          <el-input :disabled="!saveStatus" v-model="infoApply.sellingpoint" placeholder="广告宣传内容" type="textarea"
+            :rows="3"></el-input>
+        </el-form-item>
+        <el-form-item class="info-line online">
+          <span>其他说明</span>
+          <el-input :disabled="!saveStatus" v-model="infoApply.procontent" placeholder="设计稿内容描述" type="textarea"
+            :rows="3"></el-input>
+        </el-form-item>
+        <div style="padding: 0 20px 0 100px; margin-bottom: 20px">
+          <uploadDown ref="myupload" :datalist="datalist" :dialogStatus="uploadstatus"></uploadDown>
+        </div>
+        <div style="padding: 0 20px 0 100px; margin-bottom: 20px" v-if="uploadsts">
+          <myUpload @uploadBack="uploadBack" :fileInfo="fileInfo" :fileList="fileInfo.fileList">
+          </myUpload>
+        </div>
+        <!-- <el-form-item class="info-line online" v-if="changeinfo">
+          <span>备注</span>
+          <el-input
+            :disabled="!changeinfo"
+            v-model="infolist.remark"
+            placeholder="备注"
+          ></el-input>
+        </el-form-item> -->
+      </el-form>
+
+      <div v-if="suppSts" class="supp-box">
+        <span style="padding-left: 20px; padding-top: 8px">简易设计</span>
+        <div v-for="item in gys" class="suppdiv">
+          <el-checkbox :disabled="!changeinfo || !suppdis" v-model="item.sts" @change="cancel(item)"><span>{{ item.type
+          }}</span></el-checkbox>
+          <div class="box">
+            <div v-for="one in item.list" class="supp-list">
+              <el-select :disabled="!changeinfo || !suppdis" v-model="one.cho" placeholder="请选择供应商"
+                @change="priceone(one, item)">
+                <el-option v-for="items in item.supplier" :key="items.name" :label="items.name" :value="items.name">
+                </el-option>
+              </el-select>
+              <el-input :disabled="!changeinfo || !suppdis" v-model="one.num" placeholder="数量" @input="numChange(one)">
+              </el-input>
+            </div>
+          </div>
+          <el-button @click="item.list.push({})" type="text" v-if="suppdis">继续添加</el-button>
+        </div>
+      </div>
+
+      <div style="margin-bottom: 20px; padding: 0 20px">
+        <el-table class="com-table" ref="multipleTable" :data="rovaList" tooltip-effect="dark" size="small" border
+          style="width: 100%">
+          <el-table-column prop="taskId" label="编号"> </el-table-column>
+          <el-table-column prop="taskName" label="环节"> </el-table-column>
+          <el-table-column prop="assignee" label="处理人"> </el-table-column>
+          <!-- <el-table-column prop="opNo" label="处理人工号"> </el-table-column> -->
+          <el-table-column prop="endTime" label="处理时间"> </el-table-column>
+          <el-table-column prop="content" label="备注"> </el-table-column>
+        </el-table>
+      </div>
+    </div>
+    <el-dialog title="选择审批人" v-if="checkexa" :before-close="handleClose" :visible.sync="checkexa" :modal="false"
+      width="100%" :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
+      <Workflow :list="infoApply" :requestForm="requestForm" @updateForm="updateForm" />
+    </el-dialog>
+    <div slot="footer" class="dialog-footer">
+      <el-button v-if="changeinfo" type="primary" @click="dialogCli(2)">处 理</el-button>
+      <el-button v-if="saveStatus" type="primary" @click="dialogCli(4)">保 存</el-button>
+      <!-- <el-button v-if="changeinfo" type="primary" @click="dialogCli(1)"
+        >驳 回</el-button
+      > -->
+      <!-- <el-button v-if="!changeinfo" @click="dialogCli(3)">确 定</el-button> -->
+      <el-button @click="dialogCli(3)">取 消</el-button>
+    </div>
+  </div>
+</template>
+
+<script>
+import Workflow from "../../../../components/workflowBase";
+import uploadDown from "../../../../components/uploadDown.vue";
+import myUpload from "../../../../components/upload.vue";
+export default {
+  props: ["componentInfo", "componentStatus", "changeinfo", "saveStatus"],
+  components: {
+    uploadDown,
+    myUpload,
+    Workflow,
+  },
+  data() {
+    return {
+      applydept: '广告申请',
+      requestForm: {
+        fresourceId: "99e7da22-5f04-11ed-b399-e00084564cce", //线上环境
+        // fresourceId: "e817fc35-5a51-11ed-8912-00505687dcd3", //测试环境
+        // fresourceId: "3c9baf21-3e43-11ed-ad6b-d6cd97160e00", //本地环境
+        processDefinitionKey: "ggsj_process",
+      },
+      checkexa: false,
+      cdisable: true,
+      dialogStatus: false,
+      infolist: {},
+      rovaList: [],
+      infoApply: {
+        esay: [],
+        picter: [],
+        medium: [],
+        product: [],
+        copywriting: [],
+        video: [],
+        all: [],
+        testing: [],
+        esaystr: "",
+        picterstr: "",
+        mediumstr: "",
+        productstr: "",
+        copywritingstr: "",
+        videostr: "",
+        allstr: "",
+        testingstr: "",
+      },
+      userInfo: {},
+      terminList: [],
+      oneterminal: "",
+      options: [],
+      fireopt: [],
+      typeopt: [],
+      esayopt: [],
+      picteropt: [],
+      mediumopt: [],
+      productopt: [],
+      copywritingopt: [],
+      videoopt: [],
+      allopt: [],
+      testingopt: [],
+      otheropt: [],
+      extensionopt: [],
+      terminalopt: [],
+      materTypeopt: [],
+      datalist: {
+        url: "/bpm/api/download",
+        type: 1,
+      },
+      fileInfo: {
+        type: "img",
+        limit: 50,
+        url: "/market/ggsj/upload",
+        fileList: [],
+      },
+      uploadstatus: false,
+      suppSts: false,
+      suppdis: false,
+      uploadsts: false,
+      attList: [],
+      mkFileShareAttachList: [],
+      gys: [
+        // {
+        //     type:'设计类型1',
+        //     supplier:[
+        //         {
+        //             name:'供应商1',
+        //             price:100
+        //         },
+        //         {
+        //             name:'供应商2',
+        //             price:200
+        //         },
+        //     ],
+        //     list:[{}]
+        // },
+        // {
+        //     type:'设计类型2',
+        //     supplier:[
+        //         {
+        //             name:'供应商3',
+        //             price:100
+        //         },
+        //         {
+        //             name:'供应商4',
+        //             price:200
+        //         },
+        //     ],
+        //     list:[{}]
+        // },
+      ],
+    };
+  },
+  methods: {
+    updateForm(e) {
+      if (e) {
+        this.$router.go(0);
+      }
+    },
+    //取消勾选时清空后边对应的供应商数据
+    cancel(item) {
+      let chexeboxSts = item.sts;
+      //如果页面取消勾选那么将清空复选框后的内容
+      if (!chexeboxSts) {
+        item.list = [{}];
+      }
+    },
+    uploadBack(v) {
+      this.attList = v;
+    },
+    priceone(v, item) {
+      for (let i = 0; i < item.supplier.length; i++) {
+        if (v.cho == item.supplier[i].name) {
+          v.price = item.supplier[i].price;
+        }
+      }
+      v.cho = v.cho + " " + v.price * (v.num || 1) + "元";
+    },
+    numChange(v) {
+      if (!v.cho) return;
+      v.cho = v.cho.split(" ")[0] + " " + v.price * v.num + "元";
+    },
+    //流程追踪接口
+    async clickForm(e) {
+      let list = {
+        processInstanceId: e.process_id,
+        // taskId:e.taskId
+      };
+      let _this = this;
+      let obj = {
+        url: this.$url.formList.getCommentsByProcessId, //流程追踪接口
+        data: list,
+        headers: {
+          "Content-Type": "application/json",
+        },
+      };
+
+      let res = await this.common.httpPost(obj, success);
+      function success(data) {
+        data.data.map((item) => {
+          item.startTime = _this.$util.datetimeFormat(item.startTime);
+          item.endTime = _this.$util.datetimeFormat(item.endTime);
+        });
+        console.log(data.data);
+        _this.rovaList = data.data;
+        // _this.lables.data = data.data;
+        // data.data.map((item) => {
+        //   item.startTime = _this.$util.datetimeFormat(item.startTime);
+        //   item.endTime = _this.$util.datetimeFormat(item.endTime);
+        // });
+        // // _this.getProcess(e, data.data);
+        // _this.lables.data = data.data;
+      }
+    },
+    //处理申请
+    dialogCheck() {
+      this.infoApply = this.componentInfo;
+      this.uploadstatus = true;
+      //判断当前是否有余额上传
+      // if (this.infoApply.price) {
+      //   this.gys = JSON.parse(this.infoApply.param_val);
+      //   console.log(this.gys);
+      //   this.suppSts = true;
+      //   this.suppdis = true;
+      // }else{
+      //   this.suppSts = false;
+      // }
+
+      this.getinfolist();
+      //判断当前节点
+      if (this.infoApply.taskName == "宣传负责人审批") {
+        this.suppSts = true;
+        this.suppdis = true;
+        this.getSupp();
+      }
+      if (this.infoApply.taskName == "宣传负责人上传") {
+        this.uploadsts = true;
+      }
+      // this.getDepot();
+      // this.$http({
+      //   url: "/bpm/api/taskInit",
+      //   method: "post",
+      //   headers: {
+      //     "Content-Type": "application/json",
+      //   },
+      //   data: {
+      //     taskId: "767191013787082752",
+      //     woNo: "767190809331539968",
+      //   },
+      // }).then((res) => {
+      //   console.log(this.materTypeopt);
+      //   console.log(res);
+      //   this.infolist = Object.assign({}, res.data);
+      //   this.infoApply = JSON.parse(this.infolist.params.terminalRes);
+      //   console.log(this.infoApply);
+      // });
+      //   console.log(res);
+      //   this.rovaList = res.data.taskList; //流程追踪
+      //   // let attlist = JSON.parse(res.data.params.attList);
+      //   for (let i = 0; i < res.data.attachList.length; i++) {
+      //     res.data.attachList[i].id = res.data.attachList[i].attchFileId;
+      //   }
+      //   this.datalist.attList = res.data.attachList;
+      //   if (this.infoApply.price) {
+      //     this.gys = this.infoApply.gys;
+      //     this.suppSts = true;
+      //     this.suppdis = false;
+      //   }
+      //   if (res.data.taskName == "宣传负责人") {
+      //     this.suppSts = true;
+      //     this.suppdis = true;
+      //     this.getSupp();
+      //   }
+      //   if (
+      //     this.rovaList[this.rovaList.length - 1].taskName == "宣传负责人上传"
+      //   ) {
+      //     this.uploadsts = true;
+      //   }
+      //   this.uploadstatus = true;
+      // });
+    },
+    changeArr(v) {
+      let list = "";
+      for (let i = 0; i < v.length; i++) {
+        list += v[i] + " ";
+      }
+      return list;
+    },
+    //添加
+    dialogCli(v) {
+      if(v ==2 ){
+        this.checkexa = true;
+      }
+      //取消操作
+      if (v == 4) {
+        this.$http({
+          url: "/market/ggsj/update",
+          method: "post",
+          headers: {
+            "Content-Type": "application/json",
+          },
+          data: this.infoApply,
+        }).then((res) => {
+          this.$message.success('保存成功')
+        });
+      }
+      if (v === 3) {
+        console.log(this.gys);
+        this.$emit("closeEdio");
+      } else {
+        if (this.infoApply.taskName == "宣传负责人审批") {
+          if (this.suppSts) {
+            let gys = [];
+            let price = 0;
+            for (let i = 0; i < this.gys.length; i++) {
+              if (this.gys[i].sts) {
+                gys.push(JSON.parse(JSON.stringify(this.gys[i])));
+              }
+            }
+            gys.forEach((n) => {
+              for (let j = 0; j < n.list.length; j++) {
+                price += n.list[j].num * n.list[j].price;
+              }
+            });
+            console.log(gys);
+            this.infoApply.gys = gys;
+            this.infoApply.price = price;
+          }
+
+          let list = {
+            id: this.infoApply.id,
+            terminalRes: this.infoApply.gys,
+            price: this.infoApply.price,
+          };
+          this.$http({
+            url: "/market/ggsj/update",
+            method: "post",
+            headers: {
+              "Content-Type": "application/json",
+            },
+            data: list,
+          }).then((res) => {
+            this.$message.success('保存成功')
+          });
+          //调用接口
+          // this.suppSts = true;
+          // this.suppdis = true;
+          // this.getSupp();
+        }
+        if (this.infoApply.taskName == "宣传负责人上传") {
+          let list = {
+            id: this.infoApply.id,
+            mkFileShareAttachList: [],
+          };
+          list.mkFileShareAttachList = this.attList;
+          if (this.mkFileShareAttachList) {
+            this.mkFileShareAttachList.map((item) => {
+              list.mkFileShareAttachList.push(item)
+            })
+          }
+          this.$http({
+            url: "/market/ggsj/update",
+            method: "post",
+            headers: {
+              "Content-Type": "application/json",
+            },
+            data: list,
+          }).then((res) => {
+            console.log(res);
+          });
+        }
+      }
+      // this.datalist.attList = [];
+      // this.uploadstatus = false;
+      // if (v === 3) {
+      //   this.closeInfo();
+      //   return;
+      // }
+      // let _this = this;
+      // this.infolist.opTime = _this.$formatDate(new Date(), "YYYY-MM-DD");
+      // if (this.suppSts) {
+      //   let gys = [];
+      //   let price = 0;
+      //   for (let i = 0; i < this.gys.length; i++) {
+      //     if (this.gys[i].sts) {
+      //       gys.push(JSON.parse(JSON.stringify(this.gys[i])));
+      // if(gys[i])
+
+      // {
+      //     for (let j = 0; j < gys[i].list.length; j++) {
+      //         price+=gys[i].list[j].num*gys[i].list[j].price;
+      //     }
+      // }
+      //   }
+      // }
+      // gys.forEach((n) => {
+      //   for (let j = 0; j < n.list.length; j++) {
+      //     price += n.list[j].num * n.list[j].price;
+      //   }
+      // });
+      // console.log(gys);
+      // console.log(price);
+      // this.infoApply.gys = gys;
+      // this.infoApply.price = price;
+      // }
+      // if (v === 1) {
+      //   let params = {
+      //     dealType: "1",
+      //     dealTypeDesc: "打回",
+      //     procId: this.infolist.procId,
+      //     procVersion: this.infolist.procVersion,
+      //     remark: this.infolist.remark,
+      //     stepId: this.infolist.stepId,
+      //     taskId: this.infolist.taskId,
+      //     taskName: this.infolist.taskName,
+      //     opName: this.infolist.opName,
+      //     opNo: this.infolist.opNo,
+      //     opTime: this.infolist.opTime,
+      //     params: {
+      //       procExeCondiVal: "不同意",
+      //       terminalRes: JSON.stringify(this.infoApply),
+      //     },
+      //     woNo: this.infolist.woNo,
+      //   };
+      //   this.submitInfo("/bpm/api/submitTask", params);
+      // } else if (v === 2) {
+      //   let attList = [];
+      //   for (let i = 0; i < this.attList.length; i++) {
+      //     attList.push({
+      //       id: this.attList[i].id,
+      //       fileCode: this.attList[i].fileCode,
+      //       fileName: this.attList[i].fileName,
+      //       opName: this.attList[i].opName,
+      //       opNo: this.attList[i].opNo,
+      //       opTime: this.attList[i].opTime,
+      //       woNo: this.infolist.woNo,
+      //       attchFileId: this.attList[i].attchFileId,
+      //     });
+      //   }
+      //   let param = {
+      //     dealType: "0",
+      //     dealTypeDesc: "提交",
+      //     procId: this.infolist.procId,
+      //     procVersion: this.infolist.procVersion,
+      //     remark: this.infolist.remark,
+      //     stepId: this.infolist.stepId,
+      //     taskId: this.infolist.taskId,
+      //     taskName: this.infolist.taskName,
+      //     opName: this.infolist.opName,
+      //     opNo: this.infolist.opNo,
+      //     opTime: this.infolist.opTime,
+      //     params: {
+      //       terminalRes: JSON.stringify(this.infoApply),
+      //     },
+      //     woNo: this.infolist.woNo,
+      //   };
+      //   param.params.attList = JSON.stringify(attList);
+      //   if (this.rovaList[this.rovaList.length - 1].taskName == "市场经营部") {
+      //     param.params.assigneeNo = this.infolist.opNo;
+      //     param.params.assigneeName = this.infolist.opName;
+      //   }
+      //   this.submitInfo("/bpm/api/submitTask", param);
+      // }
+    },
+    submitInfo(u, v) {
+      let _this = this;
+      this.$http({
+        url: u,
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: v,
+      }).then((res) => {
+        if (res.data.result === 1) {
+          _this.$message({
+            message: res.data.desc,
+            type: "error",
+          });
+        } else {
+          _this.$message({
+            message: "成功",
+            type: "success",
+          });
+          _this.closeInfo();
+        }
+      });
+    },
+    closeInfo() {
+      this.infolist = {};
+      this.rovaList = [];
+      this.infoApply = {
+        esay: [],
+        picter: [],
+        medium: [],
+        product: [],
+        copywriting: [],
+        video: [],
+        all: [],
+        testing: [],
+      };
+      this.userInfo = {};
+      this.cdisable = true;
+      this.$emit("closeEdio");
+    },
+    getinfolist() {
+      this.$http({
+        url: "/sysmgr/cfgDataDicts/queryMap",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+          page: '{"pageNo":"' + 1 + '","pageSize":"100"}',
+        },
+        data: {
+          dictCodePks:
+            "materType,jjcd,ggfl,jysj,xchm,mj,cp,wal,spdhzz,qa,jkfw,tgqd",
+        },
+      }).then((res) => {
+        this.materTypeopt = res.data.body.materType;
+        this.fireopt = res.data.body.jjcd;
+        this.typeopt = res.data.body.ggfl;
+        this.esayopt = res.data.body.jysj;
+        this.picteropt = res.data.body.xchm;
+        this.mediumopt = res.data.body.mj;
+        this.productopt = res.data.body.cp;
+        this.copywritingopt = res.data.body.wal;
+        this.videoopt = res.data.body.spdhzz;
+        this.allopt = res.data.body.qa;
+        this.testingopt = res.data.body.jkfw;
+        this.extensionopt = res.data.body.tgqd;
+      });
+    },
+    //获取部门
+    getDepot() {
+      this.$http({
+        url: "/sysmgr/sysdept/queryList",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {},
+      }).then((res) => {
+        this.terminalopt = res.data;
+      });
+    },
+    getSupp() {
+      this.$http({
+        url: "/market/cDesignSupplier/getSupplier",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: {},
+      }).then((res) => {
+        res.data.forEach((item) => {
+          item.list = [{}];
+        });
+
+        this.gys = res.data;
+      });
+    },
+    //获取表单上传列表,爆炸贴
+    getQueryList(e) {
+      this.$http({
+        url: "/market/ggsj/query",
+        method: "post",
+        headers: {
+          "Content-Type": "application/json",
+        },
+        data: { id: e.id },
+      }).then((res) => {
+        console.log(res);
+        this.mkFileShareAttachList = res.data.mkFileShareAttachList;
+        if (res.data.paramVal) {
+
+        }
+        console.log(
+          (this.$refs.myupload.infolist = res.data.mkFileShareAttachList)
+        );
+        // this.datalist.attList = res.data.mkFileShareAttachList;
+      });
+    },
+    handleClose() {
+      console.log(123);
+      this.checkexa = false;
+    }
+  },
+  computed: {
+    pickerOptions: function () {
+      return {
+        disabledDate(time) {
+          // if(time.getTime() < Date.now() - 8.64e7 || (time.getTime() > Date.now() && time.getTime() < Date.now() + 8.64e7*3) ){
+          //     return true
+          // }
+          if (time.getTime() < Date.now() + 8.64e7 * 3) {
+            return true;
+          }
+        },
+      };
+    },
+  },
+  mounted() {
+    this.getQueryList(this.componentInfo); //获取表单上传列表,爆炸贴
+    this.clickForm(this.componentInfo);
+  },
+  created() {
+    if (this.componentStatus) {
+      this.dialogCheck();
+    }
+  },
+  watch: {
+    componentStatus(v) {
+      if (v) {
+        // this.dialogCheck();
+      }
+    },
+  },
+};
+</script>
+
+<style scoped lang="scss">
+.onetab {
+  margin-bottom: 20px;
+  padding: 0 20px;
+}
+
+.info-line {
+  width: 100%;
+  display: block;
+  padding-left: 20px;
+
+  div {
+    width: 50%;
+    display: inline-block;
+  }
+
+  span {
+    width: 80px;
+    display: inline-block;
+    text-align: left;
+
+    i {
+      color: red;
+      display: inline-block;
+      padding-right: 5px;
+    }
+  }
+
+  .el-select {
+    width: calc(100% - 100px);
+  }
+
+  .el-input {
+    width: calc(100% - 100px);
+  }
+}
+
+.add {
+  .el-select {
+    width: calc(100% - 200px);
+    margin-right: 20px;
+  }
+}
+
+.online {
+  width: 100%;
+
+  .el-select {
+    width: calc(100% - 100px);
+  }
+
+  span {
+    vertical-align: top;
+  }
+
+  .el-textarea {
+    width: calc(100% - 100px);
+  }
+}
+
+.dialog-footer {
+  text-align: right;
+  padding: 15px 20px;
+}
+
+.supp-box {
+  span {
+    width: 100px;
+    display: inline-block;
+  }
+
+  .suppdiv {
+    width: calc(100% - 110px);
+    float: right;
+
+    .el-checkbox {
+      vertical-align: top;
+      padding-top: 10px;
+    }
+  }
+
+  .box {
+    width: calc(100% - 200px);
+    display: inline-block;
+    // float: right;
+  }
+
+  .supp-list {
+    margin-bottom: 20px;
+
+    .el-select {
+      width: 45%;
+      margin-right: 5%;
+    }
+
+    .el-input {
+      width: 45%;
+      margin-right: 5%;
+    }
+  }
+}
+</style>

+ 377 - 0
src/pages/main/terminals/components/terminals.vue

@@ -0,0 +1,377 @@
+<template>
+    <div>
+        <div style="height: 50vh;overflow-y: scroll;">
+            <div class="info-line add" v-if="!cdisable" style="margin-bottom: 15px;">
+                <span>添加终端</span>
+                <el-select clearable v-model="oneterminal" placeholder="添加申请终端" multiple>
+                    <el-option v-for="item in terminList" :key="item.id" :label="item.terminalTypeName+'-'+item.brandName+'-'+item.modelType+'-'+item.terminalNo"
+                        :value="item.id">
+                    </el-option>
+                </el-select>
+                <el-button style="width: 80px;" type="primary" @click="addtermin">添加</el-button>
+            </div>
+
+            <div class="onetab">
+                <el-table class="com-table" ref="multipleTable" :data="infoApply" tooltip-effect="dark" size="small"
+                    border style="width: 100%">
+                    <el-table-column prop="terminalTypeName" label="类别">
+                    </el-table-column>
+                    <el-table-column prop="brandName" label="品牌">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="型号">
+                    </el-table-column>
+                    <el-table-column prop="terminalNo" label="终端编码">
+                    </el-table-column>
+                    <el-table-column label="操作" align="center" v-if="!cdisable">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="danger" @click="deltermain(scope.row)">删除</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
+            </div>
+
+            <el-form :model="infolist" ref="infolist">
+                <div class="info-line">
+                    <el-form-item>
+                        <span>工单标题</span>
+                        <el-input v-model="infolist.params.woTitle" placeholder="申请数量" :disabled="cdisable"></el-input>
+                    </el-form-item>
+                    <el-form-item>
+                        <span>归还时间</span>
+                        <el-date-picker v-model="reqBackTime" type="date" :disabled="cdisable" placeholder="归还时间">
+                        </el-date-picker>
+                    </el-form-item>
+                </div>
+                <div class="info-line">
+                    <el-form-item>
+                        <span>申请时间</span>
+                        <el-input v-model="infolist.createTime" placeholder="申请时间" disabled></el-input>
+                    </el-form-item>
+                    <el-form-item>
+                        <span>申请人</span>
+                        <el-input v-model="infolist.assigneeName" placeholder="申请人" disabled></el-input>
+                    </el-form-item>
+                </div>
+                <div v-if="changeinfo">
+                    <el-form-item class="info-line online">
+                        <span>备注</span>
+                        <el-input v-model="infolist.remark" placeholder="备注"></el-input>
+                    </el-form-item>
+                </div>
+            </el-form>
+            <div style="margin-bottom: 20px;padding: 0 20px;">
+                <el-table class="com-table" ref="multipleTable" :data="rovaList" tooltip-effect="dark" size="small"
+                    border style="width: 100%">
+                    <el-table-column prop="procId" label="编号">
+                    </el-table-column>
+                    <el-table-column prop="taskName" label="环节">
+                    </el-table-column>
+                    <el-table-column prop="opName" label="处理人">
+                    </el-table-column>
+                    <el-table-column prop="opNo" label="处理人工号">
+                    </el-table-column>
+                    <el-table-column prop="createTime" label="处理时间">
+                    </el-table-column>
+                    <el-table-column prop="remark" label="备注">
+                    </el-table-column>
+                </el-table>
+            </div>
+        </div>
+        <div slot="footer" class="dialog-footer">
+            <el-button v-if="changeinfo" type="primary" @click="dialogCli(2)">同 意</el-button>
+            <el-button v-if="changeinfo" type="primary" @click="dialogCli(1)">驳 回</el-button>
+            <el-button v-if="!changeinfo" @click="dialogCli(3)">确 定</el-button>
+            <el-button @click="dialogCli(3)">取 消</el-button>
+        </div>
+    </div>
+</template>
+
+<script>
+    export default {
+        props: ["componentInfo", "componentStatus","changeinfo"],
+        components: {
+
+        },
+        data() {
+            return {
+                cdisable: true,
+                dialogStatus: false,
+                infolist: {},
+                rovaList: [],
+                infoApply: [],
+                reqBackTime: '',
+                userInfo: {},
+                terminList: [],
+                oneterminal: '',
+            }
+        },
+        methods: {
+            //处理申请
+            dialogCheck() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.$http({
+                    url: '/bpm/api/taskInit',
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {
+                        taskId: this.componentInfo.taskId,
+                        woNo: this.componentInfo.woNo
+                    },
+                }).then((res) => {
+                    this.rovaList = res.data.taskList;
+                    this.infolist = Object.assign({}, res.data);
+                    if (res.data.assigneeNo === this.userInfo.loginName && '工单起草' === res.data.taskName && this.changeinfo) {
+                        this.cdisable = false;
+                        this.TerList();
+                    } else {
+                        this.cdisable = true;
+                    }
+
+                    this.infoApply = JSON.parse(this.infolist.params.terminalRes);
+                    this.reqBackTime = this.infolist.params.reqBackTime;
+
+                    this.infolist.assigneeName = this.infolist.taskList[0].opName;
+                    this.infolist.opNo = this.userInfo.loginNo;
+                    this.infolist.opName = this.userInfo.loginName;
+                });
+            },
+            //添加
+            dialogCli(v) {
+                if (v === 3) {
+                    this.closeInfo();
+                    return
+                }
+                let _this = this;
+                this.infolist.opTime = _this.$formatDate(new Date(), "YYYY-MM-DD")
+                // return
+                if (v === 1) {
+                    let params = {
+                        dealType: '1',
+                        dealTypeDesc: '打回',
+                        procId: this.infolist.procId,
+                        procVersion: this.infolist.procVersion,
+                        remark: this.infolist.remark,
+                        stepId: this.infolist.stepId,
+                        taskId: this.infolist.taskId,
+                        taskName: this.infolist.taskName,
+                        opName: this.infolist.opName,
+                        opNo: this.infolist.opNo,
+                        opTime: this.infolist.opTime,
+                        params: {
+                            procExeCondiVal: '不同意',
+                            terminalRes: JSON.stringify(this.infoApply)
+                        },
+                        woNo: this.infolist.woNo,
+                    }
+                    this.submitInfo("/bpm/api/submitTask", params);
+                } else if (v === 2) {
+                    let param = {
+                        dealType: '0',
+                        dealTypeDesc: '提交',
+                        procId: this.infolist.procId,
+                        procVersion: this.infolist.procVersion,
+                        remark: this.infolist.remark,
+                        stepId: this.infolist.stepId,
+                        taskId: this.infolist.taskId,
+                        taskName: this.infolist.taskName,
+                        opName: this.infolist.opName,
+                        opNo: this.infolist.opNo,
+                        opTime: this.infolist.opTime,
+                        params: this.infolist.params,
+                        // params:{
+                        //     procExeCondiVal:'同意'
+                        // },
+                        woNo: this.infolist.woNo,
+                    }
+                    if (!this.cdisable) {
+                        param.params = {};
+                        param.params.terminalRes = [];
+                        for (let i = 0; i < this.infoApply.length; i++) {
+                            let terminal = {
+                                terminalNo: this.infoApply[i].terminalNo,
+                                terminalTypeName: this.infoApply[i].terminalTypeName,
+                                brandName: this.infoApply[i].brandName,
+                                modelType: this.infoApply[i].modelType,
+                                id: this.infoApply[i].id,
+                            }
+                            param.params.terminalRes.push(terminal)
+                        }
+                        param.params.reqBackTime = _this.reqBackTime?_this.$formatDate(_this.reqBackTime, "YYYY-MM-DD"):'';
+                        param.params.procName = this.infolist.procName;
+                        param.params.terminalRes = JSON.stringify(param.params.terminalRes);
+                    }
+                    // console.log(param)
+                    this.submitInfo("/bpm/api/submitTask", param);
+                }
+            },
+            submitInfo(u, v) {
+                let _this = this;
+                this.$http({
+                    url: u,
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: v,
+                }).then((res) => {
+                    if (res.data.result === 1) {
+                        _this.$message({
+                            message: res.data.desc,
+                            type: 'error'
+                        });
+                    } else {
+                        _this.$message({
+                            message: '成功',
+                            type: 'success'
+                        });
+                        _this.closeInfo();
+                    }
+
+                });
+            },
+            closeInfo() {
+                this.infolist = {};
+                this.rovaList = [];
+                this.infoApply = [];
+                this.reqBackTime = '';
+                this.userInfo = {};
+                this.terminList = [];
+                this.oneterminal = '';
+                this.cdisable = false;
+                this.$emit("closeEdio")
+            },
+            //获取列表
+            TerList() {
+                let _this = this;
+                this.$http({
+                    url: "/market/terminal/terminalrepo/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + 1 + '","pageSize":"1000"}'
+                    },
+                    data: {
+                        sts: '0'
+                    },
+                }).then((res) => {
+                    this.terminList = res.data.data;
+                });
+            },
+            addtermin() {
+                let list = [];
+                for (let j = 0; j < this.oneterminal.length; j++) {
+                    for (let i = 0; i < this.terminList.length; i++) {
+                        if (this.terminList[i].id === this.oneterminal[j]) {
+                            list.push({
+                                terminalTypeName: this.terminList[i].terminalTypeName,
+                                brandName: this.terminList[i].brandName,
+                                modelType: this.terminList[i].modelType,
+                                terminalNo: this.terminList[i].terminalNo,
+                                id: this.terminList[i].id,
+                            })
+                        }
+                    }
+                }
+                for (let j = 0; j < list.length; j++) {
+                    let sts = true;
+                    for (let i = 0; i < this.infoApply.length; i++) {
+                        if (this.infoApply[i].id === list[j].id) {
+                            sts = false;
+                        }
+                    }
+                    sts ? this.infoApply.push(list[j]) : '';
+                }
+            },
+            deltermain(v) {
+                for (let i = 0; i < this.infoApply.length; i++) {
+                    if (this.infoApply[i].id === v.id) {
+                        this.infoApply.splice(i, 1)
+                    }
+                }
+            },
+        },
+        mounted() {
+
+        },
+        created() {
+            if (this.componentStatus) {
+                this.dialogCheck();
+            }
+        },
+        watch: {
+            componentStatus(v) {
+                if (v) {
+                    this.dialogCheck();
+                }
+            }
+        }
+    }
+</script>
+
+<style scoped lang="scss">
+    .onetab {
+        margin-bottom: 20px;
+        padding: 0 20px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .add {
+        .el-select {
+            width: calc(100% - 200px);
+            margin-right: 20px;
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .dialog-footer {
+        text-align: right;
+        padding: 15px 20px;
+    }
+</style>

+ 343 - 0
src/pages/main/terminals/terminApproval.vue

@@ -0,0 +1,343 @@
+<template>
+    <div>
+        <fullscreen :fullscreen.sync="fullscreen" class="container">
+            <div class="ifram" v-if="ifstatus">
+                <div class="flow">
+                    <iframe height="100%" width="100%" :src="agdataurl" frameborder="0"></iframe>
+                    <div class="closeif" @click="ifstatus=false"><i class="el-icon-close"></i></div>
+                </div>
+
+            </div>
+            <div class="container-box">
+                <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
+                <div class="search">
+                    <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+                </div>
+                <div class="tabbox">
+                    <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable"
+                        :data="tableData" tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+                        <el-table-column prop="woNo" label="工单编号">
+                        </el-table-column>
+                        <el-table-column prop="procName" label="工单标题">
+                        </el-table-column>
+                        <el-table-column prop="assigneeName" label="处理人">
+                        </el-table-column>
+                        <el-table-column prop="assigneeNo" label="处理人姓名">
+                        </el-table-column>
+                        <el-table-column prop="createTime" label="发起时间">
+                        </el-table-column>
+                        <el-table-column prop="taskName" label="当前环节">
+                        </el-table-column>
+                        <el-table-column prop="roleName" label="当前处理人">
+                        </el-table-column>
+                        <el-table-column label="操作" width="160px" align="center">
+                            <template slot-scope="scope">
+                                <el-button size="mini" type="primary" @click="dialogCheck(scope.row)">处理</el-button>
+                                <el-button size="mini" type="primary" @click="trajectory(scope.row)">轨迹</el-button>
+                            </template>
+                        </el-table-column>
+                    </el-table>
+                    <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                        :total="total">
+                    </el-pagination>
+                </div>
+
+
+
+                <el-dialog title="申请终端" :visible.sync="dialogStatus" width="60%" :destroy-on-close="true"
+                    :modal-append-to-body="false" :close-on-click-modal="false">
+
+                    <div>
+
+
+                        <terminal v-if="typestatsu === 1" :changeinfo="true" @closeEdio="closeEdio" :componentInfo="componentInfo" :componentStatus="componentStatus"></terminal>
+
+                        <advert v-if="typestatsu === 2" :changeinfo="true" @closeEdio="closeEdio" :componentInfo="componentInfo" :componentStatus="componentStatus"></advert>
+
+
+                    </div>
+
+                </el-dialog>
+            </div>
+        </fullscreen>
+
+    </div>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+    import toolList from "../../../components/toolList.vue";
+    import terminal from "./components/terminal.vue"
+    import advert from "./components/advert.vue"
+
+    // import $ from 'jquery'
+
+
+    export default {
+        components: {
+            mySearch,
+            toolList,
+            terminal,
+            advert
+        },
+        data() {
+            return {
+                tooltit: '待办任务',
+                agdataurl: '',
+                searchList: [{
+                        type: 'input',
+                        tit: '工单标题',
+                        value: '',
+                        width: '49%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '发起人',
+                        value: '',
+                        width: '49%',
+                    }
+                ],
+                loading: false,
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                dialogStatus: false,
+                titname: '终端',
+                infolist: {},
+                userInfo: {},
+                params: {},
+                ifstatus: false,
+                typestatsu: 1,
+                options: [],
+                typeopt: [],
+                componentInfo:{},
+                componentStatus:false,
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.procName = v[0] : '';
+                v[1] ? this.params.assigneeName = v[1] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                let _this = this;
+                this.tableData = [];
+                this.loading = true;
+                this.$http({
+                    url: "/bpm/api/queryToDoTaskList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                    for (let i = 0; i < this.tableData.length; i++) {
+                        this.tableData[i].opTime = _this.$formatDate(this.tableData[i].opTime,
+                            "YYYY-MM-DD")
+                    }
+                    this.loading = false;
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //轨迹
+            trajectory(v) {
+
+                this.agdataurl = '/static/views/flow/flowDesignPrew.html?prevFlag=false&woNo=' + v.woNo + '&taskName=' +
+                    v.taskName + '&fqFlag=N&procId=' + v.procId + '&woTitle=测试终端申请&procName=' + v.procName +
+                    '&procVersion=' + v.procVersion;
+                // window.open(this.agdataurl);
+                this.ifstatus = true;
+
+            },
+            //处理申请
+            dialogCheck(n) {
+                if ('广告申请' === n.procName) {
+                    this.typestatsu = 2;
+                } else if("测试终端申请" === n.procName){
+                    this.typestatsu = 1;
+                }
+                this.dialogStatus = true;
+                this.componentInfo = n;
+                this.componentStatus = true;
+            },
+            closeEdio(){
+                this.getList(this.params, this.pageSize);
+                this.dialogStatus = false;
+                this.componentStatus = false;
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .approval {
+        .roval-box {
+            padding: 0 20px;
+            margin-bottom: 10px;
+
+            .el-input {
+                width: calc(100% - 200px);
+                display: inline-block;
+            }
+
+            span {
+                display: inline-block;
+                width: 80px;
+                font-size: 14px;
+                margin-right: 20px;
+
+                .el-input {
+                    width: 100%;
+                    display: inline-block;
+                }
+            }
+        }
+    }
+
+    .onetab {
+        margin-bottom: 20px;
+        padding: 0 20px;
+    }
+
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 15px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+        // margin-bottom: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select {
+            width: calc(100% - 100px);
+            // margin-right: 20px;
+        }
+
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .ifram {
+        position: fixed;
+        width: 100%;
+        height: 100%;
+        top: 0;
+        left: 0;
+        background: rgba(0, 0, 0, .5);
+        z-index: 1000000;
+
+        .flow {
+            width: 80%;
+            height: 80%;
+            margin-left: 10%;
+            margin-top: 5%;
+            background: #fff;
+            display: inline-block;
+            position: relative;
+        }
+
+        .closeif {
+            position: absolute;
+            right: -40px;
+            background: rgba(0, 0, 0, .4);
+            display: inline-block;
+            width: 40px;
+            height: 40px;
+            line-height: 40px;
+            text-align: center;
+            cursor: pointer;
+            color: #fff;
+            font-size: 20px;
+            font-weight: bold;
+        }
+    }
+</style>

+ 643 - 0
src/pages/main/terminals/terminal.vue

@@ -0,0 +1,643 @@
+<template>
+    <fullscreen :fullscreen.sync="fullscreen" class="container" style="margin: 0;width: 100%;">
+        <div class="container-box" style="padding: 0 20px 0 0;">
+            <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
+            <div style="overflow: hidden;">
+                <div class="search" style="float: left;">
+                    <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+                </div>
+                <div style="margin-top: 20px;float: right;" class="bigbtns">
+                        <el-button style="margin-left: 20px;" size="medium" type="success" @click="tempUpdate(1)">模板下载
+                        </el-button>
+                        <myUpload style="float: left;" @uploadBack="uploadBack" :fileInfo="fileInfot" :fileList="fileInfot.fileList"></myUpload>
+                        <el-button style="margin-left: 20px;" class="btn-check" size="medium" type="primary" @click="dialogCheck(1)">添加
+                        </el-button>
+                        <myUpload style="float: right;margin-left: 20px;" @uploadBack="uploadBack" :fileInfo="fileInfo" :fileList="fileInfo.fileList"></myUpload>
+                </div>
+            </div>
+            <div class="tabbox">
+                <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
+                    tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+                    <el-table-column prop="terminalTypeName" label="类型">
+                    </el-table-column>
+                    <el-table-column prop="brandName" label="品牌">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="型号">
+                    </el-table-column>
+                    <el-table-column prop="terminalNo" label="终端编码" width="145">
+                    </el-table-column>
+                    <!-- <el-table-column prop="modelType" label="终端序列">
+                        </el-table-column> -->
+                    <el-table-column prop="opNo" label="操作工号">
+                    </el-table-column>
+                    <el-table-column prop="opName" label="操作姓名">
+                    </el-table-column>
+                    <el-table-column prop="opTime" label="操做时间" width="135">
+                    </el-table-column>
+                    <el-table-column prop="stsDesc" label="状态">
+                    </el-table-column>
+                    <el-table-column prop="borrowName" label="借用人" width="100">
+                    </el-table-column>
+                    <el-table-column prop="borrowTime" label="借用时间" width="160">
+                    </el-table-column>
+                    <el-table-column prop="requireBackTime" label="预计归还时间" width="160">
+                    </el-table-column>
+                    <el-table-column prop="lastBackTime" label="实际归还时间" width="160">
+                    </el-table-column>
+                    <el-table-column label="操作" width="180px" align="center" fixed="right">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="primary" @click="dialogCheck(2,scope.row)">查看</el-button>
+                            <el-button v-if="scope.row.sts == 0" size="mini" type="primary" @click="dialogCheck(3,scope.row)">修改</el-button>
+                            <el-button v-if="scope.row.sts == 0" size="mini" type="danger" @click="delLine(scope.row)">删除</el-button>
+                            <el-button v-if="scope.row.sts == 2" size="mini" type="primary" @click="backterminal(scope.row)">归还</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
+                <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                    :total="total">
+                </el-pagination>
+            </div>
+
+
+            <el-dialog :title="titname+'终端管理'" :visible.sync="dialogStatus" width="50%" :destroy-on-close="true"
+                :modal-append-to-body="false" :close-on-click-modal="false">
+                <el-form :model="infolist" ref="infolist" :rules="rules">
+                    <div class="info-line">
+                        <el-form-item prop="infovalue">
+                            <span>终端类型</span>
+                            <el-select :popper-append-to-body="false" v-model="infovalue" placeholder="终端类型" @change="verifcheck"
+                                :disabled="disableStatus">
+                                <el-option v-for="item in termOption" :key="item.id" :label="item.terminalTypeName+' - '+item.brandName+' - '+item.modelType"
+                                    :value="item.id">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item prop="sts">
+                            <span>终端状态</span>
+                            <el-select :popper-append-to-body="false" v-model="infolist.sts" placeholder="终端状态"
+                                :disabled="disableStatus">
+                                <el-option v-for="items in stsOption" :key="items.dataCode" :label="items.dataName"
+                                    :value="items.dataCode">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                    </div>
+                    <div v-if="titname == '查看'">
+                        <div class="info-line">
+                            <el-form-item>
+                                <span>当前借用人</span>
+                                <el-input v-model="infolist.borrowName" placeholder="当前借用人" disabled></el-input>
+                            </el-form-item>
+                            <el-form-item>
+                                <span>借用人工号</span>
+                                <el-input v-model="infolist.borrowNo" placeholder="借用人工号" disabled></el-input>
+                            </el-form-item>
+                        </div>
+                        <div class="info-line">
+                            <el-form-item>
+                                <span>借用时间</span>
+                                <el-date-picker v-model="infolist.borrowTime" type="date" placeholder="借用时间" disabled>
+                                </el-date-picker>
+                            </el-form-item>
+                            <el-form-item>
+                                <span>预计归还</span>
+                                <el-date-picker v-model="infolist.requireBackTime" type="date" placeholder="归还时间"
+                                    disabled>
+                                </el-date-picker>
+                            </el-form-item>
+                        </div>
+                        <div class="info-line">
+                            <el-form-item>
+                                <span>实际归还</span>
+                                <el-date-picker v-model="infolist.lastBackTime" type="date" placeholder="实际归还" disabled>
+                                </el-date-picker>
+                            </el-form-item>
+                            <el-form-item>
+                                <span>操作姓名</span>
+                                <el-input v-model="infolist.opName" placeholder="操作姓名" disabled></el-input>
+                            </el-form-item>
+                        </div>
+                        <div class="info-line">
+                            <el-form-item>
+                                <span>终端编码</span>
+                                <el-input v-model="infolist.terminalNo" placeholder="终端编码" disabled></el-input>
+                            </el-form-item>
+                            <el-form-item>
+                                <span>终端序列</span>
+                                <el-input v-model="infolist.terminalNo" placeholder="终端序列" disabled></el-input>
+                            </el-form-item>
+                        </div>
+                    </div>
+                </el-form>
+                <div slot="footer" class="dialog-footer">
+                    <el-button type="primary" @click="dialogCli(2)" v-if="titname !== '查看'">确 定</el-button>
+                    <el-button @click="dialogCli(1)" v-if="titname === '查看'">确 定</el-button>
+                    <el-button @click="dialogCli(1)">取 消</el-button>
+                </div>
+            </el-dialog>
+        </div>
+        <myMessage :messTit='messTit' @closeMessage="closeMessage" :centerDialogVisible="centerDialogVisible" v-if="centerDialogVisible"></myMessage>
+    </fullscreen>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+    import myUpload from "../../../components/upload";
+    import toolList from "../../../components/toolList";
+    import myMessage from "../../../components/myMessage.vue"
+
+    export default {
+        components: {
+            myUpload,
+            mySearch,
+            toolList,
+            myMessage
+        },
+        data() {
+            const infovalue = (rule, value, callback) => {
+                if (!this.infovalue) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const sts = (rule, value, callback) => {
+                if (!this.infolist.sts) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const borrowTime = (rule, value, callback) => {
+                if (!this.borrowTime) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const requireBackTime = (rule, value, callback) => {
+                if (!this.requireBackTime) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const borrowName = (rule, value, callback) => {
+                if (!this.infolist.borrowName) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const borrowNo = (rule, value, callback) => {
+                if (!this.infolist.borrowNo) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            return {
+                rules: {
+                    infovalue: [{
+                        required: true,
+                        trigger: 'change',
+                        validator: infovalue
+                    }],
+                    sts: [{
+                        required: true,
+                        trigger: 'change',
+                        validator: sts
+                    }],
+                    borrowTime: [{
+                        required: true,
+                        trigger: 'change',
+                        validator: borrowTime
+                    }],
+                    requireBackTime: [{
+                        required: true,
+                        trigger: 'change',
+                        validator: requireBackTime
+                    }],
+                    borrowName: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: borrowName
+                    }],
+                    borrowNo: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: borrowNo
+                    }],
+                },
+                tooltit: '测试终端管理',
+                searchList: [{
+                        type: 'input',
+                        tit: '类别',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '品牌',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '型号',
+                        value: '',
+                        width: '32%',
+                    },
+                ],
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                dialogStatus: false,
+                disableStatus: false,
+                titname: '终端',
+                infolist: {},
+                typeOptions: [{
+                    dataCode: 1,
+                    dataName: 111,
+                }],
+                userInfo: {},
+                params: {},
+                stsOption: [{
+                        dataCode: '0',
+                        dataName: '空闲',
+                    },
+                    {
+                        dataCode: '1',
+                        dataName: '预借',
+                    },
+                    {
+                        dataCode: "2",
+                        dataName: '借出',
+                    }
+                ],
+                termOption: [],
+                infovalue: '',
+                borrowTime: '',
+                requireBackTime: '',
+                lastBackTime: '',
+                fileInfo: {
+                    type: 'btn',
+                    typename: '导入',
+                    btntype: 'primary',
+                    limit: 1,
+                    url: '/market/terminal/terminalrepos/import',
+                    fileList: []
+                },
+                fileInfot: {
+                    type: 'btn',
+                    typename: '模板上传',
+                    btntype: 'success',
+                    limit: 1,
+                    url: '/market/compatt/upload',
+                    fileList: []
+                },
+                centerDialogVisible: false,
+                messTit: '',
+                delid: '',
+                loading: false
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.terminalTypeName = v[0] : '';
+                v[1] ? this.params.brandName = v[1] : '';
+                v[2] ? this.params.modelType = v[2] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                this.loading = true;
+                this.tableData = [];
+                let _this = this;
+                this.$http({
+                    url: "/market/terminal/terminalrepo/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                    this.loading = false;
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //查看
+            dialogCheck(v, n) {
+                this.dialogStatus = true;
+                this.disableStatus = false;
+                if (v === 1) {
+                    this.titname = '新建';
+                    this.infovalue = '';
+                    this.borrowTime = '';
+                    this.requireBackTime = '';
+                    this.lastBackTime = '';
+                    this.getUser();
+                    return
+                } else if (v === 2) {
+                    this.titname = '查看';
+                    this.disableStatus = true;
+                } else if (v === 3) {
+                    this.titname = '修改';
+                }
+                this.infolist = Object.assign({}, n); //拷贝
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+                this.borrowTime = this.infolist.borrowTime;
+                this.requireBackTime = this.infolist.requireBackTime;
+                this.lastBackTime = this.infolist.lastBackTime;
+                for (let i = 0; i < this.termOption.length; i++) {
+                    if (this.infolist.terminalType == this.termOption[i].terminalType && this.infolist.brandCode ==
+                        this.termOption[i].brandCode && this.infolist.modelType == this.termOption[i].modelType) {
+                        this.infovalue = this.termOption[i].id;
+                    }
+                }
+            },
+            //修改  添加
+            dialogCli(v) {
+                if (v === 1) {
+                    this.infolist = {};
+                    this.infovalue = '';
+                    this.borrowTime = '';
+                    this.requireBackTime = '';
+                    this.lastBackTime = '';
+                    this.dialogStatus = false;
+                    return
+                }
+                let _this = this;
+                this.infolist.opTime = _this.$formatDate(new Date(), 'YYYY-MM-DD HH:mm:ss')
+                this.infolist.borrowTime = _this.$formatDate(Date.parse(this.borrowTime), 'YYYY-MM-DD');
+                this.infolist.requireBackTime = _this.$formatDate(Date.parse(this.requireBackTime),
+                    'YYYY-MM-DD');
+                this.lastBackTime ? this.infolist.lastBackTime = _this.$formatDate(Date.parse(this.lastBackTime),
+                        'YYYY-MM-DD') :
+                    '';
+                this.infolist.sts === '0' ? this.infolist.stsDesc = '空闲' : this.infolist.sts === '1' ? this.infolist.stsDesc =
+                    '预借' : this.infolist.stsDesc = '借出';
+                if (this.titname === '新建') {
+                    this.submitInfo("/market/terminal/terminalrepos/add", v);
+                } else if (this.titname === '修改') {
+                    this.submitInfo("/market/terminal/terminalrepo/update", v);
+                }
+            },
+            submitInfo(u, v) {
+                let _this = this;
+                this.$refs.infolist.validate(valid => {
+                    if (valid) {
+                        this.$http({
+                            url: u,
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                            },
+                            data: this.infolist,
+                        }).then((res) => {
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                console.log(_this.infolist);
+                                _this.dialogStatus = false;
+                                _this.getList({}, _this.pageSize);
+                            }
+
+                        });
+                    }
+                })
+            },
+            closeMessage(v) {
+                this.centerDialogVisible = false;
+                let _this = this;
+                if (v === 1) {
+                    this.$http({
+                        url: "/market/terminal/terminalrepo/del",
+                        method: "post",
+                        headers: {
+                            "Content-Type": "application/json",
+                        },
+                        data: {
+                            id: this.delid
+                        },
+                    }).then((res) => {
+                        if (res.data.result === 1) {
+                            _this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            _this.$message({
+                                message: '删除成功',
+                                type: 'success'
+                            });
+                            _this.getList(this.params, this.pageSize);
+                        }
+                    });
+                }
+            },
+            //删除
+            delLine(v) {
+                this.centerDialogVisible = true;
+                this.messTit = '即将删除此条数据, 是否删除?';
+                this.delid = v.id;
+            },
+            backterminal(v) {
+                let _this = this;
+                this.$http({
+                    url: "/market/terminal/terminalrepos/back",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {
+                        id: v.id
+                    },
+                }).then((res) => {
+                    if (res.data.result === 1) {
+                        _this.$message({
+                            message: res.data.desc,
+                            type: 'error'
+                        });
+                    } else {
+                        _this.$message({
+                            message: '归还成功',
+                            type: 'success'
+                        });
+                        _this.getList(this.params, this.pageSize);
+                    }
+                });
+            },
+            tempUpdate(v) {
+                let path = '';
+                v === 1 ? path = "/market/terminal/terminalrepos/downloadTemp" : path =
+                    "/market/terminal/terminalrepos/downloadTemp";
+                this.$http({
+                    url: path,
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    responseType: "blob",
+                    data: {},
+                }).then((response) => {
+                    if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+                        let blob = new Blob([response.data], {
+                            type: 'application/vnd.ms-excel'
+                        })
+                        window.navigator.msSaveOrOpenBlob(blob, '资源管理模板.xlsx')
+                    } else {
+                        /* 火狐谷歌的文件下载方式 */
+                        var blob = new Blob([response.data])
+                        var downloadElement = document.createElement('a')
+                        var href = window.URL.createObjectURL(blob)
+                        downloadElement.href = href
+                        downloadElement.download = '资源管理模板.xlsx'
+                        document.body.appendChild(downloadElement)
+                        downloadElement.click()
+                        document.body.removeChild(downloadElement)
+                        window.URL.revokeObjectURL(href)
+                    }
+                });
+            },
+            verifcheck() {
+                for (let i = 0; i < this.termOption.length; i++) {
+                    if (this.termOption[i].id === this.infovalue) {
+                        this.infolist.terminalTypeName = this.termOption[i].terminalTypeName;
+                        this.infolist.terminalType = this.termOption[i].terminalType;
+                        this.infolist.brandName = this.termOption[i].brandName;
+                        this.infolist.brandCode = this.termOption[i].brandCode;
+                        this.infolist.modelType = this.termOption[i].modelType;
+                    }
+                }
+            },
+            uploadBack(v) {
+                this.getList({}, 1);
+            },
+            //获取列表
+            getDepot() {
+                this.$http({
+                    url: "/market/terminal/terminaltype/queryList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {},
+                }).then((res) => {
+                    this.termOption = res.data;
+                });
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getDepot();
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 16px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+</style>

+ 436 - 0
src/pages/main/terminals/terminalApply.vue

@@ -0,0 +1,436 @@
+<template>
+    <div>
+        <div class="container structure-r" style="margin: 0;width: calc(50% - 10px);">
+            <fullscreen :fullscreen.sync="fullscreen" class="container-box" style="padding: 0 20px 0 0;">
+                <div class="titbox">
+                    <h2 class="font-ui">测试终端申请</h2>
+                </div>
+                <div class="search">
+                    <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+                </div>
+                <div class="tabbox">
+                    <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData" tooltip-effect="dark" size="small"
+                        border style="width: 100%">
+                        <el-table-column prop="terminalTypeName" label="类型">
+                        </el-table-column>
+                        <el-table-column prop="brandName" label="品牌">
+                        </el-table-column>
+                        <el-table-column prop="modelType" label="型号">
+                        </el-table-column>
+                        <el-table-column prop="terminalNo" label="终端编码">
+                        </el-table-column>
+                        <el-table-column label="操作" width="80px" align="center">
+                            <template slot-scope="scope">
+                                <el-button size="mini" type="primary" @click="dialogCheck(scope.row)">申请</el-button>
+                            </template>
+                        </el-table-column>
+                    </el-table>
+                    <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                        :total="total">
+                    </el-pagination>
+                </div>
+            </fullscreen>
+        </div>
+
+        <div class="container structure-r" style="margin: 0;width: calc(50% - 10px);margin-left: 20px;">
+            <div class="onetab">
+                <el-table height="calc(100% - 10px)" class="com-table" ref="multipleTable" :data="infoApply" tooltip-effect="dark" size="small"
+                    border style="width: 100%">
+                    <el-table-column prop="terminalTypeName" label="类型">
+                    </el-table-column>
+                    <el-table-column prop="brandName" label="品牌">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="型号">
+                    </el-table-column>
+                    <el-table-column prop="terminalNo" label="终端编码">
+                    </el-table-column>
+                    <el-table-column label="操作" width="80px" align="center">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="danger" @click="delone(scope.row)">x</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
+            </div>
+
+            <el-form :model="infolist" ref="infolist" :rules="rules">
+                <div class="info-line">
+                    <el-form-item prop="terminalTypeName">
+                        <span>申请标题</span>
+                        <el-input v-model="infolist.tit" placeholder="申请标题" :disabled="disableStatus"></el-input>
+                    </el-form-item>
+                    <el-form-item prop="modelType">
+                        <span>归还时间</span>
+                        <el-date-picker v-model="infolist.time" type="date" placeholder="归还时间">
+                        </el-date-picker>
+                    </el-form-item>
+                </div>
+                <div class="info-line">
+                    <el-form-item>
+                        <span>申请流程</span>
+                        <el-select clearable v-model="terminal" placeholder="申请流程" disabled>
+                            <el-option v-for="items in options" :key="items.procId" :label="items.procName"
+                                :value="items.procId">
+                            </el-option>
+                        </el-select>
+                    </el-form-item>
+                    <el-form-item>
+                        <span>操作姓名</span>
+                        <el-input v-model="infolist.opName" placeholder="操作姓名" disabled></el-input>
+                    </el-form-item>
+                </div>
+            </el-form>
+            <div class="t-footer">
+                <el-button type="primary" @click="dialogCli(2)">确 定</el-button>
+                <el-button @click="dialogCli(1)">取 消</el-button>
+            </div>
+        </div>
+    </div>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+
+    export default {
+        components: {
+            mySearch
+        },
+        data() {
+            const terminalTypeName = (rule, value, callback) => {
+                if (!this.infolist.tit) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const modelType = (rule, value, callback) => {
+                if (!this.infolist.time) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            return {
+                rules: {
+                    terminalTypeName: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: terminalTypeName
+                    }],
+                    modelType: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: modelType
+                    }],
+                },
+                searchList: [{
+                        type: 'input',
+                        tit: '类别',
+                        value: '',
+                        width: '48%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '品牌',
+                        value: '',
+                        width: '48%',
+                    },
+                    // {
+                    //     type: 'input',
+                    //     tit: '型号',
+                    //     value: '',
+                    //     width: '32%',
+                    // },
+                ],
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                disableStatus: false,
+                titname: '终端',
+                infolist: {},
+                typeOptions: [{
+                    dataCode: 1,
+                    dataName: 111,
+                }],
+                userInfo: {},
+                params: {},
+                infoApply: [],
+                options: [],
+                terminal:'686495855492730880',
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.terminalTypeName = v[0] : '';
+                v[1] ? this.params.brandName = v[1] : '';
+                v[2] ? this.params.modelType = v[2] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                v.sts = '0';
+                this.pageSize = n;
+                let _this = this;
+                this.$http({
+                    url: "/market/terminal/terminalrepo/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                    for (let i = 0; i < this.tableData.length; i++) {
+                        _this.tableData[i].opTime =  _this.$formatDate(_this.tableData[i].opTime, "YYYY-MM-DD")
+                    }
+                });
+            },
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //申请
+            dialogCheck(n) {
+                let _this = this;
+                let sts = true;
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+                for(let i=0;i<this.infoApply.length;i++){
+                    if(n.id === this.infoApply[i].id){
+                        sts = false;
+                    }
+                }
+                sts ? this.infoApply.push(Object.assign({}, n)) : '';
+            },
+            delone(n){
+                for(let i=0;i<this.infoApply.length;i++){
+                    if(n.id === this.infoApply[i].id){
+                        this.infoApply.splice(i,1)
+                    }
+                }
+            },
+            //添加
+            dialogCli(v) {
+                if (v === 1) {
+                    this.infolist = {};
+                    this.infoApply = [];
+                    this.getUser();
+                    return
+                }
+                let _this = this;
+                let info = {};
+                info.opTime = _this.$formatDate(new Date(), "YYYY-MM-DD");
+                info.opNo = this.userInfo.loginNo;
+                info.opName = this.userInfo.loginName;
+                info.params = {};
+                info.params.reqBackTime = _this.infolist.time?_this.$formatDate(_this.infolist.time, "YYYY-MM-DD"):'';
+                info.params.terminalRes = [];
+                for (let i = 0; i < this.infoApply.length; i++) {
+                    let terminal = {
+                        terminalNo: this.infoApply[i].terminalNo,
+                        terminalTypeName: this.infoApply[i].terminalTypeName,
+                        brandName: this.infoApply[i].brandName,
+                        modelType: this.infoApply[i].modelType,
+                        id: this.infoApply[i].id,
+                    }
+                    info.params.terminalRes.push(terminal)
+                }
+                info.woTitle = this.infolist.tit;
+                info.params.woTitle = this.infolist.tit;
+                info.procId = this.terminal;
+                for (let i = 0; i < this.options.length; i++) {
+                    if(this.infolist.terminal === this.options[i].procId){
+                        info.procName = this.options[i].procName;
+                        info.procVersion = this.options[i].procVersion;
+                    }
+                }
+                info.params.terminalRes = JSON.stringify(info.params.terminalRes)
+                this.submitInfo("/bpm/api/startProc",info);
+            },
+            submitInfo(u,v) {
+                let _this = this;
+                this.$refs.infolist.validate(valid => {
+                    if (valid) {
+                        this.$http({
+                            url: u,
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                            },
+                            data: v,
+                        }).then((res) => {
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                _this.infoApply = [];
+                                _this.getUser();
+                            }
+
+                        });
+                    }
+                })
+            },
+            //删除
+            delLine(v) {
+                let _this = this;
+                this.$confirm('即将删除此条数据, 是否删除?', '提示', {
+                    confirmButtonText: '确定',
+                    cancelButtonText: '取消',
+                    type: 'warning'
+                }).then(() => {
+                    this.$http({
+                        url: "/market/terminal/terminaltype/del",
+                        method: "post",
+                        headers: {
+                            "Content-Type": "application/json",
+                        },
+                        data: {
+                            id: v.id
+                        },
+                    }).then((res) => {
+                        if (res.data.result === 1) {
+                            _this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            _this.$message({
+                                message: '删除成功',
+                                type: 'success'
+                            });
+                            _this.getList(this.params, this.pageSize);
+                        }
+                    });
+                })
+            },
+            //流程
+            getTermianl() {
+                this.$http({
+                    url: "/bpm/api/queryBpmProcList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+                    },
+                    data: {},
+                }).then((res) => {
+                    this.options = res.data.data;
+                });
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getTermianl();
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .t-footer {
+        text-align: right;
+        padding-right: 20px;
+    }
+
+    .onetab {
+        padding: 20px;
+        height: calc(100% - 180px);
+    }
+
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 15px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+</style>

+ 440 - 0
src/pages/main/terminals/terminalModel.vue

@@ -0,0 +1,440 @@
+<template>
+    <fullscreen :fullscreen.sync="fullscreen" class="container" style="margin: 0;width: 100%;">
+        <div class="container-box" style="padding: 0 20px 0 0;">
+            <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
+            <div class="search">
+                <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+                <el-button class="btn-check" size="medium" type="primary" @click="dialogCheck(1)">添加
+                </el-button>
+            </div>
+            <div class="tabbox">
+                <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
+                    tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+                    <el-table-column prop="terminalTypeName" label="类别">
+                    </el-table-column>
+                    <el-table-column prop="brandName" label="品牌">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="型号">
+                    </el-table-column>
+                    <el-table-column prop="opNo" label="操作工号">
+                    </el-table-column>
+                    <el-table-column prop="opName" label="操作姓名">
+                    </el-table-column>
+                    <el-table-column prop="opTime" label="操做时间">
+                    </el-table-column>
+                    <el-table-column label="操作" width="160px" align="center">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="primary" @click="dialogCheck(2,scope.row)">查看</el-button>
+                            <el-button size="mini" type="primary" @click="dialogCheck(3,scope.row)">修改</el-button>
+                            <el-button size="mini" type="danger" @click="delLine(scope.row)">删除</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
+                <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                    :total="total">
+                </el-pagination>
+            </div>
+            <el-dialog :title="titname+'终端'" :visible.sync="dialogStatus" width="50%" :destroy-on-close="true"
+                :modal-append-to-body="false" :close-on-click-modal="false">
+                <div v-loading="loading">
+                    <el-form :model="infolist" ref="infolist" :rules="rules">
+                        <div class="info-line">
+                            <el-form-item prop="terminalTypeName">
+                                <span>终端类别</span>
+                                <el-input v-model="infolist.terminalTypeName" placeholder="终端类别" :disabled="disableStatus"></el-input>
+                            </el-form-item>
+                            <el-form-item prop="terminalType">
+                                <span>类别编码</span>
+                                <el-input v-model="infolist.terminalType" placeholder="类型编码" :disabled="disableStatus"></el-input>
+                            </el-form-item>
+                        </div>
+                        <div class="info-line">
+                            <el-form-item prop="brandName">
+                                <span>终端品牌</span>
+                                <el-input v-model="infolist.brandName" placeholder="终端品牌" :disabled="disableStatus"></el-input>
+                            </el-form-item>
+                            <el-form-item prop="brandCode">
+                                <span>品牌编码</span>
+                                <el-input v-model="infolist.brandCode" placeholder="品牌编码" :disabled="disableStatus"></el-input>
+                            </el-form-item>
+                        </div>
+                        <div class="info-line">
+                            <el-form-item prop="modelType">
+                                <span>终端型号</span>
+                                <el-input v-model="infolist.modelType" placeholder="终端型号" :disabled="disableStatus"></el-input>
+                            </el-form-item>
+                            <el-form-item prop="opNo">
+                                <span>操作姓名</span>
+                                <el-input v-model="infolist.opName" placeholder="操作姓名" disabled></el-input>
+                            </el-form-item>
+                        </div>
+                    </el-form>
+                    <div slot="footer" class="dialog-footer myfooter">
+                        <el-button type="primary" @click="dialogCli(2)" v-if="titname !== '查看'">确 定</el-button>
+                        <el-button @click="dialogCli(1)" v-if="titname === '查看'">确 定</el-button>
+                        <el-button @click="dialogCli(1)">取 消</el-button>
+                    </div>
+                </div>
+            </el-dialog>
+        </div>
+        <myMessage :messTit='messTit' @closeMessage="closeMessage" :centerDialogVisible="centerDialogVisible" v-if="centerDialogVisible"></myMessage>
+    </fullscreen>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+    import toolList from "../../../components/toolList.vue";
+    import myMessage from "../../../components/myMessage.vue"
+
+    export default {
+        components: {
+            mySearch,
+            toolList,
+            myMessage
+        },
+        data() {
+            const terminalTypeName = (rule, value, callback) => {
+                if (!this.infolist.terminalTypeName) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const brandName = (rule, value, callback) => {
+                if (!this.infolist.brandName) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const modelType = (rule, value, callback) => {
+                if (!this.infolist.modelType) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const brandCode = (rule, value, callback) => {
+                if (!this.infolist.brandCode) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            const terminalType = (rule, value, callback) => {
+                if (!this.infolist.terminalType) {
+                    callback(new Error('不能为空'))
+                } else {
+                    callback()
+                }
+            }
+            return {
+                rules: {
+                    terminalTypeName: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: terminalTypeName
+                    }],
+                    terminalType: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: terminalType
+                    }],
+                    brandName: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: brandName
+                    }],
+                    brandCode: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: brandCode
+                    }],
+                    modelType: [{
+                        required: true,
+                        trigger: 'blur',
+                        validator: modelType
+                    }],
+                },
+                tooltit: '终端类型管理',
+                searchList: [{
+                        type: 'input',
+                        tit: '类别',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '品牌',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '型号',
+                        value: '',
+                        width: '32%',
+                    },
+                ],
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                dialogStatus: false,
+                disableStatus: false,
+                titname: '终端',
+                infolist: {},
+                typeOptions: [{
+                    dataCode: 1,
+                    dataName: 111,
+                }],
+                userInfo: {},
+                params: {},
+                centerDialogVisible: false,
+                messTit: '',
+                delid: '',
+                loading:false
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.terminalTypeName = v[0] : '';
+                v[1] ? this.params.brandName = v[1] : '';
+                v[2] ? this.params.modelType = v[2] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                let _this = this;
+                this.loading = true;
+                this.tableData = [];
+                this.$http({
+                    url: "/market/terminal/terminaltype/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                    this.loading = false;
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //查看
+            dialogCheck(v, n) {
+                this.dialogStatus = true;
+                this.disableStatus = false;
+                if (v === 1) {
+                    this.titname = '新建';
+                    this.getUser();
+                    return
+                } else if (v === 2) {
+                    this.titname = '查看';
+                    this.disableStatus = true;
+                } else if (v === 3) {
+                    this.titname = '修改';
+                    this.loading = true;
+                }
+                this.infolist = Object.assign({}, n); //拷贝
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+                this.loading = false;
+            },
+            //修改  添加
+            dialogCli(v) {
+                if (v === 1) {
+                    this.infolist = {};
+                    this.dialogStatus = false;
+                    return
+                }
+                this.infolist.opTime = this.$formatDate(new Date(), 'YYYY-MM-DD HH:mm:ss');
+                if (this.titname === '新建') {
+                    this.submitInfo("/market/terminal/terminaltypes/add", v);
+                } else if (this.titname === '修改') {
+                    this.submitInfo("/market/terminal/terminaltype/update", v);
+                }
+            },
+            submitInfo(u, v) {
+                let _this = this;
+                this.$refs.infolist.validate(valid => {
+                    if (valid) {
+                        this.$http({
+                            url: u,
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                            },
+                            data: this.infolist,
+                        }).then((res) => {
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                _this.dialogStatus = false;
+                                _this.getList({}, _this.pageSize);
+                            }
+
+                        });
+                    }
+                })
+            },
+            closeMessage(v) {
+                this.centerDialogVisible = false;
+                let _this = this;
+                if (v === 1) {
+                    this.$http({
+                        url: "/market/terminal/terminaltype/del",
+                        method: "post",
+                        headers: {
+                            "Content-Type": "application/json",
+                        },
+                        data: {
+                            id: this.delid
+                        },
+                    }).then((res) => {
+                        if (res.data.result === 1) {
+                            _this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            _this.$message({
+                                message: '删除成功',
+                                type: 'success'
+                            });
+                            _this.getList(this.params, this.pageSize);
+                        }
+                    });
+                }
+            },
+            //删除
+            delLine(v) {
+                this.centerDialogVisible = true;
+                this.messTit = '即将删除此条数据, 是否删除?';
+                this.delid = v.id;
+            },
+            //获取字典
+            getDepot() {
+                this.$http({
+                    url: "/market/cfgDataDict/queryList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {},
+                }).then((res) => {
+                    console.log(res.data)
+                    this.typeOptions = res.data;
+                });
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+                console.log(this.infolist);
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 16px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+</style>

+ 270 - 0
src/pages/main/terminals/terminalOver.vue

@@ -0,0 +1,270 @@
+<template>
+    <fullscreen :fullscreen.sync="fullscreen" class="container">
+        <div class="container-box">
+            <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
+            <div class="search">
+                <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+            </div>
+            <div class="tabbox">
+                <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
+                    tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+                    <el-table-column prop="woNo" label="工单编号">
+                    </el-table-column>
+                    <el-table-column prop="procName" label="工单标题">
+                    </el-table-column>
+                    <el-table-column prop="assigneeName" label="发起人">
+                    </el-table-column>
+                    <el-table-column prop="assigneeNo" label="发起人姓名">
+                    </el-table-column>
+                    <el-table-column prop="createTime" label="发起时间">
+                    </el-table-column>
+                    <el-table-column prop="taskName" label="当前环节">
+                    </el-table-column>
+                    <el-table-column prop="roleName" label="当前处理人">
+                    </el-table-column>
+                    <el-table-column label="操作" width="100px" align="center">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="primary" @click="dialogCheck(scope.row)">查看</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
+                <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                    :total="total">
+                </el-pagination>
+            </div>
+            <el-dialog title="终端申请" :visible.sync="dialogStatus" width="50%" :destroy-on-close="true"
+                :modal-append-to-body="false" :close-on-click-modal="false">
+                <div>
+
+                    <terminal v-if="typestatsu === 1" @closeEdio="closeEdio" :componentInfo="componentInfo"
+                        :componentStatus="componentStatus" :changeinfo="false"></terminal>
+
+                    <advert v-if="typestatsu === 2" @closeEdio="closeEdio" :componentInfo="componentInfo"
+                        :componentStatus="componentStatus" :changeinfo="false"></advert>
+
+                </div>
+            </el-dialog>
+        </div>
+    </fullscreen>
+</template>
+<script>
+    import mySearch from "../../../components/search.vue";
+    import toolList from "../../../components/toolList.vue";
+    import terminal from "./components/terminal.vue"
+    import advert from "./components/advert.vue"
+
+    export default {
+        components: {
+            mySearch,
+            toolList,
+            terminal,
+            advert
+        },
+        data() {
+            return {
+                tooltit: '已办任务',
+                searchList: [{
+                        type: 'input',
+                        tit: '工单标题',
+                        value: '',
+                        width: '49%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '发起人',
+                        value: '',
+                        width: '49%',
+                    },
+                ],
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                dialogStatus: false,
+                disableStatus: false,
+                titname: '终端',
+                infolist: {},
+                userInfo: {},
+                params: {},
+                typestatsu: 1,
+                options: [],
+                typeopt: [],
+                componentInfo:{},
+                componentStatus:false,
+                loading:false,
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.terminalTypeName = v[0] : '';
+                v[1] ? this.params.brandName = v[1] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                let _this = this;
+                this.tableData = [];
+                this.loading = true;
+                this.$http({
+                    url: "/bpm/api/queryDoneTaskList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                     this.loading = false;
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //处理申请
+            dialogCheck(n) {
+                if ('广告申请' === n.procName) {
+                    this.typestatsu = 2;
+                } else if ("测试终端申请" === n.procName) {
+                    this.typestatsu = 1;
+                }
+                this.dialogStatus = true;
+                this.componentInfo = n;
+                this.componentStatus = true;
+            },
+            closeEdio() {
+                this.getList(this.params, this.pageSize);
+                this.dialogStatus = false;
+                this.componentStatus = false;
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+            getUser() {
+                this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+                this.infolist = {
+                    opNo: '',
+                    opName: '',
+                };
+                this.infolist.opNo = this.userInfo.loginNo;
+                this.infolist.opName = this.userInfo.loginName;
+
+            }
+        },
+        mounted() {
+            this.getList({}, 1);
+            this.getUser();
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .approval {
+        .roval-box {
+            padding: 0 20px;
+            margin-top: 20px;
+            margin-bottom: 10px;
+
+            .el-input {
+                width: calc(100% - 200px);
+                display: inline-block;
+            }
+
+            span {
+                display: inline-block;
+                width: 80px;
+                font-size: 14px;
+                margin-right: 20px;
+
+                .el-input {
+                    width: 100%;
+                    display: inline-block;
+                }
+            }
+        }
+    }
+
+    .onetab {
+        margin-bottom: 20px;
+        padding: 0 20px;
+    }
+
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 15px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+</style>

+ 198 - 0
src/pages/main/terminals/terminalStandbook.vue

@@ -0,0 +1,198 @@
+<template>
+    <fullscreen :fullscreen.sync="fullscreen" class="container" style="margin: 0;width: 100%;">
+        <div class="container-box" style="padding: 0 20px 0 0;">
+            <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
+            <div class="search">
+                <mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
+            </div>
+            <div class="tabbox">
+                <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData" tooltip-effect="dark"
+                    size="small" border style="width: 100%" v-loading="loading">
+                    <el-table-column prop="terminalTypeName" label="类别">
+                    </el-table-column>
+                    <el-table-column prop="brandName" label="品牌">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="型号">
+                    </el-table-column>
+                    <el-table-column prop="resId" label="终端编码" width="160">
+                    </el-table-column>
+                    <el-table-column prop="modelType" label="终端序列">
+                    </el-table-column>
+                    <el-table-column prop="opName" label="操作工号">
+                    </el-table-column>
+                    <el-table-column prop="opNo" label="操作姓名">
+                    </el-table-column>
+                    <el-table-column prop="opTime" label="操作时间">
+                    </el-table-column>
+                    <el-table-column prop="dealContent" label="内容">
+                    </el-table-column>
+                </el-table>
+                <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                    :total="total">
+                </el-pagination>
+            </div>
+        </div>
+    </fullscreen>
+</template>
+<script>
+    import toolList from '../../../components/toolList'
+    import mySearch from '../../../components/search'
+
+    export default {
+        components: {
+            toolList,
+            mySearch
+        },
+        data() {
+            return {
+                tooltit: '测试终端管理台账',
+                fullscreen: false,
+                total: 0,
+                pageSize: 1,
+                tableData: [{}],
+                searchList: [{
+                        type: 'input',
+                        tit: '类别',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '品牌',
+                        value: '',
+                        width: '32%',
+                    },
+                    {
+                        type: 'input',
+                        tit: '型号',
+                        value: '',
+                        width: '32%',
+                    },
+                ],
+                loading:false,
+                params:{}
+            }
+        },
+        methods: {
+            //搜索数据
+            searchInfo(v) {
+                this.params = {};
+                v[0] ? this.params.terminalTypeName = v[0] : '';
+                v[1] ? this.params.brandName = v[1] : '';
+                v[2] ? this.params.modelType = v[2] : '';
+                this.getList(this.params, this.pageSize);
+            },
+            //获取列表
+            getList(v, n) {
+                this.pageSize = n;
+                let _this = this;
+                this.tableData = [];
+                this.loading = true;
+                this.$http({
+                    url: "/market/terminal/terminalacct/queryPage",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                    },
+                    data: v,
+                }).then((res) => {
+                    this.tableData = res.data.data;
+                    this.total = res.data.totalRecord;
+                    this.loading = false;
+                });
+            },
+            // 分页
+            currchange(v) {
+                this.pageSize = v;
+                this.getList(this.params, this.pageSize);
+            },
+            //功能栏
+            iconCli(v) {
+                if (v === 1) {
+                    this.getList(this.params, this.pageSize);
+                }
+                if (v === 2) {
+                    this.fullscreen = !this.fullscreen
+                }
+            },
+        },
+        mounted() {
+            this.getList({}, 1);
+        },
+        created() {
+
+        }
+    }
+</script>
+<style scoped lang="scss">
+    .onetab {
+        margin-bottom: 20px;
+        padding: 0 20px;
+    }
+
+    .titbox {
+        div {
+            float: right;
+
+            i {
+                font-size: 22px;
+                margin-left: 20px;
+                cursor: pointer;
+            }
+        }
+    }
+
+    .tabbox {
+        margin-top: 15px;
+    }
+
+    .pageBox {
+        text-align: right;
+        margin-top: 10px;
+    }
+
+    .info-line {
+        width: 100%;
+        display: block;
+        padding-left: 20px;
+
+        div {
+            width: 50%;
+            display: inline-block;
+        }
+
+        span {
+            width: 80px;
+            display: inline-block;
+            text-align: left;
+
+            i {
+                color: red;
+                display: inline-block;
+                padding-right: 5px;
+            }
+        }
+
+        .el-select,
+        .el-input {
+            width: calc(100% - 100px);
+        }
+    }
+
+    .online {
+        width: 100%;
+
+        .el-select {
+            width: calc(100% - 100px);
+        }
+
+        span {
+            vertical-align: top;
+        }
+
+        .el-textarea {
+            width: calc(100% - 100px);
+        }
+    }
+</style>

+ 133 - 0
src/pages/main/terminals/terminalhome.vue

@@ -0,0 +1,133 @@
+<template>
+  <div class="inner-container">
+    <div class="tabBox">
+      <el-tabs v-model="activeName" @tab-click="handleClick">
+        <el-tab-pane
+          v-for="(item, index) in routerList"
+          :key="index"
+          :name="item.path"
+          :label="item.label"
+        >
+        </el-tab-pane>
+      </el-tabs>
+    </div>
+    <div class="infoBox">
+      <router-view />
+    </div>
+  </div>
+</template>
+<script>
+export default {
+  data() {
+    return {
+      activeName: "",
+      showList: [],
+      routerList: [
+        {
+          label: "测试终端管理",
+          path: "/terminal",
+          name: "terminal",
+        },
+        {
+          label: "测试终端申请",
+          path: "/terminalApply",
+          name: "terminalApply",
+        },
+        {
+          label: "终端型号管理",
+          path: "/terminalModel",
+          name: "terminalModel",
+        },
+        {
+          label: "终端台账管理",
+          path: "/terminalStandbook",
+          name: "terminalStandbook",
+        },
+      ],
+    };
+  },
+  computed: {
+    menuList: function () {
+      let arr = [];
+      this.routerList.map((item) => {
+        this.showList.map((row) => {
+          if (item.path == row) {
+            arr.push(item);
+          }
+        });
+      });
+      return arr;
+    },
+  },
+  methods: {
+    handleClick(val) {
+      if (this.$route.path != this.activeName) {
+        this.$router.push(this.activeName);
+      }
+    },
+  },
+  mounted() {
+    this.activeName = this.$route.path;
+  },
+  created() {
+    JSON.parse(sessionStorage.childrenMenus).map((item) => {
+      this.showList.push(item.jspUrl);
+    });
+  },
+  watch: {
+    $route(to, from) {
+      this.activeName = this.$route.path;
+    },
+  },
+};
+</script>
+<style lang="scss" scoped>
+
+.el-tabs__content {
+  display: none;
+}
+.inner-container {
+//   display: flex;
+//   justify-content: space-between;
+}
+.tabBox {
+  border-bottom: 1px solid #e1e1e1;
+  height: 55px;
+  margin-top: 10px;
+}
+.infoBox {
+  background: #f4f4f4 !important;
+  height: 100%;
+//   width: calc(100% - 135px);
+    margin-left: 20px;
+}
+::v-deep .el-tabs__item {
+  width: 166px;
+  text-align: center;
+  border-left: 10px solid #ffffff;
+  border-right: 10px solid #ffffff;
+  padding: 0;
+}
+::v-deep .el-tabs__header {
+  margin: 0px;
+  background: #d8eaf6;
+  color: black;
+  margin-left: 20px;
+  display: inline-block;
+}
+::v-deep .is-active {
+  background: #0583cd;
+  color: white;
+}
+
+::v-deep .el-tabs__item:hover {
+  color: black;
+}
+::v-deep .is-active:hover {
+  background: #0583cd;
+  color: white;
+}
+::v-deep .el-tabs__active-bar{
+		width: 0px !important;
+	}
+</style>

+ 188 - 0
src/pages/main/workflowdef/Import.vue

@@ -0,0 +1,188 @@
+<template>
+    <el-dialog title="导入" @close="closeDialog" :close-on-click-modal="false" v-if="visible" :visible.sync="visible" append-to-body>
+        <el-form style="margin-top:20px" :model="model" ref="form" @submit.native.prevent @keyup.enter.native="dataFormSubmit()" label-width="80px">
+            <el-form-item label="模板文件" prop="file" verify :maxLength="255" label-width="100px" class="is-required exportFile">
+                <el-input v-model="model.file" style="display:none;width:100%;height:100%"></el-input>
+                <div class="btnUpfileBox">
+                    <div class="filename">{{ this.model.file }}<span v-if="!this.model.file" style="color: rgb(204, 204, 204);">(请选择上传文件)</span></div>
+                    <el-button type="primary" @click="uploadTrigger">点击上传<i class="el-icon-upload el-icon--right"></i></el-button>
+                </div>
+                <input type="file" @change="onDataFileSelect" style="display:none;width:100%;height:100%" ref="upFilesDataRef" />
+            </el-form-item>
+            <el-form-item label="模板名称" prop="name" verify :maxLength="255" label-width="100px" class="is-required">
+                <el-input v-model="model.name"></el-input>
+            </el-form-item>
+            <el-form-item label="模板key" prop="key" verify :maxLength="255" label-width="100px" class="is-required">
+                <el-input v-model="model.key"></el-input>
+            </el-form-item>
+            <el-form-item label="模型描述" prop="description" class="is-required" verify label-width="100px" :maxLength="200">
+                <el-input type="textarea" v-model="model.description"></el-input>
+            </el-form-item>
+            <el-form-item label="模型分类" verify can-be-empty label-width="100px" :maxLength="200">
+                <el-input  v-model="model.category"></el-input>
+            </el-form-item>
+        </el-form>
+        <span slot="footer" class="dialog-footer">
+            <el-button type="primary" @click="dataFormSubmit()">确定</el-button>
+            <el-button @click="visible = false">关闭</el-button>
+        </span>
+    </el-dialog>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            formAction: 0, //0 add,//1,edit
+            visible: false,
+            title: '添加',
+            disabled: false,
+            btn: '提交',
+            aproveVisible: false,
+            model: {
+                file: '',
+                name: '',
+                key: '',
+                description: '',
+                category: ''
+            },
+            filesData: '',
+            filename: ''
+        }
+    },
+    created() {},
+    activated() {},
+    methods: {
+        init(id) {
+            Object.assign(this.$data, this.$options.data.call(this))
+            this.visible = true
+
+            if (id) {
+                let self = this
+                var obj = {
+                    url: this.$url.workflowdef.getById,
+                    data: {
+                        id: id
+                    }
+                }
+                this.common.httpPost(obj, success)
+                function success(data) {
+                    self.model = data.data
+                    self.model.description = self.model.desc
+                }
+            } else {
+                this.model = {}
+                self.formAction = 0
+
+                // self.$nextTick(() => {
+                //   self.$refs.form.resetFields();
+                //   self.formAction = 0;
+                // })
+            }
+        },
+        uploadTrigger() {
+            this.$refs.upFilesDataRef.click()
+        },
+        // 上传科研数据的事件
+        onDataFileSelect(e) {
+            // if (this.$refs.upFilesDataRef.value.indexOf('.txt') != -1) return this.$message('不支持.txt格式的文件 ')
+            var f = e.target.files || e.dataTransfer.files
+            if (!f.length) return
+            this.filesData = f[0]
+            console.log(this.filesData)
+
+            // 上传进度
+            var _this = this
+            this.$refs.upFilesDataRef.onchange = function() {
+                var fr = new FileReader()
+                fr.readAsDataURL(this.files[0])
+                var total = this.files[0].size
+                fr.onprogress = function(ev) {
+                    _this.percentage = parseInt((ev.loaded / total) * 100) + '%'
+                    console.log(_this.percentage)
+                    if (_this.percentage == '100%') {
+                        _this.$set(_this.model, 'file', _this.filesData.name)
+                    }
+                }
+            }
+            this.$refs.upFilesDataRef.onchange()
+        },
+        closeDialog() {
+            this.$refs.form.resetFields()
+            this.filesData = ''
+            this.$refs.upFilesDataRef.value = ''
+        },
+        dataFormSubmit() {
+            let self = this
+            self.$refs['form'].validate(async valid => {
+                if (valid) {
+                    var formdata = new FormData()
+                    // form.append('name', this.model.name)
+                    // form.append('key', this.model.name)
+                    // form.append('description', this.model.name)
+                    // form.append('category', this.model.name)
+                    if (!this.model.file) return this.$message.error('请检查您的文件!')
+                    formdata.append('file', this.filesData)
+                    console.log(this.filesData)
+                    delete this.model.file
+                    var obj = {
+                        url: this.$url.processinst.exportFile,
+                        data: this.model
+                    }
+                    const  {data:res} = await this.common.postRequestHybid(obj, formdata)
+                    console.log(res)
+                    if(res.code!==1) return this.$message.error('导入失败!')
+                    this.$emit('change')
+                    // let model = self.model
+                    // var obj = {
+                    //     url: this.$url.workflowdef.add,
+                    //     data: self.model
+                    // }
+                    // this.common.httpPost(obj, success)
+                    // function success(data) {
+                    //     self.$notify.success({
+                    //         title: '',
+                    //         message: '操作成功!'
+                    //     })
+                    //     self.$parent.editFormVisible = false
+                    //     self.$parent.doSearch(1)
+                    // }
+                } else {
+                    self.$notify.error({
+                        title: '错误',
+                        message: '系统输入验证失败!'
+                    })
+                    return false
+                }
+            })
+        }
+    }
+}
+</script>
+<style>
+.exportFile input {
+    border: none !important;
+    /* width: 75px;
+    height: 25px;
+    opacity: 0;
+    filter: alpha(opacity=0);
+    background-color: lawngreen; */
+}
+.btnUpfileBox {
+    display: flex;
+}
+.btnUpfileBox .filename {
+    width: 300px;
+    margin-right: 10px;
+}
+.btnUpfileBox .btnUpfile {
+    width: 100px;
+    height: 100%;
+    background-color: #409eff;
+}
+.btnUpfileBox span {
+    display: inline-block;
+    width: 100%;
+    text-align: right;
+}
+</style>

+ 0 - 0
src/pages/main/workflowdef/codeView.vue


+ 45 - 0
src/pages/main/workflowdef/design.vue

@@ -0,0 +1,45 @@
+
+<template>
+<el-dialog @close="close" ref='dailog' title="流程设计" :close-on-click-modal="false"  v-if="visible" :visible.sync="visible" width="80%" height="100%" append-to-body>
+  <div>
+    <iframe :src="designSrc" id="show-iframe" frameborder=0 name="showHere" scrolling=auto :height="iframeHeight" width="100%" />
+  </div>
+</el-dialog>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      designSrc: null,
+      visible: false, title:"添加",
+      disabled:false,
+      btn:"提交",
+      aproveVisible: false,
+      iframeHeight:'800px',
+    };
+  },
+  created() {
+
+
+  },
+  activated() {},
+  mounted(){
+  this.$nextTick(() => {
+      //const deviceWidth = document.documentElement.clientWidth;
+      const deviceHeight = document.documentElement.clientHeight;
+      this.iframeHeight = (deviceHeight-125) + 'px';
+    })
+},
+  methods: {
+    init(id) {
+        Object.assign(this.$data, this.$options.data.call(this))
+      this.visible = true;
+      this.designSrc =this.$url.workflowdef.modeler+id;// window.SITE_CONFIG.wfDesingUrl + id;
+    },
+    close(){
+      this.$parent.doSearch(1)
+    }
+  }
+  }
+  </script>

+ 105 - 0
src/pages/main/workflowdef/edit.vue

@@ -0,0 +1,105 @@
+
+<template>
+<el-dialog :title="formAction == 0 ? '新增' : '修改'" :close-on-click-modal="false" v-if="visible" :visible.sync="visible" append-to-body>
+  <el-form :model="model" ref="form" @submit.native.prevent  @keyup.enter.native="dataFormSubmit()" label-width="80px">
+    <el-form-item label="标识" prop="key" verify :maxLength="255" class="is-required">
+      <el-input v-model="model.key"></el-input>
+    </el-form-item>
+
+    <el-form-item label="名称" prop="name" verify :maxLength="255" class="is-required">
+      <el-input v-model="model.name"></el-input>
+    </el-form-item>
+    <!-- <el-form-item label="分类" prop="category" verify :maxLength="255" class="is-required">
+      <el-input v-model="model.category"></el-input>
+    </el-form-item> -->
+    <el-form-item label="描述" prop="description" verify can-be-empty :maxLength="200">
+      <el-input type="textarea" v-model="model.description"></el-input>
+    </el-form-item>
+
+  </el-form>
+  <span slot="footer" class="dialog-footer">
+      <el-button type="primary" @click="dataFormSubmit()">确定</el-button>
+      <el-button @click="visible = false">关闭</el-button>
+    </span>
+</el-dialog>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      formAction: 0, //0 add,//1,edit
+      visible: false, title:"添加",
+      disabled:false,
+      btn:"提交",
+      aproveVisible: false,
+      model: {
+
+      },
+    };
+  },
+  created() {
+
+  },
+  activated() {},
+  methods: {
+    init(id) {
+        Object.assign(this.$data, this.$options.data.call(this))
+      this.visible = true;
+
+      if (id) {
+        let self = this;
+        var obj ={
+          url:this.$url.workflowdef.getById,
+          data:{
+            id:id
+          }
+        }
+        this.common.httpPost(obj,success);
+        function success(data){
+           self.model = data.data
+            self.model.description = self.model.desc
+        }
+
+      }else{
+        this.model = {};
+        self.formAction = 0;
+
+        // self.$nextTick(() => {
+        //   self.$refs.form.resetFields();
+        //   self.formAction = 0;
+        // })
+      }
+    },
+    dataFormSubmit() {
+      let self = this;
+      self.$refs['form'].validate((valid) => {
+        if (valid) {
+          let model = self.model;
+          var obj ={
+            url:this.$url.workflowdef.add,
+            data:self.model
+          }
+          this.common.httpPost(obj,success);
+          function success(data){
+              self.$notify.success({
+                title: '',
+                message: '操作成功!'
+              });
+              self.$parent.editFormVisible = false;
+              self.$parent.doSearch(1)
+          }
+
+        } else {
+          self.$notify.error({
+            title: '错误',
+            message: '系统输入验证失败!'
+          });
+          return false;
+        }
+      });
+    },
+
+  }
+  }
+  </script>

+ 294 - 0
src/pages/main/workflowdef/index.vue

@@ -0,0 +1,294 @@
+<template>
+    <div class="container">
+        <div class="mod-role" style="height:100%;overflow:auto;">
+            <el-form :inline="true" @submit.native.prevent @keyup.enter.native="doSearch(1)" style="margin:20px 0px 0px 10px">
+                <el-form-item>
+                    <el-input v-model="form.searchKey" placeholder="模型名称" clearable></el-input>
+                </el-form-item>
+                <el-form-item>
+                    <el-button icon="el-icon-search" type="primary" @click="doSearch(1)">查询</el-button>
+                    <el-button icon="el-icon-plus" type="primary" @click="doNew()">新增</el-button>
+                    <el-button icon="el-icon-upload2" type="primary" @click="doImport()">导入</el-button>
+                    <!-- <el-button icon="el-icon-upload2" type="primary" @click="doImport()">导入</el-button>
+                    <el-button icon="el-icon-download" type="primary" @click="download()">导出</el-button> -->
+                    <!-- 暂时禁用批量删除
+      <el-button icon="el-icon-delete" type="danger" @click="doBatchDelete()" :disabled="selectedRows.length <= 0">批量删除</el-button>
+      -->
+
+                    <!-- <el-button icon="el-icon-download" @click="doExportExcel()">导出</el-button> -->
+                </el-form-item>
+            </el-form>
+            <el-table  @selection-change="handleSelectionChange" :data="list" border ref="searchReulstList"  style="width: 100%">
+                <el-table-column align="center" type="selection" width="55"> </el-table-column>
+                <el-table-column align="center" type="index" :index="index" label="行数" width="50"></el-table-column>
+                <!-- <el-table-column align="center"  prop="key" label="模型标志" width="180"></el-table-column> -->
+                <el-table-column align="center" prop="name" label="模型名称"></el-table-column>
+                <el-table-column align="center" prop="metaInfo" label="描述">
+                    <template slot-scope="scope">
+                        {{ scope.row.metaInfo ?JSON.parse(scope.row.metaInfo).description : '' }}
+                    </template>
+                </el-table-column>
+                <!-- <el-table-column align="center"  prop="category" label="分类" ></el-table-column> -->
+                <el-table-column align="center" prop="createTime" :formatter="$util.YYMM" label="时间"></el-table-column>
+                <el-table-column align="center" prop="lastUpdateTime" :formatter="$util.YYMM" label="最后更新时间"></el-table-column>
+                <el-table-column align="center" label="操作" fixed="right" width="250">
+                    <template slot-scope="scope">
+                        <!-- <el-button @click="doEdit(scope)" type="text" size="small">查看</el-button> -->
+                        <el-button @click="doCopy(scope)" type="text" size="small">复制</el-button>
+                        <el-button @click="doDesign(scope)" type="text" size="small">设计</el-button>
+                        <el-button @click="doDeploy(scope)" type="text" size="small">部署</el-button>
+                        <el-button @click="doDelete(scope)" type="text" size="small">删除</el-button>
+                        <!-- <el-button @click="dd" type="text" size="small">下载</el-button>
+        <el-button @click="dd" type="text" size="small">上传</el-button> -->
+                    </template>
+                </el-table-column>
+            </el-table>
+            <el-pagination style="margin:10px 10px 0px 10px;float:right" @current-change="doSearch"  :page-size="form.rows" layout="total, prev, pager, next, jumper" :total="total"> </el-pagination>
+            <!-- <t-grid ref="searchReulstList" :options="gridOptions" @selection-change="handleSelectionChange">
+  </t-grid> -->
+            <!-- 弹窗, 新增 / 修改 -->
+            <edit-form v-if="editFormVisible" ref="editForm" @change="doSearch(1)"></edit-form>
+            <import-form v-if="importFormVisible" ref="importForm" @change="doSearch(1)"></import-form>
+            <design-form v-if="designFormVisible" ref="designForm"></design-form>
+            <code-view-form v-if="codeViewFormVisible" ref="codeViewForm"></code-view-form>
+        </div>
+    </div>
+</template>
+
+<script>
+import EditForm from './edit'
+import DesignForm from './design'
+import CodeViewForm from './codeView'
+import ImportForm from './Import'
+import AproveStep from '../comWin/aproveStep'
+// 重发代办
+export default {
+    data() {
+        return {
+            editFormVisible: false,
+            designFormVisible: false,
+            codeViewFormVisible: false,
+            uploadFormVisible: false,
+            importFormVisible: false,
+            selectedRows: [],
+            index(i) {
+                return ++i
+            },
+            total: 0,
+            list: [],
+            form: {
+                page: 1,
+                rows: 10,
+                searchKey: ''
+            }
+        }
+    },
+    components: {
+        EditForm,
+        AproveStep,
+        DesignForm,
+        CodeViewForm,
+        ImportForm
+    },
+    created() {
+        this.doSearch(1)
+    },
+    methods: {
+        YYMM(row, column, cellValue) {
+            return this.$util.datetimeFormat(cellValue)
+        },
+        doSearch(value) {
+            this.importFormVisible = false
+            this.form.page = value
+
+            let self = this
+            var obj = {
+                url: this.$url.workflowdef.getList,
+                data: this.form,
+                type: 'post'
+            }
+            this.common.httpPost(obj, success)
+            function success(data) {
+                self.list = data.data.rows
+                self.total = data.data.total
+            }
+        },
+        doImport() {
+            this.importFormVisible = true
+            this.$nextTick(() => {
+                console.log(this)
+                this.$refs.importForm.init(null)
+            })
+        },
+        doNew() {
+            this.editFormVisible = true
+            this.$nextTick(() => {
+                this.$refs.editForm.init(null)
+            })
+        },
+        // doImport() {
+        //     this.importFormVisible = true
+        //     this.$nextTick(() => {
+        //         console.log(this)
+        //         this.$refs.importForm.init(null)
+        //     })
+        // },
+        doEdit(row) {
+            this.editFormVisible = true
+
+            this.$nextTick(() => {
+                this.$refs.editForm.init(row.row.id)
+            })
+        },
+
+        doCopy(row) {
+            row = row.row
+            let self = this
+            var obj = {
+                url: this.$url.workflowdef.copyById,
+                data: {
+                    id: row.id
+                }
+            }
+            this.common.httpPost(obj, success)
+            function success(data) {
+                self.$notify.success({
+                    title: '操作成功',
+                    message: '模型已复制成功!'
+                })
+                self.doSearch(1)
+            }
+            // tapp.services.wf_Model.copy(row.id).then(function(result) {
+            //   self.$notify.success({
+            //     title: '操作成功',
+            //     message: '模型已复制成功!'
+            //   });
+            //   self.$refs.searchReulstList.refresh();
+            // })
+        },
+        doDesign(row) {
+            row = row.row
+            this.designFormVisible = true
+            this.$nextTick(() => {
+                this.$refs.designForm.init(row.id)
+            })
+        },
+        doViewCode(row) {
+            this.codeViewFormVisible = true
+            console.log(row)
+            this.$nextTick(() => {
+                this.$refs.codeViewForm.init(row.key)
+            })
+        },
+        download() {
+            console.log(this.$url)
+            window.location.href = this.$url.workflowdef.getExportFile
+        },
+        doDeploy(row) {
+            row = row.row
+            let self = this
+            var obj = {
+                url: this.$url.workflowdef.deploy,
+                data: {
+                    modelId: row.id
+                }
+            }
+            this.common.httpPost(obj, success)
+            function success(data) {
+                self.$notify.success({
+                    title: '操作成功',
+                    message: '模型已部署成功!'
+                })
+                self.doSearch(1)
+            }
+        },
+        doDelete(row) {
+            row = row.row
+            let self = this
+            var obj = {
+                url: this.$url.workflowdef.deleteModelById,
+                data: {
+                    id: row.id
+                }
+            }
+            this.common.httpPost(obj, success)
+            function success(data) {
+                self.$notify.success({
+                    title: '操作成功',
+                    message: '模型已删除!'
+                })
+                self.doSearch(1)
+            }
+        },
+        handleSelectionChange(val) {
+            this.selectedRows = val
+        },
+
+        doBatchDelete() {
+            let self = this
+            if (!self.selectedRows || self.selectedRows.length == 0) {
+                self.$notify.info({
+                    title: '系统提示',
+                    message: '您没选择任何行,无法操作!'
+                })
+                return
+            }
+            let ids = new Array()
+            // ids[0] = '5';
+            // for(let i=0;i<self.selectedRows.length;i++){
+            //   ids.push(self.selectedRows[i].id)
+            // }
+            self.selectedRows.map(function(row) {
+                ids.push(row.id)
+            })
+            ids = ids.join(',')
+            console.log(ids)
+            self.$confirm('此操作将永久删除' + ids.length + '个模型, 是否继续?', '提示', {
+                confirmButtonText: '确定',
+                cancelButtonText: '取消',
+                type: 'warning'
+            }).then(() => {
+                var obj = {
+                    url: this.$url.workflowdef.del,
+                    data: {
+                        ids: ids
+                    }
+                }
+                this.common.httpPost(obj, success)
+                function success(data) {
+                    self.$notify.success({
+                        title: '操作成功',
+                        message: '模型已删除成功!'
+                    })
+                    self.doSearch(1)
+                }
+            })
+        },
+        doExportExcel() {
+            this.$refs.searchReulstList.exportCSV('模型列表')
+        }
+        // ,
+        // doSearch(value) {
+        //   this.form.page = value;
+
+        // let self = this;
+        // var obj ={
+        //   url:this.$url.workflowdef.getList,
+        //   data:this.form
+        // }
+        // this.common.httpPost(obj,success);
+        // function success(data){
+
+        //     self.list = data.data.rows
+        //     self.total = data.data.total
+
+        // }
+        // }
+    }
+}
+</script>
+<style lang="scss" scoped>
+::v-deep .el-table td, .el-table th{
+    padding: 3px 0px;
+}
+</style>

+ 4 - 0
src/plugins/element-ui.js

@@ -59,14 +59,18 @@ import {
 	ColorPicker,
 	RadioButton,
 	Drawer,
+	Descriptions,
 	Badge,
 	TimePicker,
+	DescriptionsItem,
 	Alert,
 	InputNumber,
 	Rate,
 	Progress
 } from 'element-ui';
+Vue.use(DescriptionsItem);
 Vue.use(TimePicker);
+Vue.use(Descriptions);
 Vue.use(Badge);
 Vue.use(Drawer);
 Vue.use(RadioButton);

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 737 - 671
src/router/index.js


+ 2 - 1
vue.config.js

@@ -135,7 +135,8 @@ module.exports = {
                 // target: 'http://192.168.0.156:9600/',
                 // target: 'http://192.168.2.170:9600/',
                 // target: 'http://192.168.2.169:9600/',
-                target: "http://192.168.2.124:9600",
+                // target: "http://124.223.66.248:9600",
+                target: "http://43.138.50.94:9600",
                 changeOrigin: true,
             },
         },

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 10406 - 0
yarn.lock