chunk-2d2217b6.5164ecde.js 2.8 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d2217b6"],{cb12:function(e,t,n){"use strict";n.r(t),n.d(t,"crudOptions",(function(){return o}));n("99af"),n("d3b7");var a=n("9668"),o=function(e){return{pageOptions:{compact:!0},options:{tableType:"vxe-table",stripe:!1,rowKey:!0,rowId:"id",height:"100%",highlightCurrentRow:!1,defaultExpandAll:!0,treeConfig:{lazy:!0,hasChild:"has_children",loadMethod:function(e){var t=e.row;return a["GetList"]({parent:t.id,lazy:!0}).then((function(e){return e.data.data}))},iconLoaded:"el-icon-loading"}},rowHandle:{width:140,view:{thin:!0,text:"",disabled:function(){return!e.hasPermissions("Retrieve")}},edit:{thin:!0,text:"",disabled:function(){return!e.hasPermissions("Update")}},remove:{thin:!0,text:"",disabled:function(){return!e.hasPermissions("Delete")}}},indexRow:{title:"序号",align:"center",width:100},viewOptions:{componentType:"form"},formOptions:{defaultSpan:12},columns:[{title:"关键词",key:"search",show:!1,disabled:!0,search:{disabled:!1},form:{disabled:!0,component:{props:{clearable:!0},placeholder:"请输入关键词"}},view:{disabled:!0}},{title:"ID",key:"id",show:!1,disabled:!0,width:90,form:{disabled:!0}},{show:!1,title:"上级部门",key:"parent",type:"tree-selector",dict:{isTree:!0,label:"name",value:"id",cache:!1,getData:function(e,t,n){n.form,n.component;return a["DeptLazy"]().then((function(e){return e.data}))},getNodes:function(t,n){return new Promise((function(t,n){var a=e.getEditRow();t(null!==a.parent?[{name:a.parent_name,id:a.parent}]:[])}))}},form:{helper:"默认留空为根节点",component:{span:12,props:{multiple:!1,elProps:{lazy:!0,hasChild:"has_children",load:function(e,t){a["DeptLazy"]({parent:e.data.id}).then((function(e){t(e.data)}))}}}}}},{title:"部门名称",key:"name",sortable:!0,treeNode:!0,search:{disabled:!1,component:{props:{clearable:!0}}},width:180,type:"input",form:{rules:[{required:!0,message:"部门名称必填项"}],component:{span:12,props:{clearable:!0},placeholder:"请输入部门名称"},itemProps:{class:{yxtInput:!0}}}},{title:"负责人",key:"owner",sortable:!0,form:{component:{span:12,props:{clearable:!0},placeholder:"请输入负责人"}}},{title:"联系电话",key:"phone",sortable:!0,form:{component:{span:12,props:{clearable:!0},placeholder:"请输入联系电话"}}},{title:"邮箱",key:"email",sortable:!0,form:{component:{span:12,props:{clearable:!0},placeholder:"请输入邮箱"},rules:[{type:"email",message:"请输入正确的邮箱地址",trigger:["blur","change"]}]}},{title:"排序",key:"sort",sortable:!0,width:80,type:"number",form:{value:1,component:{span:12,placeholder:"请选择序号"}}},{title:"状态",key:"status",sortable:!0,search:{disabled:!1},width:90,type:"radio",dict:{data:e.dictionary("button_status_bool")},form:{value:!0,component:{span:12,placeholder:"请选择状态"}}}].concat(e.commonEndColumns())}}}}]);