(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-d074b11a"],{"15a9":function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));n("6b07"),n("62f9"),n("5ff7"),n("7d1c"),n("decd"),n("484a"),n("96f8");function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function r(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function i(t){for(var e=1;e1?arguments[1]:void 0)}})},3422:function(t,e,n){"use strict";var o=n("4292"),r=n("6ff7"),i=n("11a1"),a=n("8531");o({target:"String",proto:!0,forced:!a("includes")},{includes:function(t){return!!~String(i(this)).indexOf(r(t),arguments.length>1?arguments[1]:void 0)}})},"365c":function(t,e,n){"use strict";n.d(e,"Q",(function(){return r})),n.d(e,"z",(function(){return i})),n.d(e,"l",(function(){return a})),n.d(e,"y",(function(){return s})),n.d(e,"O",(function(){return u})),n.d(e,"P",(function(){return l})),n.d(e,"eb",(function(){return c})),n.d(e,"fb",(function(){return p})),n.d(e,"c",(function(){return d})),n.d(e,"o",(function(){return m})),n.d(e,"D",(function(){return f})),n.d(e,"T",(function(){return b})),n.d(e,"E",(function(){return h})),n.d(e,"d",(function(){return g})),n.d(e,"U",(function(){return v})),n.d(e,"p",(function(){return k})),n.d(e,"J",(function(){return O})),n.d(e,"K",(function(){return j})),n.d(e,"bb",(function(){return x})),n.d(e,"u",(function(){return y})),n.d(e,"L",(function(){return w})),n.d(e,"j",(function(){return P})),n.d(e,"cb",(function(){return S})),n.d(e,"w",(function(){return $})),n.d(e,"I",(function(){return D})),n.d(e,"i",(function(){return z})),n.d(e,"Z",(function(){return _})),n.d(e,"t",(function(){return Q})),n.d(e,"g",(function(){return L})),n.d(e,"A",(function(){return R})),n.d(e,"f",(function(){return V})),n.d(e,"W",(function(){return q})),n.d(e,"r",(function(){return T})),n.d(e,"G",(function(){return C})),n.d(e,"h",(function(){return E})),n.d(e,"s",(function(){return A})),n.d(e,"H",(function(){return F})),n.d(e,"a",(function(){return I})),n.d(e,"m",(function(){return J})),n.d(e,"B",(function(){return N})),n.d(e,"v",(function(){return U})),n.d(e,"R",(function(){return B})),n.d(e,"X",(function(){return G})),n.d(e,"Y",(function(){return H})),n.d(e,"ab",(function(){return K})),n.d(e,"C",(function(){return M})),n.d(e,"b",(function(){return W})),n.d(e,"S",(function(){return X})),n.d(e,"n",(function(){return Y})),n.d(e,"M",(function(){return Z})),n.d(e,"N",(function(){return tt})),n.d(e,"k",(function(){return et})),n.d(e,"db",(function(){return nt})),n.d(e,"x",(function(){return ot})),n.d(e,"F",(function(){return rt})),n.d(e,"e",(function(){return it})),n.d(e,"V",(function(){return at})),n.d(e,"q",(function(){return st}));var o=n("b775");function r(t){return Object(o["a"])({url:"/api/v1/kxpms/workbench/query",method:"post",data:t})}function i(t){return Object(o["a"])({url:"/api/v1/kxpms/login/login",method:"post",data:t})}function a(t){return Object(o["a"])({url:"/api/v1/kxpms/user/add",method:"post",data:t})}function s(t){return Object(o["a"])({url:"/api/v1/kxpms/user/delete/".concat(t),method:"post"})}function u(t){return Object(o["a"])({url:"/api/v1/kxpms/user/get",method:"post",data:t})}function l(t){return Object(o["a"])({url:"/api/v1/kxpms/user/list",method:"post",data:t})}function c(t,e){return Object(o["a"])({url:"/api/v1/kxpms/user/update/".concat(t),method:"post",data:e})}function p(t){return Object(o["a"])({url:"/api/v1/kxpms/updatePassword",method:"post",data:t})}function d(t){return Object(o["a"])({url:"/api/v1/kxpms/depot/add",method:"post",data:t})}function m(t){return Object(o["a"])({url:"/api/v1/kxpms/depot/delete/".concat(t),method:"post"})}function f(t){return Object(o["a"])({url:"/api/v1/kxpms/depot/list",method:"post",data:t})}function b(t,e){return Object(o["a"])({url:"/api/v1/kxpms/depot/update/".concat(t),method:"post",data:e})}function h(t){return Object(o["a"])({url:"/api/v1/kxpms/dict/list",method:"post",data:t})}function g(t){return Object(o["a"])({url:"/api/v1/kxpms/dict/add",method:"post",data:t})}function v(t,e){return Object(o["a"])({url:"/api/v1/kxpms/dict/update/".concat(t),method:"post",data:e})}function k(t){return Object(o["a"])({url:"/api/v1/kxpms/dict/delete/".concat(t),method:"post"})}function O(t){return Object(o["a"])({url:"/api/v1/kxpms/project/get",method:"post",data:t})}function j(t){return Object(o["a"])({url:"/api/v1/kxpms/project/list",method:"post",data:t})}function x(t,e){return Object(o["a"])({url:"/api/v1/kxpms/project/update/".concat(t),method:"post",data:e})}function y(t){return Object(o["a"])({url:"/api/v1/kxpms/project/delete/".concat(t),method:"post"})}function w(t){return Object(o["a"])({url:"/api/v1/kxpms/role/list",method:"post",data:t})}function P(t){return Object(o["a"])({url:"/api/v1/kxpms/role/add",method:"post",data:t})}function S(t,e){return Object(o["a"])({url:"/api/v1/kxpms/role/update/".concat(t),method:"post",data:e})}function $(t){return Object(o["a"])({url:"/api/v1/kxpms/role/delete/".concat(t),method:"delete"})}function D(t){return Object(o["a"])({url:"/api/v1/kxpms/permission/list",method:"post",data:t})}function z(t){return Object(o["a"])({url:"/api/v1/kxpms/permission/add",method:"post",data:t})}function _(t,e){return Object(o["a"])({url:"/api/v1/kxpms/permission/update/".concat(t),method:"post",data:e})}function Q(t){return Object(o["a"])({url:"/api/v1/kxpms/permission/delete/".concat(t),method:"post"})}function L(t){return Object(o["a"])({url:"/api/v1/kxpms/system/addProject",method:"post",data:t})}function R(t){return Object(o["a"])({url:"/api/v1/kxpms/system/exportProject",method:"post",data:t})}function V(t){return Object(o["a"])({url:"/api/v1/kxpms/flow/add",method:"post",data:t})}function q(t,e){return Object(o["a"])({url:"/api/v1/kxpms/flow/update/".concat(t),method:"post",data:e})}function T(t){return Object(o["a"])({url:"/api/v1/kxpms/flow/delete/".concat(t),method:"delete"})}function C(t){return Object(o["a"])({url:"/api/v1/kxpms/system/getFlowList",method:"post",data:t})}function E(t){return Object(o["a"])({url:"/api/v1/kxpms/payback/add",method:"post",data:t})}function A(t){return Object(o["a"])({url:"/api/v1/kxpms/payback/delete/".concat(t),method:"post"})}function F(t){return Object(o["a"])({url:"/api/v1/kxpms/system/getPaybackList",method:"post",data:t})}function I(t){return Object(o["a"])({url:"/api/v1/kxpms/annex/add",method:"post",data:t})}function J(t){return Object(o["a"])({url:"/api/v1/kxpms/annex/delete/".concat(t),method:"post"})}function N(t){return Object(o["a"])({url:"/api/v1/kxpms/annex/list",method:"post",data:t})}function U(t){return Object(o["a"])({url:"/api/v1/kxpms/system/deleteProjectUser",method:"post",data:t})}function B(t){return Object(o["a"])({url:"/api/v1/kxpms/system/modifyProjectUser",method:"post",data:t})}function G(t){return Object(o["a"])({url:"/api/v1/kxpms/system/updateFlow",method:"post",data:t})}function H(t){return Object(o["a"])({url:"/api/v1/kxpms/system/updatePayback",method:"post",data:t})}function K(t){return Object(o["a"])({url:"/api/v1/kxpms/system/updateProductionPlan",method:"post",data:t})}function M(t){return Object(o["a"])({url:"/api/v1/kxpms/calendar/list",method:"post",data:t})}function W(t){return Object(o["a"])({url:"/api/v1/kxpms/calendar/add",method:"post",data:t})}function X(t,e){return Object(o["a"])({url:"/api/v1/kxpms/calendar/update/".concat(t),method:"post",data:e})}function Y(t){return Object(o["a"])({url:"/api/v1/kxpms/calendar/delete/".concat(t),method:"post"})}function Z(t){return Object(o["a"])({url:"/api/v1/kxpms/system/getRoleUsers",method:"post",data:t})}function tt(t){return Object(o["a"])({url:"/api/v1/kxpms/summary/list",method:"post",data:t})}function et(t){return Object(o["a"])({url:"/api/v1/kxpms/summary/add",method:"post",data:t})}function nt(t,e){return Object(o["a"])({url:"/api/v1/kxpms/summary/update/".concat(t),method:"post",data:e})}function ot(t){return Object(o["a"])({url:"/api/v1/kxpms/summary/delete/".concat(t),method:"post"})}function rt(t){return Object(o["a"])({url:"/api/v1/kxpms/netdisc/list",method:"post",data:t})}function it(t){return Object(o["a"])({url:"/api/v1/kxpms/netdisc/add",method:"post",data:t})}function at(t,e){return Object(o["a"])({url:"/api/v1/kxpms/netdisc/update/".concat(t),method:"post",data:e})}function st(t){return Object(o["a"])({url:"/api/v1/kxpms/netdisc/delete",method:"post",data:t})}},"60a8":function(t,e,n){"use strict";var o=n("4292"),r=n("4c15").includes,i=n("e517");o({target:"Array",proto:!0},{includes:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),i("includes")},"6ff7":function(t,e,n){var o=n("0c6e");t.exports=function(t){if(o(t))throw TypeError("The method doesn't accept regular expressions");return t}},"7d1c":function(t,e,n){var o=n("4292"),r=n("bc5d"),i=n("b9dd"),a=n("016e").f,s=n("61a2"),u=r((function(){a(1)})),l=!s||u;o({target:"Object",stat:!0,forced:l,sham:!s},{getOwnPropertyDescriptor:function(t,e){return a(i(t),e)}})},8531:function(t,e,n){var o=n("9345"),r=o("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[r]=!1,"/./"[t](e)}catch(o){}}return!1}},d75f:function(t,e,n){},d7ee:function(t,e,n){"use strict";n("d75f")},decd:function(t,e,n){var o=n("4292"),r=n("61a2"),i=n("1578"),a=n("b9dd"),s=n("016e"),u=n("5c14");o({target:"Object",stat:!0,sham:!r},{getOwnPropertyDescriptors:function(t){var e,n,o=a(t),r=s.f,l=i(o),c={},p=0;while(l.length>p)n=r(o,e=l[p++]),void 0!==n&&u(c,e,n);return c}})},e350:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));n("60a8"),n("2c51"),n("3422");var o=n("4360");function r(t){if(t&&t instanceof Array&&t.length>0){var e=o["a"].getters&&o["a"].getters.permissions,n=t,r=e.some((function(t){return n.includes(t)}));return!!r}return console.error("need roles! Like v-permission=\"['admin','editor']\""),!1}},f982:function(t,e,n){"use strict";n.r(e);var o=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"app-container"},[n("el-form",{attrs:{inline:!0,model:t.form,size:"mini"}},[n("el-form-item",{attrs:{label:"角色名称"}},[n("el-select",{attrs:{filterable:"",placeholder:"请输入角色名称"},model:{value:t.form.uuid,callback:function(e){t.$set(t.form,"uuid",e)},expression:"form.uuid"}},t._l(t.roles,(function(t,e){return n("el-option",{key:e,attrs:{label:t.name,value:t.uuid}})})),1)],1),n("el-form-item",[n("el-button",{attrs:{type:"primary"},on:{click:t.onSubmit}},[t._v("查询")])],1),n("el-form-item",[n("el-button",{on:{click:t.onReset}},[t._v("重置")])],1),n("el-form-item",[n("el-button",{attrs:{type:"warning"},on:{click:t.onAdd}},[t._v("添加")])],1)],1),n("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.isLoading,expression:"isLoading"}],attrs:{"element-loading-text":"Loading",data:t.list,size:"mini",border:"",stripe:"",fit:"","highlight-current-row":""}},[n("el-table-column",{attrs:{prop:"name",label:"角色名称",align:"center","min-width":"150","show-overflow-tooltip":!0}}),n("el-table-column",{attrs:{prop:"is_system",label:"系统角色",width:"80"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("span",[t._v(t._s(e.row.is_system?"是":"否"))])]}}])}),n("el-table-column",{attrs:{prop:"create_at",label:"创建时间",width:"150"}}),n("el-table-column",{attrs:{prop:"create_by.username",label:"创建者",width:"150"}}),n("el-table-column",{attrs:{prop:"update_at",label:"更新时间",width:"150"}}),n("el-table-column",{attrs:{prop:"update_by.username",label:"更新者",width:"150"}}),n("el-table-column",{attrs:{label:"操作",align:"center",width:"180",fixed:"right"},scopedSlots:t._u([{key:"default",fn:function(e){return[n("el-button",{attrs:{size:"mini",type:"success",disabled:t.hasPermission},on:{click:function(n){return t.handleEdit(e.$index,e.row)}}},[t._v("编辑")]),n("el-button",{attrs:{size:"mini",type:"danger",disabled:e.row.is_system},on:{click:function(n){return t.handleDelete(e.$index,e.row)}}},[t._v("删除")])]}}])})],1),n("div",{staticClass:"page-wrapper"},[n("el-pagination",{attrs:{"current-page":t.form.pagenum,background:"",small:"","page-size":t.form.pagesize,"pager-count":5,layout:"pager, prev, next, total",total:t.total},on:{"current-change":t.handleCurrentChange,"update:currentPage":function(e){return t.$set(t.form,"pagenum",e)},"update:current-page":function(e){return t.$set(t.form,"pagenum",e)}}})],1),n("el-dialog",{attrs:{title:t.dialogTitle,visible:t.dialogVisible,width:"45%"},on:{"update:visible":function(e){t.dialogVisible=e}}},[n("el-form",{ref:"post",attrs:{model:t.post,"status-icon":"",rules:t.rules,inline:!0,size:"mini","label-width":"120px"}},[n("el-form-item",{attrs:{label:"角色名称",prop:"name"}},[n("el-input",{attrs:{type:"text",disabled:t.post.is_system,autocomplete:"off",placeholder:"请输入角色名称"},model:{value:t.post.name,callback:function(e){t.$set(t.post,"name",e)},expression:"post.name"}})],1),n("el-divider",{attrs:{"content-position":"left"}},[t._v("操作权限")]),n("el-form-item",{attrs:{label:"基础信息权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.basic,callback:function(e){t.$set(t.post.permission,"basic",e)},expression:"post.permission.basic"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"流程管理权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.flow,callback:function(e){t.$set(t.post.permission,"flow",e)},expression:"post.permission.flow"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"回款计划权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.paybackPlan,callback:function(e){t.$set(t.post.permission,"paybackPlan",e)},expression:"post.permission.paybackPlan"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"回款进度权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.paybackProgress,callback:function(e){t.$set(t.post.permission,"paybackProgress",e)},expression:"post.permission.paybackProgress"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"技术资源库权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.techResources,callback:function(e){t.$set(t.post.permission,"techResources",e)},expression:"post.permission.techResources"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"技术日历权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.calendar,callback:function(e){t.$set(t.post.permission,"calendar",e)},expression:"post.permission.calendar"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"用户管理权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.users,callback:function(e){t.$set(t.post.permission,"users",e)},expression:"post.permission.users"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"角色管理权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.roles,callback:function(e){t.$set(t.post.permission,"roles",e)},expression:"post.permission.roles"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"部门管理权限",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.depots,callback:function(e){t.$set(t.post.permission,"depots",e)},expression:"post.permission.depots"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"人员资质预警",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.personQualification,callback:function(e){t.$set(t.post.permission,"personQualification",e)},expression:"post.permission.personQualification"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"设备资质预警",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.equipmentQualification,callback:function(e){t.$set(t.post.permission,"equipmentQualification",e)},expression:"post.permission.equipmentQualification"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-form-item",{attrs:{label:"公司资质预警",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.companyQualification,callback:function(e){t.$set(t.post.permission,"companyQualification",e)},expression:"post.permission.companyQualification"}},[n("el-radio-button",{attrs:{label:"可读"}}),n("el-radio-button",{attrs:{label:"可读写"}}),n("el-radio-button",{attrs:{label:"无权限"}})],1)],1),n("el-divider",{attrs:{"content-position":"left"}},[t._v("数据范围")]),n("el-form-item",{attrs:{label:"项目数据范围",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.dataScope,callback:function(e){t.$set(t.post.permission,"dataScope",e)},expression:"post.permission.dataScope"}},[n("el-radio-button",{attrs:{label:"自己的"}}),n("el-radio-button",{attrs:{label:"部门的"}}),n("el-radio-button",{attrs:{label:"公司的"}})],1)],1),n("el-form-item",{attrs:{label:"预警数据范围",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.warningDataScope,callback:function(e){t.$set(t.post.permission,"warningDataScope",e)},expression:"post.permission.warningDataScope"}},[n("el-radio-button",{attrs:{label:"自己的"}}),n("el-radio-button",{attrs:{label:"部门的"}}),n("el-radio-button",{attrs:{label:"公司的"}})],1)],1),n("el-form-item",{attrs:{label:"日历数据范围",prop:"permission"}},[n("el-radio-group",{attrs:{size:"mini"},model:{value:t.post.permission.calendarDataScope,callback:function(e){t.$set(t.post.permission,"calendarDataScope",e)},expression:"post.permission.calendarDataScope"}},[n("el-radio-button",{attrs:{label:"自己的"}}),n("el-radio-button",{attrs:{label:"部门的"}}),n("el-radio-button",{attrs:{label:"公司的"}})],1)],1)],1),n("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{attrs:{type:"primary",size:"mini",plain:""},on:{click:function(e){return t.submitForm("post")}}},[t._v("提交")]),n("el-button",{attrs:{type:"success",size:"mini",plain:""},on:{click:function(e){return t.onReset("post")}}},[t._v("重置")]),n("el-button",{attrs:{size:"mini"},on:{click:function(e){t.dialogVisible=!1}}},[t._v("关闭")])],1)],1)],1)},r=[],i=(n("82a8"),n("2a39"),n("15a9")),a=n("7736"),s=n("365c"),u=n("e350"),l=n("ed08"),c={data:function(){return{total:0,list:[],isLoading:!1,roles:[],form:{uuid:null,name:null,pagesize:15,pagenum:1},dialogTitle:"",dialogVisible:!1,currentValue:null,currentIndex:null,post:{name:null,permission:{basic:"无权限",flow:"无权限",users:"无权限",roles:"无权限",depots:"无权限",paybackPlan:"无权限",paybackProgress:"无权限",personQualification:"无权限",equipmentQualification:"无权限",companyQualification:"无权限",techResources:"无权限",calendar:"无权限",dataScope:"自己的",warningDataScope:"自己的",calendarDataScope:"自己的"},is_system:!1},rules:{name:[{type:"string",required:!0,message:"用户名不能为空",trigger:"blur"},{min:1,max:20,message:"字符串长度在 1 到 20 之间",trigger:"blur"}],permission:[{type:"object",required:!0,message:"权限不能为空",trigger:"blur"}]}}},computed:Object(i["a"])(Object(i["a"])(Object(i["a"])({},Object(a["c"])("user",["avatar"])),Object(a["b"])(["role"])),{},{hasPermission:function(){return"超级管理员"!==JSON.parse(sessionStorage.getItem("user")).role.name}}),methods:{checkPermission:u["a"],fetchData:function(t){var e=this;this.isLoading=!0,Object(s["L"])(Object.assign({pagenum:this.form.pagenum,pagesize:this.form.pagesize},t)).then((function(t){e.total=t.count,e.list=t.data})).catch((function(t){console.log(t.message)})).finally((function(){e.isLoading=!1}))},fetchSelectData:function(){var t=this;Object(s["L"])({scope_type:"list"}).then((function(e){200==e.code&&(t.roles=e.data)})).catch((function(t){console.log(t.message)}))},handleSizeChange:function(t){this.form.pagesize=t,this.fetchData(Object(l["e"])(this.form))},handleCurrentChange:function(t){this.form.pagenum=t,this.fetchData(Object(l["e"])(this.form))},handleEdit:function(t,e){if(e.is_system&&this.hasPermission)return this.$message.error("系统内置角色,无法修改");e.permission.basic&&(this.post.permission.basic=e.permission.basic),e.permission.dataScope&&(this.post.permission.dataScope=e.permission.dataScope),e.permission.flow&&(this.post.permission.flow=e.permission.flow),e.permission.users&&(this.post.permission.users=e.permission.users),e.permission.roles&&(this.post.permission.roles=e.permission.roles),e.permission.depots&&(this.post.permission.depots=e.permission.depots),e.permission.paybackPlan&&(this.post.permission.paybackPlan=e.permission.paybackPlan),e.permission.paybackProgress&&(this.post.permission.paybackProgress=e.permission.paybackProgress),e.permission.personQualification&&(this.post.permission.personQualification=e.permission.personQualification),e.permission.equipmentQualification&&(this.post.permission.equipmentQualification=e.permission.equipmentQualification),e.permission.companyQualification&&(this.post.permission.companyQualification=e.permission.companyQualification),e.permission.techResources&&(this.post.permission.techResources=e.permission.techResources),e.permission.calendar&&(this.post.permission.calendar=e.permission.calendar),e.permission.calendarDataScope&&(this.post.permission.calendarDataScope=e.permission.calendarDataScope),e.permission.warningDataScope&&(this.post.permission.warningDataScope=e.permission.warningDataScope),this.post.name=e.name,this.post.is_system=e.is_system,this.currentValue=e,this.currentIndex=t,this.dialogTitle="编辑",this.dialogVisible=!0},handleDelete:function(t,e){var n=this;if(e.is_system)return this.$message.error("系统内置角色,无法删除");this.$alert("您确定要删除么?删除操作将不可恢复。如需取消操作,请点击右上角关闭按钮。","删除提醒",{confirmButtonText:"确定",callback:function(o){"confirm"==o&&Object(s["w"])(e.uuid).then((function(e){console.log(e),n.total-=1,n.$delete(n.list,t),n.$message({type:"success",message:"成功删除第".concat(t,"行")}),n.fetchData()})).catch((function(t){n.$message.error(t.message)}))}})},submitForm:function(t){var e=this;this.$refs[t].validate((function(t){var n=!0;return t?"添加"===e.dialogTitle?Object(s["j"])(e.post).then((function(t){console.log(t),e.$message({type:"success",message:"添加成功"}),e.fetchData()})).catch((function(t){e.$message.error(t.message)})):"编辑"===e.dialogTitle&&Object(s["cb"])(e.currentValue.uuid,Object(l["a"])(e.post,e.currentValue)).then((function(t){console.log(t),e.$message({type:"success",message:"更新成功"}),e.fetchData()})).catch((function(t){e.$message.error(t.message)})):n=!1,e.dialogVisible=!1,n}))},onAdd:function(){this.dialogTitle="添加",this.dialogVisible=!0},onSubmit:function(){this.form.pagenum=1,this.form.pagesize=15,this.fetchData(Object(l["e"])(this.form))},onReset:function(t){this.form={account:null,username:null,pagesize:15,pagenum:1},this.$refs[t].resetFields(),this.fetchData()}},mounted:function(){},created:function(){this.fetchData(),this.fetchSelectData();var t=JSON.parse(sessionStorage.getItem("user"));t&&"无权限"!=t.role.permission.roles||this.$router.push("/403")}},p=c,d=(n("d7ee"),n("5d22")),m=Object(d["a"])(p,o,r,!1,null,"c5e2f406",null);e["default"]=m.exports}}]);