schangxiang@126.com
2025-09-19 0821aa23eabe557c0d9ef5dbe6989c68be35d1fe
1
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-40c5"],{CZs7:function(e,t,o){"use strict";var n=o("TUYA");o.n(n).a},DNkW:function(e,t,o){var n=o("93I4"),a=Math.floor;e.exports=function(e){return!n(e)&&isFinite(e)&&a(e)===e}},"GW1+":function(e,t,o){"use strict";var n=o("mxV5"),a=o.n(n);t.a=function(e){return new a.a(e)}},IfNc:function(e,t,o){"use strict";var n=o("MX4z");o.n(n).a},MX4z:function(e,t,o){},Pv5g:function(e,t,o){"use strict";var n=o("ylC3");o.n(n).a},TUYA:function(e,t,o){},h5AQ:function(e,t,o){o("hRZT"),e.exports=o("WEpk").Number.isInteger},hRZT:function(e,t,o){var n=o("Y7ZC");n(n.S,"Number",{isInteger:o("DNkW")})},"j+QC":function(e,t,o){"use strict";o.r(t);var n=o("QpdM"),a=o("90mL"),i=o("E9g8"),s=o("dWSf"),r={name:"dept-tab",custoJsonmRoute:"/sys/permission/dept",components:{splitPane:n.a,yrtDataList:a.a,yrtEditor:i.a},mixins:[s.a],data:function(){return{filterText:"",dataTree:[],treeNodeOverId:0,props:{label:"label",children:"children",isLeaf:"isLeaf"}}},watch:{filterText:function(e){this.$refs.tree.filter(e)}},created:function(){},methods:{loadTreeNode:function(e,t){var o=this,n=this;n.$nextTick(function(){var a=o.common.getUserInfo(),i={openNodeApi:!0,folder:"sys/core",DBServer:"Sys",tableName:"Sys_Dept",tableView:"Sys_Dept",keyName:"dept_Id",nodeName:"deptName",fixHasChild:!1,isBreakWay:!1,displayBreakWay:!1,parentName:"parentId",orderBy:"OrderNo desc, dept_Id",where:0===e.level?{userProduct_Id:a.userProduct_Id,parentId:0}:{userProduct_Id:a.userProduct_Id,parentId:e.data.dept_Id},extendColumns:""};n.common.ajax("/api/common/loadTreeNode",i,function(e){e.result?(e.data.forEach(function(e){e.isLeaf=!e.hasChild}),t(e.data)):n.$message.error(e.msg)},!0)})},filterTreeNode:function(e,t){return!e||-1!==t.label.indexOf(e)},nodeClick:function(e,t,o){var n="dept_Id in(Select dept_Id from dbo.[GetDeptTree]("+e.dept_Id+"))";this.dataList.reloadData(n)},treeRefresh:function(){this.filterText="";for(var e=this.$refs.tree.store.root;e.childNodes.length;)this.$refs.tree.remove(e.childNodes[0]);this.loadTreeNode(e,function(t){e.doCreateChildren(t)})},treeNodeAppend:function(e,t){this.editor.addData()},treeNodeEdit:function(e,t){this.editor.editData(t.dept_Id)},treeNodeRemove:function(e,t){this.dataList.delete(t.dept_Id)},treeNodeOver:function(e,t){this.treeNodeOverId=t.value},treeNodeOut:function(e,t){this.treeNodeOverId=-1},onFocus:function(e,t,o,n){n&&"fullPathId"===n.options.prop&&!n.options.isLoaded&&(this.cascaderLoadNode(e,0,n),n.options.isLoaded=!0)},onChange:function(e,t,o){var n=this.editor;"fullPathId"===o.options.prop&&(n.formData.parentId=t[t.length-1],setTimeout(function(){n.formData.fullPathName=e.inputValue},500))},cascaderLoadNode:function(e,t,o){var n=this,a={openNodeApi:!0,folder:"sys/core",DBServer:"Sys",tableName:"Sys_Dept",tableView:"Sys_Dept",keyName:"dept_Id",nodeName:"deptName",fixHasChild:!1,isBreakWay:!1,displayBreakWay:!1,parentName:"parentId",orderBy:"OrderNo desc, dept_Id",where:{parentId:0,userProduct_Id:this.common.getUserInfo().userProduct_Id},extendColumns:""};n.common.ajax("/api/common/loadTreeNodeAll",a,function(e){if(e.result){var t=[{value:0,label:"根",children:e.data}];o.options.options=t}else n.$message.error(e.msg)},!0)},onDeleteAfter:function(){this.treeRefresh()}}},d=(o("CZs7"),o("KHd+")),l=Object(d.a)(r,function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"tab-container"},[o("split-pane",{attrs:{"max-width":500,"default-width":260,split:"vertical"}},[o("div",{staticClass:"left-container",attrs:{slot:"paneL"},slot:"paneL"},[o("el-form",{staticClass:"form-tool"},[o("el-form-item",[o("el-input",{staticClass:"search-input",attrs:{placeholder:"搜索名称","prefix-icon":"el-icon-search"},model:{value:e.filterText,callback:function(t){e.filterText=t},expression:"filterText"}}),e._v(" "),o("el-button",{staticClass:"btn-refresh",attrs:{title:"刷新",icon:"el-icon-yrt-shuaxin"},nativeOn:{click:function(t){return e.treeRefresh(t)}}})],1),e._v(" "),o("el-form-item",[o("el-tree",{ref:"tree",attrs:{data:e.dataTree,"expand-on-click-node":!1,load:function(t,o){e.loadTreeNode(t,o)},"filter-node-method":e.filterTreeNode,props:e.props,"default-expand-all":!1,"highlight-current":"",lazy:"","node-key":"treeKey"},on:{"node-click":e.nodeClick},scopedSlots:e._u([{key:"default",fn:function(t){var n=t.node,a=t.data;return o("span",{staticClass:"custom-tree-node",on:{mouseover:function(){return e.treeNodeOver(n,a)},mouseout:function(){return e.treeNodeOut(n,a)}}},[o("span",[a.hasChild?o("i",{staticClass:"el-icon-menu"}):o("i",{staticClass:"el-icon-tickets"}),e._v("\n                "+e._s(n.label)+"\n              ")]),e._v(" "),o("span",{directives:[{name:"show",rawName:"v-show",value:a.value==e.treeNodeOverId,expression:"data.value==treeNodeOverId"}]},[o("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(){return e.treeNodeAppend(n,a)}}},[o("i",{staticClass:"el-icon-circle-plus-outline"})]),e._v(" "),o("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(){return e.treeNodeEdit(n,a)}}},[o("i",{staticClass:"el-icon-edit-outline"})]),e._v(" "),o("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(){return e.treeNodeRemove(n,a)}}},[o("i",{staticClass:"el-icon-delete"})])],1)])}}])})],1)],1)],1),e._v(" "),o("div",{staticClass:"right-container",attrs:{slot:"paneR"},slot:"paneR"},[o("yrt-data-list",{ref:e.dataListRef,attrs:{"editor-ref":e.editorRef,"data-options":e.dataOptions,fields:e.dataListOptions.fields,buttons:e.dataListOptions.buttons,"button-click":e.buttonClick,"auth-nodes":e.authNodes,"data-list-selections":e.dataListSelections},on:{"update:fields":function(t){return e.$set(e.dataListOptions,"fields",t)},"update:dataListSelections":function(t){e.dataListSelections=t},"update:data-list-selections":function(t){e.dataListSelections=t},"on-delete-after":e.onDeleteAfter}}),e._v(" "),o("yrt-editor",e._b({ref:e.editorRef,attrs:{"data-list-ref":e.dataListRef,"data-options":e.dataOptions,action:e.editorOptions.action,top:e.editorOptions.top,visible:e.editorOptions.config.visible,"auth-nodes":e.authNodes},on:{"update:action":function(t){return e.$set(e.editorOptions,"action",t)},"update:top":function(t){return e.$set(e.editorOptions,"top",t)},"update:visible":function(t){return e.$set(e.editorOptions.config,"visible",t)},"on-focus":e.onFocus,"on-change":e.onChange}},"yrt-editor",e.editorOptions,!1))],1)])],1)},[],!1,null,"76d0a6ba",null);l.options.__file="dept-tab.vue";var c=l.exports,u={custoJsonmRoute:"/sys/permission/user",name:"user-tab",components:{splitPane:n.a,yrtDataList:a.a,yrtEditor:i.a},mixins:[s.a],data:function(){var e=this;return{filterText:"",dataTree:[],actionField:{prop:"_action",label:"操作",width:"120",headerAlign:"center",align:"center",action:[{type:"button",action:"Enable",label:"禁用",onClick:function(t,o){return e.rowDisabledUser(t,o),!0}},{type:"button",action:"edit",label:"编辑"},{type:"button",action:"delete",label:"删除"}],hidden:!1}}},watch:{filterText:function(e){this.$refs.tree.filter(e)}},created:function(){},methods:{loadTreeNode:function(e,t){var o=this,n=this;n.$nextTick(function(){var a=o.common.getUserInfo(),i={openNodeApi:!0,folder:"sys/core",DBServer:"Sys",tableName:"Sys_Dept",tableView:"Sys_Dept",keyName:"dept_Id",nodeName:"deptName",fixHasChild:!1,isBreakWay:!1,displayBreakWay:!1,parentName:"parentId",orderBy:"orderNo desc, dept_Id",where:0===e.level?{userProduct_Id:a.userProduct_Id,parentId:0}:{userProduct_Id:a.userProduct_Id,parentId:e.data.dept_Id},extendColumns:""};n.common.ajax("/api/common/loadTreeNode",i,function(e){e.result?t(e.data):n.$message.error(e.msg)},!0)})},filterTreeNode:function(e,t){return!e||-1!==t.label.indexOf(e)},nodeClick:function(e,t,o){var n="dept_Id in(Select dept_Id from dbo.[GetDeptTree]("+e.dept_Id+"))";this.dataList.reloadData(n)},treeRefresh:function(){this.filterText="";for(var e=this.$refs.tree.store.root;e.childNodes.length;)this.$refs.tree.remove(e.childNodes[0]);this.loadTreeNode(e,function(t){e.doCreateChildren(t)})},onFocus:function(e,t,o){"fullPathId"!==o.options.prop||o.options.isLoaded||(this.cascaderLoadNode(e,0,o),o.options.isLoaded=!0)},onChange:function(e,t,o){var n=this.editor;"fullPathId"===o.options.prop&&(n.formData.parentId=t[t.length-1],setTimeout(function(){n.formData.fullPathName=e.inputValue},500))},cascaderLoadNode:function(e,t,o){var n=this,a={openNodeApi:!0,folder:"sys/core",DBServer:"Sys",tableName:"Sys_Dept",tableView:"Sys_Dept",keyName:"dept_Id",nodeName:"deptName",fixHasChild:!1,isBreakWay:!1,displayBreakWay:!1,parentName:"parentId",orderBy:"orderNo desc, dept_Id",where:{parentId:0},extendColumns:""};n.common.ajax("/api/common/loadTreeNodeAll",a,function(e){if(e.result){var t=[{value:0,label:"根",children:e.data}];o.options.options=t}else n.$message.error(e.msg)},!0)},onDeleteAfter:function(){this.treeRefresh()},rowDisabledUser:function(e,t){var o=this;this.$confirm("确定要进行禁用操作吗?","禁用",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var e={openNodeApi:!0,user_Id:t.user_Id},n=o.findRef(o.dataListRef);o.common.ajax("/api/sys/user/disabledUser",e,function(e){o.common.showMsg(e),e.result&&(n.loadData(),o.editorOptions.config.visible=!1)},n)}).catch(function(){o.$message({type:"info",message:"已取消"})})}}},p=(o("Pv5g"),Object(d.a)(u,function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"tab-container"},[o("split-pane",{attrs:{"max-width":500,"default-width":260,split:"vertical"}},[o("div",{staticClass:"left-container",attrs:{slot:"paneL"},slot:"paneL"},[o("el-form",{staticClass:"form-tool"},[o("el-form-item",[o("el-input",{staticClass:"search-input",attrs:{placeholder:"搜索名称","prefix-icon":"el-icon-search"},model:{value:e.filterText,callback:function(t){e.filterText=t},expression:"filterText"}}),e._v(" "),o("el-button",{staticClass:"btn-refresh",attrs:{title:"刷新",icon:"el-icon-yrt-shuaxin"},nativeOn:{click:function(t){return e.treeRefresh(t)}}})],1),e._v(" "),o("el-form-item",[o("el-tree",{ref:"tree",attrs:{data:e.dataTree,"expand-on-click-node":!1,load:function(t,o){e.loadTreeNode(t,o)},"filter-node-method":e.filterTreeNode,lazy:"","highlight-current":"","default-expand-all":"","node-key":"treeKey"},on:{"node-click":e.nodeClick},scopedSlots:e._u([{key:"default",fn:function(t){var n=t.node,a=t.data;return o("span",{staticClass:"custom-tree-node"},[o("span",[a.hasChild?o("i",{staticClass:"el-icon-menu"}):o("i",{staticClass:"el-icon-tickets"}),e._v("\n                "+e._s(n.label)+"\n              ")])])}}])})],1)],1)],1),e._v(" "),o("div",{staticClass:"right-container",attrs:{slot:"paneR"},slot:"paneR"},[o("yrt-data-list",{ref:e.dataListRef,attrs:{"editor-ref":e.editorRef,"data-options":e.dataOptions,fields:e.dataListOptions.fields,buttons:e.dataListOptions.buttons,"button-click":e.buttonClick,"action-field":e.actionField,"data-list-selections":e.dataListSelections,"auth-nodes":e.authNodes,"fixed-where":{enable:1}},on:{"update:fields":function(t){return e.$set(e.dataListOptions,"fields",t)},"update:dataListSelections":function(t){e.dataListSelections=t},"update:data-list-selections":function(t){e.dataListSelections=t},"on-delete-after":e.onDeleteAfter},scopedSlots:e._u([{key:"common-column-slot",fn:function(t){var n=t.row,a=t.col;return["enable"==a.prop?[1==n[a.prop]?[o("el-tag",{staticStyle:{color:"white",border:"0"},attrs:{color:"#7aaffe"}},[e._v("\n                "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop],a.dropdown_Id))+"\n              ")])]:[o("el-tag",{staticStyle:{color:"white",border:"0"},attrs:{color:"#ffcc33"}},[e._v("\n                "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop]||0,a.dropdown_Id))+"\n              ")])]]:"sex"==a.prop?[e._v("\n            "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop]||0,a.dropdown_Id))+"\n          ")]:[e._v("\n            "+e._s(n[a.prop])+"\n          ")]]}}])}),e._v(" "),o("yrt-editor",e._b({ref:e.editorRef,attrs:{"data-list-ref":e.dataListRef,"data-options":e.dataOptions,action:e.editorOptions.action,top:e.editorOptions.top,visible:e.editorOptions.config.visible,"auth-nodes":e.authNodes},on:{"update:action":function(t){return e.$set(e.editorOptions,"action",t)},"update:top":function(t){return e.$set(e.editorOptions,"top",t)},"update:visible":function(t){return e.$set(e.editorOptions.config,"visible",t)},"on-focus":e.onFocus,"on-change":e.onChange}},"yrt-editor",e.editorOptions,!1))],1)])],1)},[],!1,null,"3c0ae364",null));p.options.__file="user-tab.vue";var f=p.exports,h={name:"user-disabled-tab",custoJsonmRoute:"/sys/permission/user",components:{},mixins:[s.a],data:function(){var e=this;return{buttons:[{type:"button-group",label:"按钮组",buttons:[{type:"button",label:"解禁",options:{icon:"el-icon-yrt-shenpi3",type:"primary",authNode:"Enable"},key:"1544526690000_95807"},{type:"button",label:"删除",options:{icon:"el-icon-yrt-shanchu2",type:"primary",authNode:"delete"},key:"1544526694000_18473"}],options:{icon:"el-icon-yrt-anniuzu"},key:"1544526689000_39228"},{type:"button-group",label:"按钮组",buttons:[{type:"button",label:"刷新",options:{icon:"el-icon-yrt-shuaxin",type:"default",authNode:"refresh"},key:"1544526700000_1981"},{type:"button",label:"帮助",options:{icon:"el-icon-info",type:"default",authNode:"helper"},key:"1544526720000_74567"}],options:{icon:"el-icon-yrt-anniuzu"},key:"1544526698000_61679"}],actionField:{prop:"_action",label:"操作",width:"100",headerAlign:"center",align:"center",action:[{type:"button",action:"Enable",label:"解禁",onClick:function(t,o){return e.rowEnableUser(t,o),!0}},{type:"button",action:"delete",label:"删除"}],hidden:!1}}},created:function(){},methods:{buttonClick:function(e){switch(e){case"Enable":this.multiEnableUser()}},multiEnableUser:function(){var e=this;e.dataListSelections.length?this.$confirm("确定要批量进行解禁操作吗?","批量解禁",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var t={selectIDs:e.dataListSelections.map(function(e,t,o){return e.Receive_Id}).join(",")},o=e.$refs[e.$options.dataListRef];e.common.ajax("/api/Sys_User/enableUser",t,function(t){e.common.showMsg(t),t.result&&o.loadData()},o)}).catch(function(){e.$message({type:"info",message:"已取消"})}):this.$message.error("至少选择一行!")},rowEnableUser:function(e,t){var o=this;this.$confirm("确定要进行解禁操作吗?","解禁",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var e={openNodeApi:!0,user_Id:t.user_Id},n=o.findRef(o.dataListRef);o.common.ajax("/api/sys/user/enableUser",e,function(e){o.common.showMsg(e),e.result&&(n.loadData(),o.editorOptions.config.visible=!1)},n)}).catch(function(){o.$message({type:"info",message:"已取消"})})}}},m=Object(d.a)(h,function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"page-list-container"},[o("yrt-data-list",{ref:e.dataListRef,attrs:{"editor-ref":e.editorRef,"data-options":e.dataOptions,fields:e.dataListOptions.fields,buttons:e.buttons,"action-field":e.actionField,"button-click":e.buttonClick,"data-list-selections":e.dataListSelections,"auth-nodes":e.authNodes,"fixed-where":{enable:{operator:"raw",value:"(enable is null OR enable=0)"}}},on:{"update:fields":function(t){return e.$set(e.dataListOptions,"fields",t)},"update:dataListSelections":function(t){e.dataListSelections=t},"update:data-list-selections":function(t){e.dataListSelections=t}},scopedSlots:e._u([{key:"common-column-slot",fn:function(t){var n=t.row,a=t.col;return["enable"==a.prop?[1==n[a.prop]?[o("el-tag",{staticStyle:{color:"white",border:"0"},attrs:{color:"#7aaffe"}},[e._v("\n            "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop],a.dropdown_Id))+"\n          ")])]:[o("el-tag",{staticStyle:{color:"white",border:"0"},attrs:{color:"#ffcc33"}},[e._v("\n            "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop]||0,a.dropdown_Id))+"\n          ")])]]:"sex"==a.prop?[e._v("\n        "+e._s(e.$refs[e.dataListRef].translateText(a.prop,n[a.prop]||0,a.dropdown_Id))+"\n      ")]:[e._v("\n        "+e._s(n[a.prop])+"\n      ")]]}}])}),e._v(" "),o("yrt-editor",e._b({ref:e.editorRef,attrs:{"data-list-ref":e.dataListRef,"data-options":e.dataOptions,action:e.editorOptions.action,top:e.editorOptions.top,visible:e.editorOptions.config.visible,"auth-nodes":e.authNodes},on:{"update:action":function(t){return e.$set(e.editorOptions,"action",t)},"update:top":function(t){return e.$set(e.editorOptions,"top",t)},"update:visible":function(t){return e.$set(e.editorOptions.config,"visible",t)}}},"yrt-editor",e.editorOptions,!1))],1)},[],!1,null,null,null);m.options.__file="user-disabled-tab.vue";var b={name:"sys-permission-dept",components:{deptTab:c,userTab:f,userDisabledTab:m.exports},data:function(){return{currentTab:"dept"}}},v=(o("IfNc"),Object(d.a)(b,function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"page-list-container"},[o("el-tabs",{attrs:{type:"card"},model:{value:e.currentTab,callback:function(t){e.currentTab=t},expression:"currentTab"}},[o("el-tab-pane",{attrs:{label:"公司部门",name:"dept"}},[o("dept-tab")],1),e._v(" "),o("el-tab-pane",{attrs:{label:"公司成员",name:"user"}},[o("user-tab")],1),e._v(" "),o("el-tab-pane",{attrs:{label:"已禁账号",name:"fourth"}},[o("user-disabled-tab")],1)],1)],1)},[],!1,null,"1ff29568",null));v.options.__file="dept.vue";t.default=v.exports},ql3t:function(e,t,o){e.exports={default:o("h5AQ"),__esModule:!0}},yaWU:function(e,t,o){"use strict";o.d(t,"a",function(){return n});var n={bind:function(e,t,o){e.children[2].onscroll=function(t){var o=e.children[3];o&&o.classList.contains("el-table__footer-wrapper")&&(o.scrollLeft=t.target.scrollLeft)}},update:function(e,t,o){}}},ylC3:function(e,t,o){}}]);