Ver código fonte

Merge branch 'master' into feature/Feature-return

莫绍宝 3 anos atrás
pai
commit
68f7867e8e

Diferenças do arquivo suprimidas por serem muito extensas
+ 1 - 21040
package-lock.json


+ 1 - 0
package.json

@@ -19,6 +19,7 @@
     "core-js": "3.6.5",
     "echarts": "^5.1.1",
     "element-ui": "2.13.2",
+    "file-saver": "^2.0.5",
     "js-cookie": "2.2.0",
     "normalize.css": "7.0.0",
     "nprogress": "0.2.0",

+ 225 - 209
src/api/setting.js

@@ -1,469 +1,485 @@
-import request from '@/utils/request'
+import request from "@/utils/request";
 
 // 获取个人信息
 export function getUserInfo(params) {
   return request({
-    url: '/admin/user/detail',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 修改密码
 export function changePassword(params) {
   return request({
-    url: '/admin/user/password/update',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/password/update",
+    method: "post",
+    params,
+  });
 }
 
 // 获取账户列表
 export function getAccountList(params) {
   return request({
-    url: '/admin/user/list',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/list",
+    method: "get",
+    params,
+  });
 }
 
 // 获取角色列表
 export function getRoleList(params) {
   return request({
-    url: '/admin/role/list',
-    method: 'get',
-    params
-  })
+    url: "/admin/role/list",
+    method: "get",
+    params,
+  });
 }
 
 // 重置密码
 export function resetPassword(params) {
   return request({
-    url: '/admin/user/password/reset',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/password/reset",
+    method: "post",
+    params,
+  });
 }
 
 // 更改账户状态
 export function changeAccountStatus(params) {
   return request({
-    url: '/admin/user/status/update',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/status/update",
+    method: "post",
+    params,
+  });
 }
 
 // 新增账户
 export function addAccount(params) {
   return request({
-    url: '/admin/user/add',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/user/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 编辑账户
 export function editAccount(params) {
   return request({
-    url: '/admin/user/user/update',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/user/user/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 获取账户详情
 export function getAccountDetail(params) {
   return request({
-    url: '/admin/user/detail',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 获取字段列表
 export function getFieldList(params) {
   return request({
-    url: '/sys/dict/list/page',
-    method: 'get',
-    params
-  })
+    url: "/sys/dict/list/page",
+    method: "get",
+    params,
+  });
 }
 
 // 更改字段状态
 export function changeFieldStatus(params) {
   return request({
-    url: '/sys/dict/status/update',
-    method: 'post',
-    params
-  })
+    url: "/sys/dict/status/update",
+    method: "post",
+    params,
+  });
 }
 
 // 删除字段
 export function deleteField(params) {
   return request({
-    url: '/sys/dict/delete',
-    method: 'post',
-    params
-  })
+    url: "/sys/dict/delete",
+    method: "post",
+    params,
+  });
 }
 
 // 新增字段
 export function addField(params) {
   return request({
-    url: '/sys/dict/add',
-    method: 'post',
-    params
-  })
+    url: "/sys/dict/add",
+    method: "post",
+    params,
+  });
 }
 
 // 编辑字段
 export function editField(params) {
   return request({
-    url: '/sys/dict/update',
-    method: 'post',
-    params
-  })
+    url: "/sys/dict/update",
+    method: "post",
+    params,
+  });
 }
 
 // 获取字段详情
 export function getFieldDetail(params) {
   return request({
-    url: '/sys/dict/detail',
-    method: 'get',
-    params
-  })
+    url: "/sys/dict/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 获取操作日志列表
 export function getOplogList(params) {
   return request({
-    url: '/admin/operation/log/list',
-    method: 'get',
-    params
-  })
+    url: "/admin/operation/log/list",
+    method: "get",
+    params,
+  });
 }
 
 // 检查工程机帐号是否有效
 export function checkEngineAccount() {
   return request({
-    url: '/admin/user/engin/checkuser',
-    method: 'post'
-  })
+    url: "/admin/user/engin/checkuser",
+    method: "post",
+  });
 }
 
 // 绑定工程机帐号
 export function bindEngineAccount(params) {
   return request({
-    url: '/admin/user/engin/bind',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/engin/bind",
+    method: "post",
+    params,
+  });
 }
 
 // 删除工程机帐号
 export function delEngineAccount(params) {
   return request({
-    url: '/admin/user/engin/account/del',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/engin/account/del",
+    method: "post",
+    params,
+  });
 }
 
 // 更改轮播图状态
 export function changeBannerStatus(params) {
   return request({
-    url: '/carouselMap/state/update',
-    method: 'post',
-    params
-  })
+    url: "/carouselMap/state/update",
+    method: "post",
+    params,
+  });
 }
 
 // 删除轮播图
 export function deleteBanner(params) {
   return request({
-    url: '/carouselMap/delete',
-    method: 'post',
-    params
-  })
+    url: "/carouselMap/delete",
+    method: "post",
+    params,
+  });
 }
 
 // 新增轮播图
 export function addBanner(params) {
   return request({
-    url: '/carouselMap/add',
-    method: 'post',
-    data: params
-  })
+    url: "/carouselMap/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 编辑轮播图
 export function editBanner(params) {
   return request({
-    url: '/carouselMap/update',
-    method: 'post',
-    data: params
-  })
+    url: "/carouselMap/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 获取轮播图详情
 export function getBannerDetail(params) {
   return request({
-    url: '/carouselMap/detail',
-    method: 'get',
-    params
-  })
+    url: "/carouselMap/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 新增角色
 export function addRole(params) {
   return request({
-    url: '/admin/role/add',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/role/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 编辑角色
 export function editRole(params) {
   return request({
-    url: '/admin/role/update',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/role/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 删除角色
 export function deleteRole(params) {
   return request({
-    url: '/admin/role/delete',
-    method: 'post',
-    params
-  })
+    url: "/admin/role/delete",
+    method: "post",
+    params,
+  });
 }
 
-
 // 获取角色详情
 export function getRoleDetail(params) {
   return request({
-    url: '/admin/role/detail',
-    method: 'get',
-    params
-  })
+    url: "/admin/role/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 获取权限列表
 export function getMenuRoleList(params) {
   return request({
-    url: '/admin/user/module/all',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/module/all",
+    method: "get",
+    params,
+  });
 }
 
 // 获取已选权限数组
 export function getMenuRoleIds(params) {
   return request({
-    url: '/admin/user/module/id/checked',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/module/id/checked",
+    method: "get",
+    params,
+  });
 }
 
 // 提交设置权限
 export function setMenuRole(params) {
   return request({
-    url: '/admin/user/module/grant',
-    method: 'post',
-    params
-  })
+    url: "/admin/user/module/grant",
+    method: "post",
+    params,
+  });
 }
 
 // 获取商品列表
 export function getGoodsList(params) {
   return request({
-    url: '/carouselMap/list/goods',
-    method: 'get',
-    params
-  })
+    url: "/carouselMap/list/goods",
+    method: "get",
+    params,
+  });
 }
 
 // 批量删除轮播图
 export function batchDeleteBanner(params) {
   return request({
-    url: '/carouselMap/batch/delete',
-    method: 'post',
-    data: params
-  })
+    url: "/carouselMap/batch/delete",
+    method: "post",
+    data: params,
+  });
 }
 
 // 获取通告
 export function getNotice(params) {
   return request({
-    url: '/notice/mini/select',
-    method: 'get',
-    params
-  })
+    url: "/notice/mini/select",
+    method: "get",
+    params,
+  });
 }
 
 // 新增通告
 export function addNotice(params) {
   return request({
-    url: '/notice/mini/add',
-    method: 'post',
-    data: params
-  })
+    url: "/notice/mini/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 编辑通告
 export function editNotice(params) {
   return request({
-    url: '/notice/mini/update',
-    method: 'post',
-    data: params
-  })
+    url: "/notice/mini/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 获取菜单列表
 export function getMenuList(params) {
   return request({
-    url: '/admin/user/module/list',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/module/list",
+    method: "get",
+    params,
+  });
 }
 
 // 添加菜单
 export function addMenu(params) {
   return request({
-    url: '/admin/module/add',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/module/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 编辑菜单
 export function editMenu(params) {
   return request({
-    url: '/admin/module/update',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/module/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 删除菜单
 export function deleteMenu(params) {
   return request({
-    url: '/admin/module/delete',
-    method: 'post',
-    params
-  })
+    url: "/admin/module/delete",
+    method: "post",
+    params,
+  });
 }
 
 // 获取菜单详情
 export function getMenuDetail(params) {
   return request({
-    url: '/admin/module/detail',
-    method: 'get',
-    params
-  })
+    url: "/admin/module/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 获取商户列表
 export function getMerchantList(params) {
   return request({
-    url: '/admin/user/mch/list',
-    method: 'get',
-    params
-  })
+    url: "/admin/user/mch/list",
+    method: "get",
+    params,
+  });
 }
 
 // 获取经销商列表
 export function getDealerList(params) {
   return request({
-    url: '/customer/list',
-    method: 'get',
-    params
-  })
+    url: "/customer/list",
+    method: "get",
+    params,
+  });
 }
 
 // 获取用户协议
 export function getAgreement(params) {
   return request({
-    url: '/admin/company/other/getOne',
-    method: 'get',
-    params
-  })
+    url: "/admin/company/other/getOne",
+    method: "get",
+    params,
+  });
 }
 
 // 更新用户协议
 export function editAgreement(params) {
   return request({
-    url: '/admin/company/other/update',
-    method: 'post',
-    params
-  })
+    url: "/admin/company/other/update",
+    method: "post",
+    params,
+  });
 }
 
 // 获取部门列表
 export function getDepartmentList(params) {
   return request({
-    url: '/admin/websit/tree',
-    method: 'get',
-    params
-  })
+    url: "/admin/websit/tree",
+    method: "get",
+    params,
+  });
 }
 
 // 添加部门
 export function addDepartment(params) {
   return request({
-    url: '/admin/websit/add',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/websit/add",
+    method: "post",
+    data: params,
+  });
 }
 
 // 修改部门
 export function editDepartment(params) {
   return request({
-    url: '/admin/websit/update',
-    method: 'post',
-    data: params
-  })
+    url: "/admin/websit/update",
+    method: "post",
+    data: params,
+  });
 }
 
 // 删除部门
 export function deleteDepartment(params) {
   return request({
-    url: '/admin/websit/delete',
-    method: 'post',
-    params
-  })
+    url: "/admin/websit/delete",
+    method: "post",
+    params,
+  });
 }
 
 // 获取部门详情
 export function getDepartmentDetail(params) {
   return request({
-    url: '/admin/websit/detail',
-    method: 'get',
-    params
-  })
+    url: "/admin/websit/detail",
+    method: "get",
+    params,
+  });
 }
 
 // 获取接口状态列表
 export function getApiList(params) {
   return request({
-    url: '/common/interface/list',
-    method: 'get',
-    params
-  })
+    url: "/common/interface/list",
+    method: "get",
+    params,
+  });
 }
 
 // 仓库仓位对应关系列表
 export function getStockListStock(params) {
   return request({
-    url: '/stock/listStock',
-    method: 'get',
-    params
-  })
+    url: "/stock/listStock",
+    method: "get",
+    params,
+  });
+}
+
+// 新建经销商子账号
+export function addSubAccount(params) {
+  return request({
+    url: "/admin/user/user/child/add",
+    method: "post",
+    params,
+  });
+}
+// 新建经销商子账号
+export function editSubAccount(params) {
+  return request({
+    url: "/admin/user/user/child/update",
+    method: "post",
+    params,
+  });
 }

+ 4 - 3
src/components/Common/image-upload.vue

@@ -205,11 +205,12 @@ export default {
       const suffix = file.name.match(/.[^.]+$/)[0]
       // 押金申请上传限制
       if (this.startRestricting) {
-        console.log(this.restrictFilename.join(''))
-        if (fileName.includes(this.restrictFilename.join('')) === -1 || suffix.includes('zip', 'rar', 'gz', 'apk')) {
+        const filterKeywords = this.restrictFilename.filter(k => fileName.includes(k))
+        console.log(filterKeywords)
+        if (!filterKeywords.length || suffix.includes('zip', 'rar', 'gz', 'apk')) {
           this.fileName = `其他文件${suffix}`
-          console.log(this.fileName, '4454')
         }
+        
       }
 
       this.$emit('handleIsFileName', file.name)

+ 133 - 75
src/utils/util.js

@@ -1,6 +1,6 @@
-
-import axios from 'axios'
-import { getToken } from '@/utils/auth'
+import axios from "axios";
+import FileSaver from "file-saver";
+import { getToken } from "@/utils/auth";
 
 /**
  * 删除对象中的空值
@@ -8,10 +8,14 @@ import { getToken } from '@/utils/auth'
  * @returns {Object}
  */
 export function deleteEmptyObj(obj) {
-  let newObj = obj;
-  for(var key in newObj) {
-    if(newObj[key] === '' || newObj[key] === null || newObj[key] === undefined) {
-      delete newObj[key]
+  const newObj = obj;
+  for (var key in newObj) {
+    if (
+      newObj[key] === "" ||
+      newObj[key] === null ||
+      newObj[key] === undefined
+    ) {
+      delete newObj[key];
     }
   }
   return newObj;
@@ -27,7 +31,7 @@ export function deleteEmptyObj(obj) {
 export function findElem(array, attr, val) {
   for (var i = 0; i < array.length; i++) {
     if (array[i][attr] == val) {
-        return i; //返回当前索引值
+      return i; // 返回当前索引值
     }
   }
   return -1;
@@ -40,15 +44,19 @@ export function findElem(array, attr, val) {
  * @returns
  */
 export function createParamsUrl(url, params) {
-  if(typeof(url) == 'undefined' || url == null || url == '') {
-    return '';
+  if (typeof url === "undefined" || url == null || url == "") {
+    return "";
   }
-  if(typeof(params) == 'undefined' || params == null || typeof(params) != 'object') {
-    return '';
+  if (
+    typeof params === "undefined" ||
+    params == null ||
+    typeof params !== "object"
+  ) {
+    return "";
   }
-  url += (url.indexOf("?") != -1) ? "" : "?";
-  for(var k in params) {
-    url += ((url.indexOf("=") != -1) ? "&" : "") + k + "=" + encodeURI(params[k]);
+  url += url.indexOf("?") != -1 ? "" : "?";
+  for (var k in params) {
+    url += (url.indexOf("=") != -1 ? "&" : "") + k + "=" + encodeURI(params[k]);
   }
   return url;
 }
@@ -58,10 +66,10 @@ export function createParamsUrl(url, params) {
  * @param {*} obj
  * @returns
  */
-export function downloadFiles(url, params={}) {
+export function downloadFiles(url, params = {}) {
   params.token = getToken();
-  let newParams = deleteEmptyObj(params);
-  let newUrl = createParamsUrl(url, newParams);
+  const newParams = deleteEmptyObj(params);
+  const newUrl = createParamsUrl(url, newParams);
   window.open(process.env.VUE_APP_BASE_API + newUrl);
 }
 
@@ -72,16 +80,24 @@ export function downloadFiles(url, params={}) {
  */
 export async function handleImport(url, formData) {
   const Result = await new Promise((resolve, reject) => {
-    axios.post(
-      process.env.VUE_APP_BASE_API + url,
-      formData,
-      
-      {headers: { 'Content-Type': 'multipart/form-data', 'x-token': getToken() } })
-    .then(res => {
-      resolve(res.data)
-    }).catch(err => {
-      reject(err)
-    })
+    axios
+      .post(
+        process.env.VUE_APP_BASE_API + url,
+        formData,
+
+        {
+          headers: {
+            "Content-Type": "multipart/form-data",
+            "x-token": getToken(),
+          },
+        }
+      )
+      .then((res) => {
+        resolve(res.data);
+      })
+      .catch((err) => {
+        reject(err);
+      });
   });
   return Result;
 }
@@ -92,16 +108,25 @@ export async function handleImport(url, formData) {
  */
 export async function handleImportTwo(url, formData) {
   const Result = await new Promise((resolve, reject) => {
-    axios.post(
-      process.env.VUE_APP_BASE_API + url,
-      formData,
-      
-      { responseType: 'arraybuffer',headers: { 'Content-Type': 'multipart/form-data', 'x-token': getToken() } })
-    .then(res => {
-      resolve(res.data)
-    }).catch(err => {
-      reject(err)
-    })
+    axios
+      .post(
+        process.env.VUE_APP_BASE_API + url,
+        formData,
+
+        {
+          responseType: "arraybuffer",
+          headers: {
+            "Content-Type": "multipart/form-data",
+            "x-token": getToken(),
+          },
+        }
+      )
+      .then((res) => {
+        resolve(res.data);
+      })
+      .catch((err) => {
+        reject(err);
+      });
   });
   return Result;
 }
@@ -112,11 +137,13 @@ export async function handleImportTwo(url, formData) {
  * @param {*} type
  */
 export function resetDateFormat(date, type) {
-  let newDate = '';
-  if (!date) {return ''}
+  let newDate = "";
+  if (!date) {
+    return "";
+  }
   // type=1: yyyy-MM-dd 转 yyyy-MM-dd HH:mm:ss
-  if(type == 1 || !type) {
-    newDate = date + ' 00:00:00';
+  if (type == 1 || !type) {
+    newDate = date + " 00:00:00";
   }
 }
 
@@ -133,48 +160,79 @@ export function resetDateFormat(date, type) {
  * dateFormat("YYYY-mm-dd HH:MM:SS WWW", date)       2020-02-09 14:45:12 星期日
  * dateFormat("YYYY-mm-dd HH:MM:SS QQQQ", date)      2020-02-09 14:09:36 第一季度
  * dateFormat("YYYY-mm-dd HH:MM:SS WWW QQQQ", date)  2020-02-09 14:46:12 星期日 第一季度
-   */
-export function dateFormat(format,date){
-  let we = date.getDay();                                 // 星期
-  let qut = Math.floor((date.getMonth()+3)/3).toString(); // 季度
+ */
+export function dateFormat(format, date) {
+  const we = date.getDay(); // 星期
+  const qut = Math.floor((date.getMonth() + 3) / 3).toString(); // 季度
   const opt = {
-    "Y+":date.getFullYear().toString(),                 // 年
-    "m+":(date.getMonth()+1).toString(),                // 月(月份从0开始,要+1)
-    "d+":date.getDate().toString(),                     // 日
-    "H+":date.getHours().toString(),                    // 时
-    "M+":date.getMinutes().toString(),                  // 分
-    "S+":date.getSeconds().toString(),                  // 秒
-    "q+":qut, // 季度
-  }
-  const week = {      // 中文数字 (星期)
-    "0":"日",
-    "1":"一",
-    "2":"二",
-    "3":"三",
-    "4":"四",
-    "5":"五",
-    "6":"六"
+    "Y+": date.getFullYear().toString(), // 年
+    "m+": (date.getMonth() + 1).toString(), // 月(月份从0开始,要+1)
+    "d+": date.getDate().toString(), // 日
+    "H+": date.getHours().toString(), // 时
+    "M+": date.getMinutes().toString(), // 分
+    "S+": date.getSeconds().toString(), // 秒
+    "q+": qut, // 季度
   };
-  const quarter = {   // 中文数字(季度)
-    "1" : "一",
-    "2" : "二",
-    "3" : "三",
-    "4" : "四",
+  const week = {
+    // 中文数字 (星期)
+    0: "日",
+    1: "一",
+    2: "二",
+    3: "三",
+    4: "四",
+    5: "五",
+    6: "六",
   };
-  if(/(W+)/.test(format)){
-    format = format.replace(RegExp.$1,(RegExp.$1.length >1 ? (RegExp.$1.length >2 ? '星期'+week[we] : '周'+week[we]) : week[we]))
+  const quarter = {
+    // 中文数字(季度)
+    1: "一",
+    2: "二",
+    3: "三",
+    4: "四",
+  };
+  if (/(W+)/.test(format)) {
+    format = format.replace(
+      RegExp.$1,
+      RegExp.$1.length > 1
+        ? RegExp.$1.length > 2
+          ? "星期" + week[we]
+          : "周" + week[we]
+        : week[we]
+    );
   }
   if (/(Q+)/.test(format)) {
     // 输入一个Q,只输出一个中文数字,输入4个Q,则拼接上字符串
-    format = format.replace(RegExp.$1,(RegExp.$1.length == 4 ? '第'+quarter[qut]+'季度' : quarter[qut]));
+    format = format.replace(
+      RegExp.$1,
+      RegExp.$1.length == 4 ? "第" + quarter[qut] + "季度" : quarter[qut]
+    );
   }
-  for(let k in opt){
-    let r = new RegExp("("+k+")").exec(format);
-    if(r){
+  for (const k in opt) {
+    const r = new RegExp("(" + k + ")").exec(format);
+    if (r) {
       // 若输入的长度不为1,则前面补零
-      format = format.replace(r[1],(RegExp.$1.length == 1 ? opt[k] : opt[k].padStart(RegExp.$1.length,'0')))
+      format = format.replace(
+        r[1],
+        RegExp.$1.length == 1 ? opt[k] : opt[k].padStart(RegExp.$1.length, "0")
+      );
     }
   }
-  return format
+  return format;
 }
 
+/**
+ * @param url {string} pdf地址
+ * @param fileName {string} pdf名称
+ */
+export function downloadPdf(url, fileName) {
+  axios({
+    method: "get",
+    url,
+    responseType: "blob",
+  }).then((res) => {
+    const file = new Blob([res.data], {
+      type: "application/pdf",
+    });
+    FileSaver(file, fileName);
+  });
+}

+ 0 - 1
src/views/basic_data/material/modify_list.vue

@@ -285,7 +285,6 @@
               <template slot-scope="scope">
                 <template v-for="(item, index) in scope.row.wallets">
                      <template v-if="item.type === 'REBATE'">
-
                         <el-tag
                   type="success"
                   style="margin: 0 10px"

+ 2 - 0
src/views/basic_data/material/price_list.vue

@@ -346,6 +346,7 @@ export default {
         endDate: '',
         materialName: '',
         materialNumber: '',
+        materialOldNumber: '',
         saleTypeId: '',
         specification: '',
         startDate: ''
@@ -382,6 +383,7 @@ export default {
         endDate: this.screenForm.endDate,
         materialName: this.screenForm.materialName,
         materialNumber: this.screenForm.materialNumber,
+        materialOldNumber: this.screenForm.materialOldNumber,
         saleTypeId: this.screenForm.saleTypeId,
         specification: this.screenForm.specification,
         startDate: this.screenForm.startDate

+ 223 - 69
src/views/engin_deposit/components/deposit-apply-surrender.vue

@@ -1,13 +1,13 @@
 <template>
   <div>
     <div class="sty">
-      <el-page-header @back="goBack" content="申请退押"> </el-page-header>
+      <el-page-header content="申请退押" @back="goBack" />
     </div>
-    <el-divider></el-divider>
+    <el-divider />
     <h3>工程项目信息</h3>
-    <el-divider></el-divider>
+    <el-divider />
     <div class="diy-table-1">
-      <el-form :model="details" ref="form">
+      <el-form ref="form" :model="details">
         <el-row :gutter="0">
           <el-col :xs="12" :sm="8" :lg="8" class="item">
             <div class="label">工程登录编码</div>
@@ -51,7 +51,7 @@
                   v-model="details.refFactoryNo"
                   placeholder="厂工程编码"
                   size="small"
-                ></el-input>
+                />
               </el-form-item>
             </div>
           </el-col>
@@ -73,8 +73,8 @@
             <div class="value">{{ details.refUseUnit }}</div>
           </el-col>
           <el-col :xs="24" :sm="24" :lg="8" class="item">
-            <div class="label"></div>
-            <div class="value"></div>
+            <div class="label" />
+            <div class="value" />
           </el-col>
           <el-col :xs="24" :sm="24" :lg="24" class="item">
             <div class="label">安装时间</div>
@@ -86,8 +86,7 @@
                   placeholder="安装时间"
                   default-time="00:00:00"
                   value-format="yyyy-MM-dd HH:mm:ss"
-                >
-                </el-date-picker>
+                />
               </el-form-item>
             </div>
           </el-col>
@@ -110,7 +109,7 @@
       </el-form>
     </div>
     <h3>货品信息</h3>
-    <el-divider></el-divider>
+    <el-divider />
     <!-- 列表 -->
     <div class="mymain-container">
       <div class="table">
@@ -132,82 +131,82 @@
             prop="materialNumber"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="产品编码"
             prop="materialOldNumber"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="产品名称"
             prop="materialName"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="规格型号"
             prop="specification"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="单价"
             prop="price"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="数量"
             prop="qty"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="金额"
             prop="totalAmount"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="发货数量"
             prop="hasSendQty"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="押金金额"
             prop="depositAmount"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="上交资料"
             prop="dataQty"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
           <el-table-column
             align="center"
             label="收差全额"
             prop="diffAmount"
             min-width="160"
             show-overflow-tooltip
-          ></el-table-column>
+          />
         </el-table>
       </div>
     </div>
     <h3>上传资料</h3>
-    <el-divider></el-divider>
+    <el-divider />
     <!-- 筛选条件 -->
     <div>
       <el-form
@@ -220,30 +219,140 @@
         <el-row :gutter="20">
           <el-col :xs="24" :sm="12" :lg="24">
             <el-form-item label="工程验收资料" prop="">
-              <imageUpload :fileList="fileList"  :multiple="true" :startRestricting="true" :restrictFilename="restrictFilename"/>
+              <imageUpload :file-list="fileList" :multiple="true" :start-restricting="true" :restrict-filename="restrictFilename" />
             </el-form-item>
           </el-col>
+          <el-col :xs="24" :sm="12" :lg="24">
+            <!-- 列表 -->
+            <div class="mymain-container">
+              <div class="table">
+                <el-table
+                  v-loading="listLoading"
+                  :data="details.dataList"
+                  element-loading-text="Loading"
+                  border
+                  fit
+                  highlight-current-row
+                  stripe
+                >
+                  <el-table-column
+                    align="center"
+                    label="资料描述"
+                    prop="dataDescribe"
+                    min-width="160"
+                    show-overflow-tooltip
+                  />
+                  <el-table-column
+                    align="center"
+                    label="原文件名"
+                    prop="fileName"
+                    min-width="160"
+                    show-overflow-tooltip
+                  />
+                  <el-table-column
+                    align="center"
+                    label="缩略图"
+                    prop="fileUrl"
+                    min-width="160"
+                    show-overflow-tooltip
+                  >
+                    <template slot-scope="scope">
+                      <el-image
+                        v-if="checkFileType(scope.row.fileUrl) == 'image'"
+                        ref="img"
+                        :src="imageURL + scope.row.fileUrl"
+                        style="width: 120px; height: 120px"
+                        fit="cover"
+                        :preview-src-list="[imageURL + scope.row.fileUrl]"
+                      />
+                      <img
+                        v-if="checkFileType(scope.row.fileUrl) == 'word'"
+                        class="file"
+                        src="@/assets/common/word.png"
+                      >
+                      <img
+                        v-if="checkFileType(scope.row.fileUrl) == 'excel'"
+                        class="file"
+                        src="@/assets/common/excel.png"
+                      >
+                      <img
+                        v-if="checkFileType(scope.row.fileUrl) == 'ppt'"
+                        class="file"
+                        src="@/assets/common/ppt.png"
+                      >
+
+                      <img
+                        v-if="checkFileType(scope.row.fileUrl) == 'pdf'"
+                        class="file"
+                        style="cursor: pointer;"
+                        src="@/assets/common/pdf.png"
+                        @click="openPdf(scope.row.fileUrl)"
+                      >
+
+                      <img
+                        v-if="checkFileType(scope.row.fileUrl) == 'file'"
+                        class="file aaa"
+                        src="@/assets/common/zip.jpeg"
+                      >
+                    </template>
+                  </el-table-column>
+                  <el-table-column
+                    align="center"
+                    label="下载文件名称"
+                    prop="fileName"
+                    min-width="160"
+                    show-overflow-tooltip
+                  >
+                    <template slot-scope="scope">
+                      {{ "资料_" + scope.row.fileName }}
+                    </template>
+                  </el-table-column>
+                  <el-table-column
+                    align="center"
+                    label="操作"
+                    min-width="160"
+                    show-overflow-tooltip
+                  >
+                    <template slot-scope="scope">
+                      <el-button
+                        type="text"
+                        class="textColor"
+                        @click="downLoadFn(scope.row.fileUrl,scope.row.fileName)"
+                      >下载</el-button>
+                      <!--                <el-button-->
+                      <!--                  v-if="checkFileType(scope.row.fileUrl) == 'pdf'"-->
+                      <!--                  type="text"-->
+                      <!--                  class="textColor"-->
+                      <!--                  @click="openPdf(scope.row.fileUrl)"-->
+                      <!--                >-->
+                      <!--                  查看-->
+                      <!--                </el-button>-->
+                    </template>
+                  </el-table-column>
+                </el-table>
+              </div>
+            </div>
+          </el-col>
           <el-col :xs="24" :sm="12" :lg="6">
             <el-form-item label="申请人" prop="submitBy">
               <el-input
-              readonly
                 v-model="details.submitName"
+                readonly
                 placeholder="请输入"
-              ></el-input>
+              />
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="12" :lg="6">
             <el-form-item label="申请日期" prop="submitTime">
               <el-date-picker
-              readonly
                 v-model="details.submitTime"
+                readonly
                 class="dateStyle"
                 type="datetime"
                 placeholder="选择日期"
-                   default-time="00:00:00"
-                  value-format="yyyy-MM-dd HH:mm:ss"
-              >
-              </el-date-picker>
+                default-time="00:00:00"
+                value-format="yyyy-MM-dd HH:mm:ss"
+              />
 
             </el-form-item>
           </el-col>
@@ -254,17 +363,21 @@
                 type="textarea"
                 placeholder="请输入"
                 class="textareaStyle"
-              ></el-input>
+              />
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="24" :lg="24">
             <el-form-item label="">
-              <el-button type="primary" size="small" @click="handleSvse"
-                >保存</el-button
-              >
-              <el-button type="primary" size="small" @click="handleReset"
-                >重置</el-button
-              >
+              <el-button
+                type="primary"
+                size="small"
+                @click="handleSvse"
+              >保存</el-button>
+              <el-button
+                type="primary"
+                size="small"
+                @click="handleReset"
+              >重置</el-button>
             </el-form-item>
           </el-col>
         </el-row>
@@ -277,63 +390,105 @@
 import { applyDeposit, geDetail } from '@/api/engin_deposit.js'
 
 import imageUpload from '@/components/Common/image-upload.vue'
+import { downloadFiles, downloadPdf } from '@/utils/util'
+
+import { getFileUrl } from '@/api/common'
 
 export default {
   components: {
-    imageUpload,
+    imageUpload
   },
   data() {
     return {
-      listLoading:false,
+      isDis: true,
+      listLoading: false,
       baseURL: process.env.VUE_APP_BASE_API,
       fileList: [],
       details: {},
       restrictFilename: [
-        '安装结算单', '合同', '竣工明细表', '审核表', '收据', '照片'
+        '结算单', '合同', '明细表', '审核表', '收据', '发票', '照片'
       ]
-    };
+    }
   },
   created() {
     geDetail({ id: this.$parent.depositManageId }).then((res) => {
-      this.details = res.data;
+      this.details = res.data
       res.data.items.forEach((item) => {
         // item.number = (item.qty*100 - item.directTransferQty*100 - item.retiredQty*100) / 100;
-        item.sums1 = ["hasSendQty", "dataQty", "qty"];
-        item.sums2 = ["totalAmount", "diffAmount", "price"];
-      });
-    });
+        item.sums1 = ['hasSendQty', 'dataQty', 'qty']
+        item.sums2 = ['totalAmount', 'diffAmount', 'price']
+      })
+    })
   },
   methods: {
     goBack() {
-      this.$parent.showPage = 1;
+      this.$parent.showPage = 1
     },
     handleSvse() {
-        if (!this.details.installDate) {
-            this.$errorMsg('请选择安装时间')
-            return
-        }
-        this.fileList.forEach(el => {
-            this.details.dataList.push({
-              dataDescribe:el.name,
-              enginOrderNo:this.details.refProjectNo,
-              fileName:el.name,
-              fileUrl:el.url,
-
-            })
-        });
-
+      if (!this.details.installDate) {
+        this.$errorMsg('请选择安装时间')
+        return
+      }
+      this.fileList.forEach(el => {
+        this.details.dataList.push({
+          dataDescribe: el.name,
+          enginOrderNo: this.details.refProjectNo,
+          fileName: el.name,
+          fileUrl: el.url
+        })
+      })
       applyDeposit(this.details).then((res) => {
-        this.$successMsg("申请成功");
-        this.$parent.showPage = 1;
-        this.$parent.deduction=''
+        this.$successMsg('申请成功')
+        this.$parent.showPage = 1
+        this.$parent.deduction = ''
         this.$parent.getList()
-      });
+      })
     },
     handleReset() {
-      this.$refs.form.resetFields();
+      this.$refs.form.resetFields()
     },
-  },
-};
+    // 批量下载
+    async batchDownloadFn() {
+      downloadFiles('/deposit-manage/downZip', { parentId: this.$parent.depositManageId })
+    },
+    // 下载
+    downLoadFn(v, fileName) {
+      if (this.checkFileType(v) === 'pdf') {
+        downloadPdf(this.$imageUrl + v, fileName)
+        return
+      }
+      getFileUrl({ key: v }).then((res) => {
+        window.open(res.data)
+      })
+    },
+    openPdf(pdfUrl) {
+      window.open(this.$imageUrl + pdfUrl)
+    },
+    // 检查文件类型
+    checkFileType(url) {
+      if (!url) return ''
+      const fileSuffix = url.substring(url.lastIndexOf('.') + 1)
+
+      if (['jpg', 'jpeg', 'png'].includes(fileSuffix)) {
+        return 'image'
+      } else if (['doc', 'docx', 'dot', 'wps', 'wpt'].includes(fileSuffix)) {
+        return 'word'
+      } else if (['xls', 'xlsx', 'xlt', 'et', 'ett'].includes(fileSuffix)) {
+        return 'excel'
+      } else if (
+        ['ppt', 'pptx', 'dps', 'dpt', 'pot', 'pps'].includes(fileSuffix)
+      ) {
+        return 'ppt'
+      } else if (['pdf'].includes(fileSuffix)) {
+        return 'pdf'
+      } else if (['zip', 'rar', 'gz', 'apk'].includes(fileSuffix)) {
+        return 'file'
+      } else {
+        return ''
+      }
+    },
+  }
+}
 </script>
 
 <style lang="scss" scoped>
@@ -368,5 +523,4 @@ export default {
 }
 }
 
-
 </style>

+ 30 - 7
src/views/engin_deposit/components/deposit_list-detail.vue

@@ -276,11 +276,15 @@
                   class="file"
                   src="@/assets/common/ppt.png"
                 >
+
                 <img
                   v-if="checkFileType(scope.row.fileUrl) == 'pdf'"
                   class="file"
+                  style="cursor: pointer;"
                   src="@/assets/common/pdf.png"
+                  @click="openPdf(scope.row.fileUrl)"
                 >
+
                 <img
                   v-if="checkFileType(scope.row.fileUrl) == 'file'"
                   class="file aaa"
@@ -309,8 +313,16 @@
                 <el-button
                   type="text"
                   class="textColor"
-                  @click="downLoadFn(scope.row.fileUrl)"
+                  @click="downLoadFn(scope.row.fileUrl,scope.row.fileName)"
                 >下载</el-button>
+                <!--                <el-button-->
+                <!--                  v-if="checkFileType(scope.row.fileUrl) == 'pdf'"-->
+                <!--                  type="text"-->
+                <!--                  class="textColor"-->
+                <!--                  @click="openPdf(scope.row.fileUrl)"-->
+                <!--                >-->
+                <!--                  查看-->
+                <!--                </el-button>-->
               </template>
             </el-table-column>
           </el-table>
@@ -320,11 +332,11 @@
         <el-row :gutter="0">
           <el-col :xs="12" :sm="12" :lg="12" class="item">
             <div class="label">申请人</div>
-            <div class="value">{{ details.submitName }}</div>
+            <div class="value">{{ details.createBy }}</div>
           </el-col>
           <el-col :xs="12" :sm="12" :lg="12" class="item">
             <div class="label">申请日期</div>
-            <div class="value">{{ details.submitTime }}</div>
+            <div class="value">{{ details.createTime }}</div>
           </el-col>
           <el-col :xs="24" :sm="24" :lg="24" class="item">
             <div class="label">申请退押金</div>
@@ -374,6 +386,10 @@
             <div class="label">验收说明</div>
             <div class="value">{{ details.checkNote }}</div>
           </el-col>
+          <el-col v-if="details.confirmName" :xs="24" :sm="24" :lg="24" class="item">
+            <div class="label">驳回说明</div>
+            <div class="value">{{ details.confirmName }}</div>
+          </el-col>
         </el-row>
       </div>
       <div style="margin: 20px 0">
@@ -607,7 +623,7 @@
 <script>
 import { editInfo, geDetail, geOrderInfo, getListProject } from '@/api/engin_deposit.js'
 import { getList } from '@/api/supply/adjust'
-import { downloadFiles } from '@/utils/util'
+import { downloadFiles, downloadPdf } from '@/utils/util'
 import { getFileUrl } from '@/api/common'
 
 export default {
@@ -697,10 +713,17 @@ export default {
       downloadFiles('/deposit-manage/downZip', { parentId: this.$parent.depositManageId })
     },
     // 下载
-    downLoadFn(v) {
+    downLoadFn(v, fileName) {
+      if (this.checkFileType(v) === 'pdf') {
+        downloadPdf(this.$imageUrl + v, fileName)
+        return
+      }
       getFileUrl({ key: v }).then((res) => {
-        window.open(res.data);
-      });
+        window.open(res.data)
+      })
+    },
+    openPdf(pdfUrl) {
+      window.open(this.$imageUrl + pdfUrl)
     },
     // 检查文件类型
     checkFileType(url) {

+ 129 - 284
src/views/engin_deposit/components/refund_list-detail.vue

@@ -10,17 +10,27 @@
     <div class="diy-table-1">
       <el-row :gutter="0">
         <el-col :xs="12" :sm="24" :lg="8" class="item">
-          <div class="label">工程登录编号</div>
+          <div class="label">
+            {{
+              detailList.enginOrderType == "HOME"
+                ? "工程登录编号"
+                : "工程信息编号"
+            }}
+          </div>
           <div class="value">{{ detailList.refEnginRecordNo }}</div>
         </el-col>
+        <!-- <el-col :xs="12" :sm="24" :lg="8" class="item">
+          <div class="label">工程信息编号</div>
+          <div class="value">{{ detailList.refEnginRecordNo }}</div>
+        </el-col> -->
         <el-col :xs="12" :sm="24" :lg="8" class="item">
-          <div class="label">项目类别</div>
+          <div class="label">项目名称</div>
           <div class="value">{{ detailList.refProjectName }}</div>
         </el-col>
         <el-col :xs="12" :sm="24" :lg="8" class="item">
           <div class="label">行业类别</div>
           <div class="value">
-            {{ detailList.refProjectNo == "HOME" ? "家用" : "商用" }}
+            {{ detailList.refPromiseStatus }}
           </div>
         </el-col>
         <el-col :xs="24" :sm="24" :lg="8" class="item">
@@ -65,26 +75,88 @@
           <div class="label">押金比例</div>
           <div class="value">{{detailList.}}</div>
         </el-col> -->
+
         <el-col :xs="24" :sm="24" :lg="8" class="item">
-          <div class="label">安装地址</div>
-          <div class="value">{{ detailList.refInstallAddress }}</div>
+          <div class="label">单据状态</div>
+          <div class="value">
+            {{
+              detailList.examineStatus == "SAVE"
+                ? "保存"
+                : detailList.examineStatus == "WAIT"
+                ? "待审核"
+                : detailList.examineStatus == "OK"
+                ? "通过"
+                : detailList.examineStatus == "FAIL"
+                ? "不通过"
+                : "关闭"
+            }}
+          </div>
+        </el-col>
+        <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">销售类型</div>
+          <div class="value">{{ detailList.saleTypeName }}</div>
         </el-col>
+        <!-- <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">不扣押金</div>
+          <div class="value">{{ detailList.customerName }}</div>
+        </el-col> -->
         <el-col :xs="24" :sm="24" :lg="8" class="item">
           <div class="label">第几次申报</div>
           <div class="value">{{ detailList.refDeclareNo }}</div>
         </el-col>
         <el-col :xs="24" :sm="24" :lg="8" class="item">
-          <div class="label">项目说明</div>
-          <div class="value">{{ detailList.refProjectNote }}</div>
+          <div class="label">项目类型</div>
+          <div class="value">{{ detailList.refProjectType }}</div>
         </el-col>
         <el-col :xs="24" :sm="24" :lg="8" class="item">
-          <div class="label">项目类型</div>
-          <div class="value">{{ detailList.refProjectName }}</div>
+          <div class="label">经销商编码</div>
+          <div class="value">{{ detailList.customerNumber }}</div>
         </el-col>
         <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">押金总额</div>
+          <div class="value">{{ detailList.depositAmount }}</div>
+        </el-col>
+        <el-col :xs="24" :sm="24" :lg="16" class="item">
+          <div class="label">安装地址</div>
+          <div class="value">{{ detailList.refInstallAddress }}</div>
+        </el-col>
+        <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">安装时间</div>
+          <div class="value">
+            <el-date-picker prefix-icon="''" placeholder="请选择安装时间" :disabled="title == '详情'" class="selectStyle" v-model="detailList.installDate" type="datetime" default-time="00:00:00" value-format="yyyy-MM-dd HH:mm:ss">
+            </el-date-picker>
+          </div>
+        </el-col>
+        <!-- <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">工程订单号</div>
+          <div class="value">{{ detailList.customerName }}</div>
+        </el-col> -->
+        <el-col :xs="24" :sm="24" :lg="16" class="item">
           <div class="label">经销商名称</div>
           <div class="value">{{ detailList.customerName }}</div>
         </el-col>
+
+        <el-col :xs="24" :sm="24" :lg="16" class="item">
+          <div class="label">项目说明</div>
+          <div class="value">{{ detailList.refProjectNote }}</div>
+        </el-col>
+        <!-- <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">订单日期</div>
+          <div class="value">{{ detailList.customerName }}</div>
+        </el-col> -->
+
+        <!-- <el-col :xs="24" :sm="24" :lg="16" class="item">
+          <div class="label">格力内部备注</div>
+          <div class="value">{{ detailList.customerName }}</div>
+        </el-col> -->
+        <!-- <el-col :xs="24" :sm="24" :lg="8" class="item">
+          <div class="label">文件编码</div>
+          <div class="value">{{ detailList.customerName }}</div>
+        </el-col> -->
+        <el-col :xs="24" :sm="24" :lg="16" class="item">
+          <div class="label">备注</div>
+          <div class="value">{{ detailList.applyNote }}</div>
+        </el-col>
         <!-- <el-col :xs="24" :sm="24" :lg="8" class="item">
           <div class="label">寄厂日期</div>
           <div class="value">
@@ -105,22 +177,6 @@
           <div class="label">提货日期</div>
           <div class="value">{{detailList.}}</div>
         </el-col> -->
-        <el-col :xs="24" :sm="24" :lg="8" class="item">
-          <div class="label">安装时间</div>
-          <div class="value">
-            <el-date-picker
-              prefix-icon="''"
-              placeholder="请选择安装时间"
-              :disabled="title == '详情'"
-              class="selectStyle"
-              v-model="detailList.installDate"
-              type="datetime"
-              default-time="00:00:00"
-              value-format="yyyy-MM-dd HH:mm:ss"
-            >
-            </el-date-picker>
-          </div>
-        </el-col>
       </el-row>
     </div>
     <h3>货品信息</h3>
@@ -128,122 +184,36 @@
     <!-- 列表 -->
     <div class="mymain-container">
       <div class="table">
-        <el-table
-          v-loading="listLoading"
-          :data="detailList.items"
-          element-loading-text="Loading"
-          border
-          fit
-          highlight-current-row
-          stripe
-          show-summary
-          :summary-method="$getSummaries"
-        >
-          <el-table-column
-            align="center"
-            label="厂产品编码"
-            prop="materialOldNumber"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="center"
-            label="产品编码"
-            prop="materialNumber"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="center"
-            label="产品名称"
-            prop="materialName"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="center"
-            label="规格型号"
-            prop="specification"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="right"
-            label="单价"
-            prop="price"
-            min-width="160"
-            show-overflow-tooltip
-          >
+        <el-table v-loading="listLoading" :data="detailList.items" element-loading-text="Loading" border fit highlight-current-row stripe show-summary :summary-method="$getSummaries">
+          <el-table-column align="center" label="产品编码" prop="materialOldNumber" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="center" label="物料编码" prop="materialNumber" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="center" label="产品名称" prop="materialName" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="center" label="规格型号" prop="specification" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="right" label="单价" prop="price" min-width="160" show-overflow-tooltip>
             <template slot-scope="scope">
               {{ scope.row.price | numToFixed }}
             </template>
           </el-table-column>
-          <el-table-column
-            align="right"
-            label="数量"
-            prop="qty"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="right"
-            label="金额"
-            prop="totalAmount"
-            min-width="160"
-            show-overflow-tooltip
-          >
+          <el-table-column align="right" label="数量" prop="qty" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="right" label="金额" prop="totalAmount" min-width="160" show-overflow-tooltip>
             <template slot-scope="scope">
               {{ scope.row.totalAmount | numToFixed }}
             </template>
           </el-table-column>
-          <el-table-column
-            align="right"
-            label="发货数量"
-            prop="hasSendQty"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="right"
-            label="上传资料"
-            prop="dataQty"
-            min-width="160"
-            show-overflow-tooltip
-            v-if="detailList.examineStatus !== 'WAIT'"
-          >
+          <el-table-column align="right" label="发货数量" prop="hasSendQty" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="right" label="上传资料" prop="dataQty" min-width="160" show-overflow-tooltip v-if="detailList.examineStatus !== 'WAIT'">
           </el-table-column>
-          <el-table-column
-            align="right"
-            label="上传资料"
-            prop="dataQty"
-            min-width="160"
-            show-overflow-tooltip
-            v-if="detailList.examineStatus == 'WAIT'"
-          >
+          <el-table-column align="right" label="上传资料" prop="dataQty" min-width="160" show-overflow-tooltip v-if="detailList.examineStatus == 'WAIT'">
             <template slot-scope="scope">
               <el-input v-model="scope.row.dataQty"></el-input>
             </template>
           </el-table-column>
-          <el-table-column
-            align="right"
-            label="收差金额"
-            prop="diffAmount"
-            min-width="160"
-            show-overflow-tooltip
-            v-if="detailList.examineStatus !== 'WAIT'"
-          >
+          <el-table-column align="right" label="收差金额" prop="diffAmount" min-width="160" show-overflow-tooltip v-if="detailList.examineStatus !== 'WAIT'">
             <template slot-scope="scope">
               {{ scope.row.diffAmount | numToFixed }}
             </template>
           </el-table-column>
-          <el-table-column
-            align="right"
-            label="收差金额"
-            prop="diffAmount"
-            min-width="160"
-            show-overflow-tooltip
-            v-if="detailList.examineStatus == 'WAIT'"
-          >
+          <el-table-column align="right" label="收差金额" prop="diffAmount" min-width="160" show-overflow-tooltip v-if="detailList.examineStatus == 'WAIT'">
             <template slot-scope="scope">
               <el-input v-model="scope.row.diffAmount"></el-input>
             </template>
@@ -253,111 +223,35 @@
     </div>
 
     <h3 class="gdzl">工程资料</h3>
-    <el-button
-      :disabled="isDis"
-      class="batchDownload"
-      type="primary"
-      size="small"
-      @click="batchDownloadFn"
-      >批量下载</el-button
-    >
+    <el-button :disabled="isDis" class="batchDownload" type="primary" size="small" @click="batchDownloadFn">批量下载</el-button>
 
     <el-divider></el-divider>
 
     <!-- 列表 -->
     <div class="mymain-container">
       <div class="table">
-        <el-table
-          v-loading="listLoading"
-          :data="detailList.dataList"
-          element-loading-text="Loading"
-          border
-          fit
-          highlight-current-row
-          stripe
-        >
-          <el-table-column
-            align="center"
-            label="资料描述"
-            prop="dataDescribe"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="center"
-            label="原文件名"
-            prop="fileName"
-            min-width="160"
-            show-overflow-tooltip
-          ></el-table-column>
-          <el-table-column
-            align="center"
-            label="缩略图"
-            prop="fileUrl"
-            min-width="160"
-            show-overflow-tooltip
-          >
+        <el-table v-loading="listLoading" :data="detailList.dataList" element-loading-text="Loading" border fit highlight-current-row stripe>
+          <el-table-column align="center" label="资料描述" prop="dataDescribe" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="center" label="原文件名" prop="fileName" min-width="160" show-overflow-tooltip></el-table-column>
+          <el-table-column align="center" label="缩略图" prop="fileUrl" min-width="160" show-overflow-tooltip>
             <template slot-scope="scope">
-              <el-image
-                ref="img"
-                :src="imageURL + scope.row.fileUrl"
-                v-if="checkFileType(scope.row.fileUrl) == 'image'"
-                style="width: 120px; height: 120px"
-                fit="cover"
-                :preview-src-list="[imageURL + scope.row.fileUrl]"
-              >
+              <el-image ref="img" :src="imageURL + scope.row.fileUrl" v-if="checkFileType(scope.row.fileUrl) == 'image'" style="width: 120px; height: 120px" fit="cover" :preview-src-list="[imageURL + scope.row.fileUrl]">
               </el-image>
-              <img
-                class="file"
-                src="@/assets/common/word.png"
-                v-if="checkFileType(scope.row.fileUrl) == 'word'"
-              />
-              <img
-                class="file"
-                src="@/assets/common/excel.png"
-                v-if="checkFileType(scope.row.fileUrl) == 'excel'"
-              />
-              <img
-                class="file"
-                src="@/assets/common/ppt.png"
-                v-if="checkFileType(scope.row.fileUrl) == 'ppt'"
-              />
-              <img
-                class="file"
-                src="@/assets/common/pdf.png"
-                v-if="checkFileType(scope.row.fileUrl) == 'pdf'"
-              />
-              <img
-                v-if="checkFileType(scope.row.fileUrl) == 'file'"
-                class="file aaa"
-                src="@/assets/common/zip.jpeg"
-              />
+              <img class="file" src="@/assets/common/word.png" v-if="checkFileType(scope.row.fileUrl) == 'word'" />
+              <img class="file" src="@/assets/common/excel.png" v-if="checkFileType(scope.row.fileUrl) == 'excel'" />
+              <img class="file" src="@/assets/common/ppt.png" v-if="checkFileType(scope.row.fileUrl) == 'ppt'" />
+              <img class="file" src="@/assets/common/pdf.png" v-if="checkFileType(scope.row.fileUrl) == 'pdf'" />
+              <img v-if="checkFileType(scope.row.fileUrl) == 'file'" class="file aaa" src="@/assets/common/zip.jpeg" />
             </template>
           </el-table-column>
-          <el-table-column
-            align="center"
-            label="下载文件名称"
-            prop="fileName"
-            min-width="160"
-            show-overflow-tooltip
-          >
+          <el-table-column align="center" label="下载文件名称" prop="fileName" min-width="160" show-overflow-tooltip>
             <template slot-scope="scope">
               {{ "资料_" + scope.row.fileName }}
             </template>
           </el-table-column>
-          <el-table-column
-            align="center"
-            label="操作"
-            min-width="160"
-            show-overflow-tooltip
-          >
+          <el-table-column align="center" label="操作" min-width="160" show-overflow-tooltip>
             <template slot-scope="scope">
-              <el-button
-                type="text"
-                class="textColor"
-                @click="downLoadFn(scope.row.fileUrl)"
-                >下载</el-button
-              >
+              <el-button type="text" class="textColor" @click="downLoadFn(scope.row.fileUrl)">下载</el-button>
             </template>
           </el-table-column>
         </el-table>
@@ -380,22 +274,18 @@
         </el-col>
       </el-row>
     </div>
-    <h3
-      v-if="
+    <h3 v-if="
         detailList.examineStatus == 'WAIT' ||
         detailList.examineStatus == 'FAIL' ||
         detailList.examineStatus == 'OK'
-      "
-    >
+      ">
       审批
     </h3>
-    <el-divider
-      v-if="
+    <el-divider v-if="
         detailList.examineStatus == 'WAIT' ||
         detailList.examineStatus == 'FAIL' ||
         detailList.examineStatus == 'OK'
-      "
-    ></el-divider>
+      "></el-divider>
     <div v-if="detailList.examineStatus == 'WAIT'" class="diy-table-1">
       <el-row :gutter="0">
         <el-col :xs="12" :sm="12" :lg="12" class="item">
@@ -405,15 +295,7 @@
         <el-col :xs="12" :sm="12" :lg="12" class="item dateS">
           <div class="label">验收日期</div>
           <div class="value">
-            <el-date-picker
-              disabled
-              prefix-icon="''"
-              class="selectStyle"
-              type="datetime"
-              placeholder="系统自动生成"
-              default-time="00:00:00"
-              value-format="yyyy-MM-dd HH:mm:ss"
-            >
+            <el-date-picker disabled prefix-icon="''" class="selectStyle" type="datetime" placeholder="系统自动生成" default-time="00:00:00" value-format="yyyy-MM-dd HH:mm:ss">
             </el-date-picker>
           </div>
         </el-col>
@@ -435,12 +317,9 @@
       </el-row>
     </div>
 
-    <div
-      v-if="
+    <div v-if="
         detailList.examineStatus == 'OK' || detailList.examineStatus == 'FAIL'
-      "
-      class="diy-table-1"
-    >
+      " class="diy-table-1">
       <el-row :gutter="0">
         <el-col :xs="12" :sm="12" :lg="12" class="item">
           <div class="label">验收人</div>
@@ -449,16 +328,7 @@
         <el-col :xs="12" :sm="12" :lg="12" class="item dateS">
           <div class="label">验收日期</div>
           <div class="value">
-            <el-date-picker
-              disabled
-              prefix-icon="''"
-              class="selectStyle"
-              v-model="detailList.checkDate"
-              type="datetime"
-              placeholder=""
-              default-time="00:00:00"
-              value-format="yyyy-MM-dd HH:mm:ss"
-            >
+            <el-date-picker disabled prefix-icon="''" class="selectStyle" v-model="detailList.checkDate" type="datetime" placeholder="" default-time="00:00:00" value-format="yyyy-MM-dd HH:mm:ss">
             </el-date-picker>
           </div>
         </el-col>
@@ -474,20 +344,13 @@
         <el-col :xs="12" :sm="24" :lg="24" class="item dateS">
           <div class="label">验收说明</div>
           <div class="value">
-            <el-input
-              disabled
-              v-model="detailList.checkNote"
-              placeholder="请输入内容"
-            ></el-input>
+            <el-input disabled v-model="detailList.checkNote" placeholder="请输入内容"></el-input>
           </div>
         </el-col>
         <el-col :xs="12" :sm="24" :lg="24" class="item dateS">
           <div class="label">审批通过后备注</div>
           <div class="value">
-            <el-input
-              v-model="detailList.examineAfterRemark"
-              placeholder="请输入内容"
-            ></el-input>
+            <el-input v-model="detailList.examineAfterRemark" placeholder="请输入内容"></el-input>
           </div>
         </el-col>
       </el-row>
@@ -497,27 +360,9 @@
     <!-- detailList.examineStatus != 'OK' || detailList.examineStatus != 'FAIL' -->
     <div class="btn-group clearfix">
       <div class="fl">
-        <el-button
-          v-if="detailList.examineStatus == 'WAIT'"
-          type="primary"
-          size="small"
-          @click="adoptFn"
-          >审批通过</el-button
-        >
-        <el-button
-          v-if="detailList.examineStatus == 'WAIT'"
-          type="primary"
-          size="small"
-          @click="rejectFn"
-          >审批驳回</el-button
-        >
-        <el-button
-          v-if="detailList.examineStatus == 'OK'"
-          type="primary"
-          size="small"
-          @click="saveFn"
-          >保存</el-button
-        >
+        <el-button v-if="detailList.examineStatus == 'WAIT'" type="primary" size="small" @click="adoptFn">审批通过</el-button>
+        <el-button v-if="detailList.examineStatus == 'WAIT'" type="primary" size="small" @click="rejectFn">审批驳回</el-button>
+        <el-button v-if="detailList.examineStatus == 'OK'" type="primary" size="small" @click="saveFn">保存</el-button>
       </div>
     </div>
   </div>
@@ -616,10 +461,10 @@ export default {
         type: "warning",
       })
         .then(() => {
-          // if (!this.detailList.installDate) {
-          //   this.$message.error("请选择安装时间");
-          //   return;
-          // }
+          if (!this.detailList.installDate) {
+            this.$message.error("请选择安装时间");
+            return;
+          }
           let data = {
             ...this.detailList,
             checkBy: this.checkBy,
@@ -677,10 +522,10 @@ export default {
         type: "warning",
       })
         .then(() => {
-          // if (!this.detailList.installDate) {
-          //   this.$message.error("请选择安装时间");
-          //   return;
-          // }
+          if (!this.detailList.installDate) {
+            this.$message.error("请选择安装时间");
+            return;
+          }
           let data = {
             ...this.detailList,
             checkBy: this.checkBy,

+ 24 - 131
src/views/engin_deposit/refund_list.vue

@@ -11,28 +11,16 @@
       <br /><br />
       <!-- 筛选条件 -->
       <div>
-        <el-form
-          ref="searchForm"
-          :model="searchForm"
-          label-width="160px"
-          size="small"
-          label-position="left"
-        >
+        <el-form ref="searchForm" :model="searchForm" label-width="160px" size="small" label-position="left">
           <el-row :gutter="20">
             <el-col :xs="24" :sm="12" :lg="6">
               <el-form-item label="工程登录(信息)编号" prop="refEnginRecordNo">
-                <el-input
-                  v-model="searchForm.refEnginRecordNo"
-                  placeholder="请输入"
-                ></el-input>
+                <el-input v-model="searchForm.refEnginRecordNo" placeholder="请输入"></el-input>
               </el-form-item>
             </el-col>
             <el-col :xs="24" :sm="12" :lg="6">
               <el-form-item label="经销商编码" prop="customerKeyword">
-                <el-input
-                  v-model="searchForm.customerKeyword"
-                  placeholder="请输入"
-                ></el-input>
+                <el-input v-model="searchForm.customerKeyword" placeholder="请输入"></el-input>
               </el-form-item>
             </el-col>
             <!-- <el-col :xs="24" :sm="12" :lg="6">
@@ -45,10 +33,7 @@
             </el-col> -->
             <el-col :xs="24" :sm="12" :lg="6">
               <el-form-item label="工程名称" prop="refProjectName">
-                <el-input
-                  v-model="searchForm.refProjectName"
-                  placeholder="请输入"
-                ></el-input>
+                <el-input v-model="searchForm.refProjectName" placeholder="请输入"></el-input>
               </el-form-item>
             </el-col>
             <!-- <el-col :xs="24" :sm="12" :lg="6">
@@ -91,9 +76,7 @@
             <el-col :xs="24" :sm="12" :lg="6">
               <el-form-item label="" class="fr">
                 <el-button size="small" @click="resetFn">清空</el-button>
-                <el-button size="small" type="primary" @click="searchFn"
-                  >搜索</el-button
-                >
+                <el-button size="small" type="primary" @click="searchFn">搜索</el-button>
               </el-form-item>
             </el-col>
           </el-row>
@@ -102,26 +85,14 @@
       <!-- 按钮 -->
       <div class="btn-group clearfix">
         <div class="fl">
-          <el-radio-group
-            @change="changeEnginOrderTypeFn"
-            v-model="enginOrderType"
-            size=""
-          >
+          <el-radio-group @change="changeEnginOrderTypeFn" v-model="enginOrderType" size="">
             <el-radio-button label="HOME">家用工程</el-radio-button>
             <el-radio-button label="TRADE">商用工程</el-radio-button>
           </el-radio-group>
         </div>
         <div class="fr">
-          <el-button type="primary" size="small" @click="exportFn"
-            >导出</el-button
-          >
-          <el-upload
-            class="import-btn"
-            action=""
-            :http-request="handleImport"
-            :file-list="importFileList"
-            :show-file-list="false"
-          >
+          <el-button type="primary" size="small" @click="exportFn">导出</el-button>
+          <el-upload class="import-btn" action="" :http-request="handleImport" :file-list="importFileList" :show-file-list="false">
             <el-button type="primary" size="small">导入</el-button>
           </el-upload>
         </div>
@@ -129,124 +100,46 @@
       <!-- 列表 -->
       <div class="mymain-container">
         <div class="table">
-          <el-table
-            v-loading="listLoading"
-            :data="dataList"
-            element-loading-text="Loading"
-            border
-            fit
-            highlight-current-row
-            stripe
-            @selection-change="handleSelectionChange"
-            show-summary
-            :summary-method="$getSummaries"
-          >
+          <el-table v-loading="listLoading" :data="dataList" element-loading-text="Loading" border fit highlight-current-row stripe @selection-change="handleSelectionChange" show-summary :summary-method="$getSummaries">
             >
             <el-table-column type="selection" align="center" width="55">
             </el-table-column>
-            <el-table-column
-              align="center"
-              label="工程登录编码"
-              prop="refEnginRecordNo"
-              min-width="160"
-              show-overflow-tooltip
-            ></el-table-column>
-            <el-table-column
-              align="center"
-              label="工程名称"
-              prop="refProjectName"
-              min-width="160"
-              show-overflow-tooltip
-            ></el-table-column>
-            <el-table-column
-              align="center"
-              label="经销商编码"
-              prop="customerId"
-              min-width="160"
-              show-overflow-tooltip
-            ></el-table-column>
-            <el-table-column
-              align="center"
-              label="经销商名称"
-              prop="customerName"
-              min-width="160"
-              show-overflow-tooltip
-            ></el-table-column>
-            <el-table-column
-              align="right"
-              label="押金金额"
-              prop="depositAmount"
-              min-width="160"
-              show-overflow-tooltip
-            >
+            <el-table-column align="center" label="工程登录编码" prop="refEnginRecordNo" min-width="160" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="工程名称" prop="refProjectName" min-width="160" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="经销商编码" prop="customerId" min-width="160" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="经销商名称" prop="customerName" min-width="160" show-overflow-tooltip></el-table-column>
+            <el-table-column align="right" label="押金金额" prop="depositAmount" min-width="160" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ scope.row.depositAmount | numToFixed }}
               </template>
             </el-table-column>
-            <el-table-column
-              align="center"
-              label="状态"
-              prop=""
-              min-width="160"
-              show-overflow-tooltip
-            >
+            <el-table-column align="center" label="状态" prop="" min-width="160" show-overflow-tooltip>
               <template v-slot="{ row }">
                 <el-tag v-show="row.examineStatus == 'SAVE'">保存</el-tag>
-                <el-tag v-show="row.examineStatus == 'WAIT'" type="warning"
-                  >待审核</el-tag
-                >
-                <el-tag v-show="row.examineStatus == 'OK'" type="success"
-                  >通过</el-tag
-                >
-                <el-tag v-show="row.examineStatus == 'FAIL'" type="danger"
-                  >不通过</el-tag
-                >
+                <el-tag v-show="row.examineStatus == 'WAIT'" type="warning">待审核</el-tag>
+                <el-tag v-show="row.examineStatus == 'OK'" type="success">通过</el-tag>
+                <el-tag v-show="row.examineStatus == 'FAIL'" type="danger">不通过</el-tag>
               </template>
             </el-table-column>
-            <el-table-column
-              align="center"
-              label="操作"
-              min-width="160"
-              show-overflow-tooltip
-            >
+            <el-table-column align="center" label="操作" min-width="160" show-overflow-tooltip>
               <template slot-scope="scope">
-                <el-button
-                  type="text"
-                  class="textColor"
-                  v-if="
+                <el-button type="text" class="textColor" v-if="
                     scope.row.examineStatus == 'WAIT' &&
                     $checkBtnRole('examine', $route.meta.roles)
-                  "
-                  @click="examineFn(scope.row.depositManageId)"
-                  >审批</el-button
-                >
+                  " @click="examineFn(scope.row.depositManageId)">审批</el-button>
 
-                <el-button
-                  type="text"
-                  class="textColor"
-                  v-if="
+                <el-button type="text" class="textColor" v-if="
                     scope.row.examineStatus == 'SAVE' ||
                     scope.row.examineStatus == 'OK' ||
                     scope.row.examineStatus == 'FAIL'
-                  "
-                  @click="infoFn(scope.row.depositManageId)"
-                  >详情</el-button
-                >
+                  " @click="infoFn(scope.row.depositManageId)">详情</el-button>
               </template>
             </el-table-column>
           </el-table>
         </div>
         <!-- 分页 -->
         <div class="fr">
-          <el-pagination
-            @size-change="handleSizeChange"
-            @current-change="handleCurrentChange"
-            :current-page="currentPage"
-            :page-sizes="[10, 20, 30, 50]"
-            :page-size="pageSize"
-            layout="total, sizes, prev, pager, next, jumper"
-            :total="listTotal"
-          >
+          <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage" :page-sizes="[10, 20, 30, 50]" :page-size="pageSize" layout="total, sizes, prev, pager, next, jumper" :total="listTotal">
           </el-pagination>
         </div>
       </div>

+ 4 - 4
src/views/finance/wallet.vue

@@ -185,7 +185,7 @@
             min-width="160"
             show-overflow-tooltip
           ></el-table-column>
-          <el-table-column
+          <!-- <el-table-column
             align="center"
             label="操作"
             min-width="160"
@@ -201,7 +201,7 @@
                 修改
               </el-button>
             </template>
-          </el-table-column>
+          </el-table-column> -->
         </el-table>
       </div>
     </div>
@@ -404,12 +404,12 @@ export default {
       this.dialogExportForm = false;
     },
     exportOKFn() {
-      this.dialogExportForm = false;
+      downloadFiles("/wallet/count/export", { ...this.exportForm });
       this.exportForm = {
         endCustomerId: "",
         startCustomerId: "",
       };
-      downloadFiles("/wallet/count/export", { ...this.exportForm });
+      this.dialogExportForm = false;
     },
     //导出
     exportFn() {

+ 386 - 0
src/views/setting/sub_account.vue

@@ -0,0 +1,386 @@
+<template>
+  <div class="app-container">
+    <div class="setting_title">子账号</div>
+    <el-divider />
+
+    <div class="mymain-container">
+      <div class="btn-group clearfix">
+        <div class="fl">
+          <el-button v-if="checkBtnRole('add')" size="small" type="primary" icon="el-icon-plus" @click="addOrEdit('add')">新增账号</el-button>
+        </div>
+        <div class="fr">
+          <ImportButton :im-url="'stock/importToll'" @importSuccess="getList" />
+        </div>
+      </div>
+
+      <div class="table">
+        <el-table v-loading="listLoading" :data="dataList" element-loading-text="Loading" border fit highlight-current-row stripe>
+          <el-table-column align="center" label="序号" type="index" width="50" />
+          <el-table-column align="center" label="账号" prop="userName" />
+          <el-table-column align="center" label="创建时间" prop="createTime" />
+          <el-table-column align="center" label="最后登录时间" prop="lastLoginTime" />
+          <el-table-column align="center" label="操作" width="180">
+            <template slot-scope="scope">
+              <el-button type="text" @click="addOrEdit('edit',scope.row)">编辑</el-button>
+              <el-button v-if="checkBtnRole('detail')" type="text" @click="setMenuRole(scope.row.adminUserId,'role')">设置权限</el-button>
+
+            </template>
+          </el-table-column>
+        </el-table>
+      </div>
+
+      <div class="pagination clearfix">
+        <div class="fr">
+          <el-pagination
+            :current-page="currentPage"
+            :page-sizes="[10, 20, 30, 50]"
+            :page-size="10"
+            layout="total, sizes, prev, pager, next, jumper"
+            :total="listTotal"
+            @size-change="handleSizeChange"
+            @current-change="handleCurrentChange"
+          />
+        </div>
+      </div>
+    </div>
+
+    <!-- 设置权限 -->
+    <el-dialog title="设置权限" :visible.sync="roleFormVisible" :show-close="false" width="40%" :close-on-click-modal="false" custom-class="tree-dialog" top="50px">
+      <el-tree
+        ref="tree"
+        :data="menuRoleList"
+        show-checkbox
+        :check-strictly="true"
+        :default-expand-all="true"
+        :expand-on-click-node="false"
+        node-key="moduleId"
+        highlight-current
+        :props="defaultProps"
+      >
+        <span slot-scope="{ node, data }" class="custom-tree-node">
+          <span>{{ node.label }}</span>
+          <span v-if="data.type < 3">
+            <el-button type="text" size="mini" @click="() => quickSelection(data)">一键全选</el-button>
+            <el-button type="text" size="mini" style="color: #f56c6c" @click="() => quickCancel(data)">一键取消</el-button>
+          </span>
+        </span>
+      </el-tree>
+      <div slot="footer" class="dialog-footer">
+        <el-button @click="roleFormVisible = false">{{ editId != 1 ? '取 消':'关 闭' }}</el-button>
+        <el-button v-if="editId != 1" type="primary" @click="submitRoleForm('role')">确 定</el-button>
+      </div>
+    </el-dialog>
+    <el-dialog
+      :visible.sync="dialogVisible"
+      :close-on-click-modal="false"
+      width="45%"
+      :title="'add'===addFormType?'新增':'编辑'"
+      @close="cancelAddForm"
+    >
+      <el-form ref="ruleForm" :model="ruleForm" :rules="rules" label-width="100px" class="demo-ruleForm">
+        <el-form-item label="账号" prop="account">
+          <el-input v-model="ruleForm.account" type="text" autocomplete="off" />
+        </el-form-item>
+        <el-form-item label="密码" prop="password">
+          <el-input v-model="ruleForm.password" type="password" autocomplete="off" />
+        </el-form-item>
+      </el-form>
+
+      <span slot="footer" class="dialog-footer">
+        <el-button type="primary" style="float: left;" @click="setMenuRole">设置权限</el-button>
+        <el-button @click="cancelAddForm">取 消</el-button>
+        <el-button type="primary" @click="submitAddForm">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { mapGetters } from 'vuex'
+import {
+  addSubAccount,
+  deleteRole,
+  editRole,
+  editSubAccount,
+  getAccountList,
+  getMenuList,
+  getMenuRoleIds
+} from '@/api/setting'
+
+export default {
+  data() {
+    return {
+      imageURL: this.$imageUrl,
+      dataList: null, // 列表数据
+      listLoading: true, // 列表加载loading
+      currentPage: 1, // 当前页码
+      pageSize: 10, // 每页数量
+      listTotal: 0, // 列表总数
+
+      editId: null,
+      addFormType: 'add',
+      addFormVisible: false,
+      addForm: {
+        name: '' // 角色名
+      },
+      addFormRules: {
+        name: [
+          { required: true, message: '请输入角色名', trigger: 'blur' }
+        ]
+      },
+
+      roleFormVisible: false,
+
+      menuRoleList: [],
+      defaultProps: {
+        children: 'children',
+        label: 'moduleName'
+      },
+      dialogVisible: false,
+      ruleForm: {
+        account: '',
+        password: ''
+      },
+      rules: {
+        account: [
+          { required: true, message: '请输入账号', trigger: 'blur' }
+        ],
+        password: [
+          { required: true, message: '请输入密码', trigger: 'blur' }
+        ]
+      }
+    }
+  },
+  computed: {
+    ...mapGetters([
+      'userid',
+      'name',
+      'customerId'
+    ])
+  },
+  created() {
+    this.getList()
+  },
+  methods: {
+    // 查询按钮权限
+    checkBtnRole(value) {
+      // let btnRole = this.$route.meta.roles;
+      // if(!btnRole) {return true}
+      // let index = btnRole.indexOf(value);
+      // return index >= 0 ? true : false;
+      return true
+    },
+
+    getList() {
+      this.listLoading = true
+
+      const params = {
+        pageNum: this.currentPage,
+        pageSize: this.pageSize,
+        customerId: this.customerId
+      }
+
+      getAccountList(params).then(res => {
+        this.dataList = res.data.records
+        this.listTotal = res.data.total
+        this.listLoading = false
+      })
+    },
+
+    // 更改每页数量
+    handleSizeChange(val) {
+      this.pageSize = val
+      this.currentPage = 1
+      this.getList()
+    },
+
+    // 更改当前页
+    handleCurrentChange(val) {
+      this.currentPage = val
+      this.getList()
+    },
+
+    // 操作 - 删除
+    handleDelete(id) {
+      deleteRole({ adminRoleId: id }).then(res => {
+        this.getList()
+        this.$successMsg()
+      })
+    },
+
+    // 新增编辑
+    addOrEdit(type, row) {
+      this.addFormType = type
+      this.dialogVisible = true
+      if (type === 'edit') {
+        this.$nextTick(() => {
+          this.ruleForm = {
+            account: row.userName,
+            password: row.password
+          }
+        })
+      }
+    },
+
+    // 取消 新增编辑
+    cancelAddForm() {
+      this.dialogVisible = false
+      this.$nextTick(() => {
+        this.$refs.tree.setCheckedKeys([])
+      })
+      this.$refs.ruleForm.resetFields()
+    },
+
+    // 提交 新增编辑
+    submitAddForm() {
+      this.$refs.ruleForm.validate((valid) => {
+        const params = {
+          userName: this.ruleForm.account,
+          password: this.ruleForm.password,
+          adminModuleIds: this.$refs.tree ? this.$refs.tree.getCheckedKeys().join(',') : ''
+        }
+        if (valid) {
+          if (this.addFormType === 'edit') {
+            params.adminRoleId = this.editId
+            editSubAccount(params).then(res => {
+              this.cancelAddForm()
+              this.getList()
+              this.$successMsg('编辑成功')
+            })
+          } else {
+            addSubAccount(params).then(res => {
+              this.cancelAddForm()
+              this.getList()
+              this.$successMsg('新增成功')
+            })
+          }
+        }
+      })
+    },
+
+    // 设置权限 - 获取列表
+    setMenuRole(id, type) {
+      this.roleFormVisible = true
+      this.editId = id
+      getMenuList({ adminUserId: this.userid }).then(res => {
+        this.menuRoleList = res.data
+      })
+      if (type === 'role') {
+
+        getMenuRoleIds({ adminRoleId: id }).then(res => {
+          console.log(78888,res.data)
+          this.$refs.tree.setCheckedKeys(res.data)
+        })
+      }
+    },
+
+    // 设置权限 - 提交数据
+    submitRoleForm(type) {
+      // if (type === 'role') {
+      //   const params = {
+      //     adminModuleIds: this.$refs.tree.getCheckedKeys().join(','),
+      //     adminRoleId: this.editId
+      //   }
+      //   setMenuRole(params).then(res => {
+      //     this.getList()
+      //     this.$successMsg()
+      //   })
+      // }
+      this.roleFormVisible = false
+    },
+
+    // 一键全选
+    quickSelection(data) {
+      const nowChecked = this.$refs.tree.getCheckedKeys()
+      const thisId = data.moduleId
+      let childId = []
+      if (data.children.length) {
+        childId = this.familyTree(data.children)
+      }
+
+      const setChecked = nowChecked.concat([thisId]).concat(childId)
+
+      this.$refs.tree.setCheckedKeys(setChecked)
+    },
+
+    // 一键取消
+    quickCancel(data) {
+      const nowChecked = this.$refs.tree.getCheckedKeys()
+      const thisId = data.moduleId
+      let childId = []
+      if (data.children.length) {
+        childId = this.familyTree(data.children)
+      }
+
+      const setChecked = nowChecked
+      if (setChecked.indexOf(thisId) >= 0) {
+        setChecked.splice(setChecked.indexOf(thisId), 1)
+      }
+
+      if (childId.length) {
+        for (var i = 0; i < childId.length; i++) {
+          if (setChecked.indexOf(childId[i]) >= 0) {
+            setChecked.splice(setChecked.indexOf(childId[i]), 1)
+          }
+        }
+      }
+
+      this.$refs.tree.setCheckedKeys(setChecked)
+    },
+
+    // 递归子id
+    familyTree(arr) {
+      var temp = []
+      var forFn = function(list) {
+        for (var i = 0; i < list.length; i++) {
+          var item = list[i]
+          if (item.children) {
+            temp.push(item.moduleId)
+            forFn(item.children)
+          }
+        }
+      }
+      forFn(arr)
+      return temp
+    },
+
+    changeStatus(id, status) {
+      editRole({
+        adminRoleId: id,
+        visitSysStatus: status
+      }).then(res => {
+        this.getList()
+        this.$successMsg('编辑成功')
+      })
+    }
+
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+::v-deep .tree-dialog {
+  .el-dialog__body {
+    padding: 20px;
+    .el-tree {
+      max-height: calc(100vh - 140px - 54px - 70px);
+      overflow-y: scroll;
+      padding: 0 30px;
+      >.el-tree-node {
+        padding: 15px 0;
+        border: 1px dashed #ddd;
+        margin-bottom: 15px;
+        border-radius: 10px;
+      }
+    }
+  }
+}
+::v-deep .custom-tree-node {
+  flex: 1;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  font-size: 14px;
+  padding-right: 8px;
+}
+</style>

+ 2 - 2
src/views/supply/engin/commerce_list.vue

@@ -176,9 +176,9 @@
               </template>
             </el-table-column>
             <el-table-column align="center" label="业务员" prop="aaa" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="制表人" prop="createName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="制表人" prop="createBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="制表日期" prop="createTime" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="审核人" prop="confirmName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="审核人" prop="confirmBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审核日期" prop="confirmTime" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="操作" width="220" fixed="right">
               <template slot-scope="scope">

+ 6 - 6
src/views/supply/engin/components/commerce_detail.vue

@@ -82,11 +82,11 @@
             </el-col>
             <el-col :span="24" class="item">
               <div class="label">格力回复</div>
-              <div class="value">{{detailData.note1}}</div>
+              <div class="value">{{detailData.geLiNote}}</div>
             </el-col>
             <el-col :span="24" class="item">
               <div class="label">格力内部备注</div>
-              <div class="value">{{detailData.note2}}</div>
+              <div class="value">{{detailData.geLiInerNote}}</div>
             </el-col>
             <el-col :span="24" class="item">
               <div class="label">备注</div>
@@ -94,7 +94,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">制单人</div>
-              <div class="value">{{detailData.createName}}</div>
+              <div class="value">{{detailData.createBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">制单日期</div>
@@ -102,7 +102,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">审核人</div>
-              <div class="value">{{detailData.confirmName}}</div>
+              <div class="value">{{detailData.confirmBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">审核日期</div>
@@ -110,7 +110,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">最后更新人</div>
-              <div class="value">{{detailData.updateName}}</div>
+              <div class="value">{{detailData.updateBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">最后更新日期</div>
@@ -118,7 +118,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">关闭人</div>
-              <div class="value">{{detailData.closeName}}</div>
+              <div class="value">{{detailData.closeBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">关闭日期</div>

+ 2 - 2
src/views/supply/engin/components/commerce_examine.vue

@@ -97,7 +97,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单日期</div>
@@ -105,7 +105,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭人</div>
-          <div class="value">{{detailData.closeName}}</div>
+          <div class="value">{{detailData.closeBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭日期</div>

+ 6 - 3
src/views/supply/engin/components/commerce_form.vue

@@ -398,6 +398,7 @@ export default {
         createDate: '',
         fileNum: '',
         salesMan: '',
+        tradeCategory: ''
       },
       mainFormRules: {
         // orderDate: [{ required: true, message: '请选择单据日期', trigger: 'change' }],
@@ -578,7 +579,7 @@ export default {
         this.mainForm.greeRemark = data.note2;
         this.mainForm.greeReply = data.note1;
         this.mainForm.remark = data.remark;
-        this.mainForm.createMan = data.createName;
+        this.mainForm.createMan = data.createBy;
         this.mainForm.createDate = data.createTime;
         this.mainForm.fileNum = data.fileNo;
         this.mainForm.salesMan = data.serviceId;
@@ -659,6 +660,7 @@ export default {
         this.mainForm.phone = data.phone;
         this.mainForm.address = data.installAddress;
         this.mainForm.salesMan = data.serviceId;
+        this.mainForm.tradeCategory = data.tradeCategory;
 
         this.goodsList = data.items.map(item => {
           return {
@@ -799,13 +801,14 @@ export default {
             refProjectName: this.mainForm.enginName || '',
             refPromiseStatus: this.mainForm.loginType || '',
             refFactoryNo: this.mainForm.factoryNum || '',
+            refTradeCategory: this.mainForm.tradeCategory || '',
             refUseUnit: this.mainForm.company || '',
             refLinkman: this.mainForm.contactMan || '',
             refTel: this.mainForm.tel || '',
             refPhone: this.mainForm.phone || '',
             refInstallAddress: this.mainForm.address || '',
-            note2: this.mainForm.greeRemark || '',
-            note1: this.mainForm.greeReply || '',
+            geLiInerNote: this.mainForm.greeRemark || '',
+            geLiNote: this.mainForm.greeReply || '',
             remark: this.mainForm.remark || '',
             fileNo: this.mainForm.fileNum || '',
             serviceId: this.mainForm.salesMan,

+ 2 - 2
src/views/supply/engin/components/commerce_return.vue

@@ -90,7 +90,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单日期</div>
@@ -98,7 +98,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭人</div>
-          <div class="value">{{detailData.closeName}}</div>
+          <div class="value">{{detailData.closeBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭日期</div>

+ 1 - 1
src/views/supply/engin/components/engin_detail.vue

@@ -66,7 +66,7 @@
         </el-col>
         <el-col :span="8" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="8" class="item">
           <div class="label">制单日期</div>

+ 1 - 1
src/views/supply/engin/components/engin_examine.vue

@@ -70,7 +70,7 @@
         </el-col>
         <el-col :span="8" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="8" class="item">
           <div class="label">制单日期</div>

+ 4 - 1
src/views/supply/engin/components/engin_form.vue

@@ -331,6 +331,7 @@ export default {
         createMan: '',
         createDate: '',
         contractDate: '',
+        tradeCategory: '',
       },
       mainFormRules: {
         // orderDate: [{ required: true, message: '请选择单据日期', trigger: 'change' }],
@@ -429,9 +430,10 @@ export default {
         this.mainForm.tel = data.tel;
         this.mainForm.remark = data.remark;
         this.mainForm.salesMan = data.serviceId;
-        this.mainForm.createMan = data.createName;
+        this.mainForm.createMan = data.createBy;
         this.mainForm.createDate = data.createTime;
         this.mainForm.contractDate = data.contractExpireDate;
+        this.mainForm.contractDate = data.contractExpireDate;
 
         this.goodsList = data.items;
       })
@@ -661,6 +663,7 @@ export default {
             tel: this.mainForm.tel,
             remark: this.mainForm.remark,
             contractExpireDate: this.mainForm.contractDate,
+            tradeCategory: this.mainForm.tradeCategory,
             items: goodsList
           }
           if(type === 1) {

+ 4 - 4
src/views/supply/engin/components/home_detail.vue

@@ -110,7 +110,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">制单人</div>
-              <div class="value">{{detailData.createName}}</div>
+              <div class="value">{{detailData.createBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">制单日期</div>
@@ -118,7 +118,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">审核人</div>
-              <div class="value">{{detailData.confirmName}}</div>
+              <div class="value">{{detailData.confirmBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">审核日期</div>
@@ -126,7 +126,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">最后更新人</div>
-              <div class="value">{{detailData.updateName}}</div>
+              <div class="value">{{detailData.updateBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">最后更新日期</div>
@@ -134,7 +134,7 @@
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">关闭人</div>
-              <div class="value">{{detailData.closeName}}</div>
+              <div class="value">{{detailData.closeBy}}</div>
             </el-col>
             <el-col :span="6" class="item">
               <div class="label">关闭日期</div>

+ 3 - 3
src/views/supply/engin/components/home_examine.vue

@@ -117,7 +117,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单日期</div>
@@ -125,7 +125,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭人</div>
-          <div class="value">{{detailData.closeName}}</div>
+          <div class="value">{{detailData.closeBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭日期</div>
@@ -415,7 +415,7 @@ export default {
               this.detailData = res.data;
             }).catch(() => {
               this.goBack();
-              this.$parent.getList();        
+              this.$parent.getList();
             });
           }
         }).finally(res => {

+ 5 - 2
src/views/supply/engin/components/home_form.vue

@@ -506,6 +506,7 @@ export default {
         salesMan: '',
         projectRemark: '',
         projectType: '',
+        tradeCategory: ''
       },
       mainFormRules: {
         // orderDate: [{ required: true, message: '请选择单据日期', trigger: 'change' }],
@@ -766,6 +767,7 @@ export default {
         this.mainForm.declareNo = data.declareNo;
         this.mainForm.projectRemark = data.buChonShuoMing;
         this.mainForm.projectType = data.govBuyType;
+        this.mainForm.tradeCategory = data.tradeCategory;
 
         let saleTypeItem = this.salesTypeList.find(o => o.id == this.mainForm.saleType);
 
@@ -873,7 +875,7 @@ export default {
         this.mainForm.greeRemark = data.geLiInerNote;
         this.mainForm.greeReply = data.note1;
         this.mainForm.remark = data.remark;
-        this.mainForm.createMan = data.createName;
+        this.mainForm.createMan = data.createBy;
         this.mainForm.createDate = data.createTime;
         this.mainForm.fileNum = data.fileNo;
         this.mainForm.salesMan = data.serviceId;
@@ -1119,13 +1121,14 @@ export default {
             saleTypeCode: saleTypeItem.saleCode,
             saleTypeName: saleTypeItem.saleName,
             geLiInerNote: this.mainForm.greeRemark || '',
-            note1: this.mainForm.greeReply || '',
+            geLiNote: this.mainForm.greeReply || '',
             remark: this.mainForm.remark || '',
             fileNo: this.mainForm.fileNum || '',
             serviceId: this.mainForm.salesMan,
             serviceName: saleManItem.nickName,
             refProjectNote: this.mainForm.projectRemark,
             refProjectType: this.mainForm.projectType,
+            refTradeCategory: this.mainForm.tradeCategory,
             items: goodsList,
           }
 

+ 2 - 2
src/views/supply/engin/components/home_return.vue

@@ -107,7 +107,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单人</div>
-          <div class="value">{{detailData.createName}}</div>
+          <div class="value">{{detailData.createBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">制单日期</div>
@@ -115,7 +115,7 @@
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭人</div>
-          <div class="value">{{detailData.closeName}}</div>
+          <div class="value">{{detailData.closeBy}}</div>
         </el-col>
         <el-col :span="6" class="item">
           <div class="label">关闭日期</div>

+ 2 - 2
src/views/supply/engin/engin_list.vue

@@ -138,9 +138,9 @@
                 {{scope.row.totalAmount | numToFixed}}
               </template>
             </el-table-column>
-            <el-table-column align="center" label="制表人" prop="createName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="制表人" prop="createBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="制表日期" prop="createTime" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="审核人" prop="confirmName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="审核人" prop="confirmBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审核日期" prop="confirmTime" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审核状态" prop="examineStatus" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">

+ 34 - 34
src/views/supply/engin/home_list.vue

@@ -96,11 +96,11 @@
         <div class="table">
           <el-table
             v-loading="listLoading"
-            :data="dataList" 
-            element-loading-text="Loading" 
-            border 
-            fit 
-            highlight-current-row 
+            :data="dataList"
+            element-loading-text="Loading"
+            border
+            fit
+            highlight-current-row
             stripe
             @selection-change="handleSelectionChange"
             show-summary
@@ -166,60 +166,60 @@
               </template>
             </el-table-column>
             <el-table-column align="center" label="业务员" prop="serviceName" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="制表人" prop="createName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="制表人" prop="createBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="制表日期" prop="createTime" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="审核人" prop="confirmName" min-width="100" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="审核人" prop="confirmBy" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审核日期" prop="confirmTime" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="操作" width="220" fixed="right">
               <template slot-scope="scope">
-                <el-popconfirm 
-                  style="margin-right: 10px;" 
-                  title="确定申请吗?" 
-                  @onConfirm="handleSubmit(scope.row.parentId)" 
+                <el-popconfirm
+                  style="margin-right: 10px;"
+                  title="确定申请吗?"
+                  @onConfirm="handleSubmit(scope.row.parentId)"
                   v-if="scope.row.examineStatus === 'SAVE'" >
                   <el-button slot="reference" type="text">申请</el-button>
                 </el-popconfirm>
-                <el-popconfirm 
-                  style="margin-right: 10px;" 
-                  title="确定撤回吗?" 
-                  @onConfirm="handleWithdraw(scope.row.parentId)" 
+                <el-popconfirm
+                  style="margin-right: 10px;"
+                  title="确定撤回吗?"
+                  @onConfirm="handleWithdraw(scope.row.parentId)"
                   v-if="scope.row.examineStatus === 'WAIT'" >
                   <el-button slot="reference" type="text">撤回</el-button>
                 </el-popconfirm>
-                <el-popconfirm 
-                  style="margin-right: 10px;" 
-                  title="确定弃审吗?" 
-                  @onConfirm="handleAbandon(scope.row.parentId)" 
+                <el-popconfirm
+                  style="margin-right: 10px;"
+                  title="确定弃审吗?"
+                  @onConfirm="handleAbandon(scope.row.parentId)"
                   v-if="$checkBtnRole('examine', $route.meta.roles) && scope.row.examineStatus === 'OK'" >
                   <el-button slot="reference" type="text">弃审</el-button>
                 </el-popconfirm>
-                <el-button 
-                  type="text" 
-                  @click="toForm(scope.row)" 
+                <el-button
+                  type="text"
+                  @click="toForm(scope.row)"
                   v-if="$checkBtnRole('edit', $route.meta.roles) && (scope.row.examineStatus === 'SAVE' || scope.row.examineStatus === 'FAIL')">
                   编辑
                 </el-button>
-                <el-button 
-                  type="text" 
-                  @click="toExamine(scope.row)" 
+                <el-button
+                  type="text"
+                  @click="toExamine(scope.row)"
                   v-if="$checkBtnRole('examine', $route.meta.roles) && scope.row.examineStatus === 'WAIT'">
                   审批
                 </el-button>
-                <el-button 
-                  type="text" 
-                  @click="toReturn(scope.row)" 
+                <el-button
+                  type="text"
+                  @click="toReturn(scope.row)"
                   v-if="$checkBtnRole('examine', $route.meta.roles) && scope.row.examineStatus !== 'FAIL'">
                   退订
                 </el-button>
-                <el-button 
-                  type="text" 
+                <el-button
+                  type="text"
                   @click="toDetail(scope.row)">
                   详情
                 </el-button>
-                <el-popconfirm 
-                  style="margin-left: 10px;" 
-                  title="确定删除吗?" 
-                  @onConfirm="handleDelete(scope.row.parentId)" 
+                <el-popconfirm
+                  style="margin-left: 10px;"
+                  title="确定删除吗?"
+                  @onConfirm="handleDelete(scope.row.parentId)"
                   v-if="$checkBtnRole('del', $route.meta.roles) && scope.row.examineStatus !== 'OK'">
                   <el-button slot="reference" type="text" style="color: #f56c6c;">删除</el-button>
                 </el-popconfirm>

Alguns arquivos não foram mostrados porque muitos arquivos mudaram nesse diff