chunk-88d6c634.103adfd3.js 10 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-88d6c634","chunk-9de60898","chunk-2d0df437"],{"4f83":function(e,t,a){"use strict";a.r(t);var r=function(){var e=this,t=e._self._c;return t("a-card",{attrs:{bordered:!1}},[t("div",{staticClass:"table-page-search-wrapper"},[t("a-form",{attrs:{layout:"inline"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.searchQuery.apply(null,arguments)}}},[t("a-row",{attrs:{gutter:24}},[t("a-col",{attrs:{md:6,sm:8}},[t("a-form-item",{attrs:{label:"规则名称"}},[t("a-input",{attrs:{placeholder:"请输入规则名称"},model:{value:e.queryParam.ruleName,callback:function(t){e.$set(e.queryParam,"ruleName",t)},expression:"queryParam.ruleName"}})],1)],1),t("a-col",{attrs:{md:6,sm:8}},[t("a-form-item",{attrs:{label:"规则Code"}},[t("a-input",{attrs:{placeholder:"请输入规则Code"},model:{value:e.queryParam.ruleCode,callback:function(t){e.$set(e.queryParam,"ruleCode",t)},expression:"queryParam.ruleCode"}})],1)],1),t("a-col",{attrs:{md:6,sm:8}},[t("span",{staticClass:"table-page-search-submitButtons",staticStyle:{float:"left",overflow:"hidden"}},[t("a-button",{attrs:{type:"primary",icon:"search"},on:{click:e.searchQuery}},[e._v("查询")]),t("a-button",{staticStyle:{"margin-left":"8px"},attrs:{type:"primary",icon:"reload"},on:{click:e.searchReset}},[e._v("重置")])],1)])],1)],1)],1),t("div",{staticClass:"table-operator"},[t("a-button",{attrs:{type:"primary",icon:"plus"},on:{click:e.handleAdd}},[e._v("新增")]),t("a-button",{attrs:{type:"primary",icon:"download"},on:{click:function(t){return e.handleExportXls("填值规则")}}},[e._v("导出")]),t("a-upload",{attrs:{name:"file",showUploadList:!1,multiple:!1,headers:e.tokenHeader,action:e.importExcelUrl},on:{change:e.handleImportExcel}},[t("a-button",{attrs:{type:"primary",icon:"import"}},[e._v("导入")])],1),e.selectedRowKeys.length>0?t("a-dropdown",[t("a-menu",{attrs:{slot:"overlay"},slot:"overlay"},[t("a-menu-item",{key:"1",on:{click:e.batchDel}},[t("a-icon",{attrs:{type:"delete"}}),e._v("\n 删除\n ")],1)],1),t("a-button",{staticStyle:{"margin-left":"8px"}},[e._v(" 批量操作\n "),t("a-icon",{attrs:{type:"down"}})],1)],1):e._e()],1),t("a-alert",{staticStyle:{"margin-bottom":"16px"},attrs:{type:"info",showIcon:""}},[t("template",{slot:"message"},[t("span",[e._v("已选择")]),t("a",{staticStyle:{"font-weight":"600",padding:"0 4px"}},[e._v(e._s(e.selectedRowKeys.length))]),t("span",[e._v("项")]),e.selectedRowKeys.length>0?[t("a-divider",{attrs:{type:"vertical"}}),t("a",{on:{click:e.onClearSelected}},[e._v("清空")])]:e._e()],2)],2),t("a-table",{ref:"table",attrs:{size:"middle",bordered:"",rowKey:"id",columns:e.columns,dataSource:e.dataSource,pagination:e.ipagination,loading:e.loading,rowSelection:{selectedRowKeys:e.selectedRowKeys,onChange:e.onSelectChange}},on:{change:e.handleTableChange},scopedSlots:e._u([{key:"action",fn:function(a,r){return t("span",{},[t("a",{on:{click:function(t){return e.handleEdit(r)}}},[e._v("编辑")]),t("a-divider",{attrs:{type:"vertical"}}),t("a-dropdown",[t("a",{staticClass:"ant-dropdown-link"},[e._v("更多 "),t("a-icon",{attrs:{type:"down"}})],1),t("a-menu",{attrs:{slot:"overlay"},slot:"overlay"},[t("a-menu-item",{on:{click:function(t){return e.handleTest(r)}}},[e._v("\n 功能测试\n ")]),t("a-menu-item",[t("a-popconfirm",{attrs:{title:"确定删除吗?"},on:{confirm:function(){return e.handleDelete(r.id)}}},[t("a",[e._v("删除")])])],1)],1)],1)],1)}}])}),t("sys-fill-rule-modal",{ref:"modalForm",on:{ok:e.modalFormOk}})],1)},l=[],n=a("0fea"),o=a("6b7a"),i=a("b65a"),s={name:"SysFillRuleList",mixins:[i["a"]],components:{SysFillRuleModal:o["default"]},data:function(){return{description:"填值规则管理页面",columns:[{title:"#",dataIndex:"",key:"rowIndex",width:60,align:"center",customRender:function(e,t,a){return 1+a}},{title:"规则名称",align:"center",dataIndex:"ruleName"},{title:"规则Code",align:"center",dataIndex:"ruleCode"},{title:"规则实现类",align:"center",dataIndex:"ruleClass"},{title:"规则参数",align:"center",dataIndex:"ruleParams"},{title:"操作",dataIndex:"action",align:"center",scopedSlots:{customRender:"action"}}],url:{list:"/sys/fillRule/list",test:"/sys/fillRule/testFillRule",delete:"/sys/fillRule/delete",deleteBatch:"/sys/fillRule/deleteBatch",exportXlsUrl:"/sys/fillRule/exportXls",importExcelUrl:"/sys/fillRule/importExcel"}}},computed:{importExcelUrl:function(){return"".concat(window._CONFIG["domianURL"]).concat(this.url.importExcelUrl)}},methods:{handleTest:function(e){var t=this,a=this.$message.loading("生成中...",0);Object(n["c"])(this.url.test,{ruleCode:e.ruleCode}).then((function(e){e.success?t.$info({title:"填值规则功能测试",content:"生成结果:"+e.result}):t.$message.warn(e.message)})).finally((function(){a()}))}}},c=s,u=(a("a549"),a("2877")),d=Object(u["a"])(c,r,l,!1,null,"12906cca",null);t["default"]=d.exports},"6b7a":function(e,t,a){"use strict";a.r(t);var r=function(){var e=this,t=e._self._c;return t("a-modal",{attrs:{title:e.title,width:800,visible:e.visible,maskClosable:!1,confirmLoading:e.confirmLoading,cancelText:"关闭"},on:{ok:e.handleOk,cancel:e.handleCancel}},[t("a-spin",{attrs:{spinning:e.confirmLoading}},[t("a-form",{attrs:{form:e.form}},[t("a-form-item",{attrs:{labelCol:e.labelCol,wrapperCol:e.wrapperCol,label:"规则名称"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["ruleName",e.validatorRules.ruleName],expression:"['ruleName', validatorRules.ruleName]"}],attrs:{placeholder:"请输入规则名称"}})],1),t("a-form-item",{attrs:{labelCol:e.labelCol,wrapperCol:e.wrapperCol,label:"规则Code"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["ruleCode",e.validatorRules.ruleCode],expression:"['ruleCode', validatorRules.ruleCode]"}],attrs:{placeholder:"请输入规则Code",disabled:e.disabledCode}})],1),t("a-form-item",{attrs:{labelCol:e.labelCol,wrapperCol:e.wrapperCol,label:"规则实现类"}},[t("a-input",{directives:[{name:"decorator",rawName:"v-decorator",value:["ruleClass",e.validatorRules.ruleClass],expression:"['ruleClass', validatorRules.ruleClass]"}],attrs:{placeholder:"请输入规则实现类"}})],1),t("a-form-item",{attrs:{labelCol:e.labelCol,wrapperCol:e.wrapperCol,label:"规则参数"}},[t("a-textarea",{directives:[{name:"decorator",rawName:"v-decorator",value:["ruleParams",e.validatorRules.ruleParams],expression:"['ruleParams', validatorRules.ruleParams]"}],attrs:{placeholder:"请输入规则参数",rows:5}})],1)],1)],1)],1)},l=[],n=a("88bc"),o=a.n(n),i=a("0fea"),s=a("ca00"),c={name:"SysFillRuleModal",components:{},data:function(){var e=this;return{title:"操作",visible:!1,model:{},labelCol:{xs:{span:24},sm:{span:5}},wrapperCol:{xs:{span:24},sm:{span:16}},confirmLoading:!1,form:this.$form.createForm(this),validatorRules:{ruleName:{rules:[{required:!0,message:"规则名称不能为空"}]},ruleCode:{rules:[{required:!0,message:"规则Code不能为空"},{validator:function(t,a,r){return Object(s["m"])("sys_fill_rule","rule_code",a,e.model.id,r)}}]},ruleClass:{rules:[{required:!0,message:"规则实现类不能为空"}]},ruleParams:{rules:[{validator:function(e,t,a){try{var r=JSON.parse(t);r instanceof Array?a("只能传递JSON对象,不能传递JSON数组"):r instanceof Object?a():a("请输入JSON字符串")}catch(l){a("请输入JSON字符串")}}}]}},url:{add:"/sys/fillRule/add",edit:"/sys/fillRule/edit"}}},computed:{disabledCode:function(){return!!this.model.id}},created:function(){},methods:{add:function(){this.edit({})},edit:function(e){var t=this;this.form.resetFields(),this.model=Object.assign({},e),this.visible=!0,this.$nextTick((function(){t.form.setFieldsValue(o()(t.model,"ruleName","ruleCode","ruleClass","ruleParams"))}))},close:function(){this.$emit("close"),this.visible=!1},handleOk:function(){var e=this,t=this;this.form.validateFields((function(a,r){if(!a){t.confirmLoading=!0;var l=e.url.add,n="post";e.model.id&&(l=e.url.edit,n="put");var o=Object.assign(e.model,r);Object(i["i"])(l,o,n).then((function(e){e.success?(t.$message.success(e.message),t.$emit("ok")):t.$message.warning(e.message)})).finally((function(){t.confirmLoading=!1,t.close()}))}}))},handleCancel:function(){this.close()}}},u=c,d=a("2877"),m=Object(d["a"])(u,r,l,!1,null,"23874808",null);t["default"]=m.exports},7976:function(e,t,a){},"88bc":function(e,t,a){(function(t){var a=1/0,r=9007199254740991,l="[object Arguments]",n="[object Function]",o="[object GeneratorFunction]",i="[object Symbol]",s="object"==typeof t&&t&&t.Object===Object&&t,c="object"==typeof self&&self&&self.Object===Object&&self,u=s||c||Function("return this")();function d(e,t,a){switch(a.length){case 0:return e.call(t);case 1:return e.call(t,a[0]);case 2:return e.call(t,a[0],a[1]);case 3:return e.call(t,a[0],a[1],a[2])}return e.apply(t,a)}function m(e,t){var a=-1,r=e?e.length:0,l=Array(r);while(++a<r)l[a]=t(e[a],a,e);return l}function p(e,t){var a=-1,r=t.length,l=e.length;while(++a<r)e[l+a]=t[a];return e}var f=Object.prototype,h=f.hasOwnProperty,v=f.toString,y=u.Symbol,b=f.propertyIsEnumerable,g=y?y.isConcatSpreadable:void 0,C=Math.max;function w(e,t,a,r,l){var n=-1,o=e.length;a||(a=_),l||(l=[]);while(++n<o){var i=e[n];t>0&&a(i)?t>1?w(i,t-1,a,r,l):p(l,i):r||(l[l.length]=i)}return l}function x(e,t){return e=Object(e),k(e,t,(function(t,a){return a in e}))}function k(e,t,a){var r=-1,l=t.length,n={};while(++r<l){var o=t[r],i=e[o];a(i,o)&&(n[o]=i)}return n}function R(e,t){return t=C(void 0===t?e.length-1:t,0),function(){var a=arguments,r=-1,l=C(a.length-t,0),n=Array(l);while(++r<l)n[r]=a[t+r];r=-1;var o=Array(t+1);while(++r<t)o[r]=a[r];return o[t]=n,d(e,this,o)}}function _(e){return j(e)||S(e)||!!(g&&e&&e[g])}function O(e){if("string"==typeof e||q(e))return e;var t=e+"";return"0"==t&&1/e==-a?"-0":t}function S(e){return F(e)&&h.call(e,"callee")&&(!b.call(e,"callee")||v.call(e)==l)}var j=Array.isArray;function N(e){return null!=e&&I(e.length)&&!P(e)}function F(e){return E(e)&&N(e)}function P(e){var t=$(e)?v.call(e):"";return t==n||t==o}function I(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function $(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function E(e){return!!e&&"object"==typeof e}function q(e){return"symbol"==typeof e||E(e)&&v.call(e)==i}var L=R((function(e,t){return null==e?{}:x(e,m(w(t,1),O))}));e.exports=L}).call(this,a("c8ba"))},a549:function(e,t,a){"use strict";a("7976")}}]);