2 lines
10 KiB
JavaScript
2 lines
10 KiB
JavaScript
webpackJsonp([5],{"5PT5":function(e,t){},"6WHa":function(e,t){},S5bR:function(e,t){},iGx0:function(e,t){},"p+yv":function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a("mvHQ"),s=a.n(r),i={data:function(){return{addForm:{welcome:"",senderServerAddress:"",senderFrom:"",senderUsername:"",senderPassword:"",recipientTo:"",recipientCC:"",recipientBC:"",subject:"",mainBody:"",copyRight:"",support:"",tel:"",sysVersion:"",isOpenAdvertise:"",defaultAdvertisement:""},addFormRules:{welcome:[{required:!1,message:"请输入系统简介",trigger:"blur"},{min:1,max:100,message:"长度在 1 到 100 个字符",trigger:"blur"}],senderServerAddress:[{required:!0,message:"请输入邮箱服务地址",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],senderFrom:[{required:!0,message:"请输入邮箱地址",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],senderUsername:[{required:!0,message:"请输入邮箱用户名",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],senderPassword:[{required:!0,message:"请输入邮箱密码",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],recipientTo:[{required:!0,message:"请输入接收人",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],recipientCC:[{required:!1,message:"请输入抄送人",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],recipientBC:[{required:!1,message:"请输入密送人",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],subject:[{required:!0,message:"请输入主题",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],mainBody:[{required:!0,message:"请输入正文",trigger:"blur"}],copyRight:[{required:!1,message:"请输入版权信息",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],support:[{required:!1,message:"请输入技术支持人员姓名",trigger:"blur"},{min:1,max:50,message:"长度在 1 到 50 个字符",trigger:"blur"}],tel:[{required:!1,message:"请输入技术支持人员电话",trigger:"blur"},{min:1,max:20,message:"长度在 1 到 20 个字符",trigger:"blur"}],sysVersion:[{required:!1,message:"请输入系统版本信息",trigger:"blur"},{min:1,max:20,message:"长度在 1 到 20 个字符",trigger:"blur"}],defaultAdvertisement:[{required:!1,message:"请输入默认公告信息",trigger:"blur"},{min:1,max:100,message:"长度在 0 到 100 个字符",trigger:"blur"}]},switchAdvertiseValue:"",isShowAdvertise:""}},methods:{switchOpenAdvertise:function(){this.isShowAdvertise=!this.isShowAdvertise},saveSystemParam:function(){var e=this;this.$refs.addFormRef.validate(function(t){t&&(e.addForm.updateTime=(new Date).getTime(),e.addForm.updatePerson=JSON.parse(localStorage.getItem("userInfo")).nick,e.addForm.id=1,e.switchAdvertiseValue?e.addForm.isOpenAdvertise=1:e.addForm.isOpenAdvertise=0,e.$api.system.updateSystemParam(s()(e.addForm)).then(function(t){e.$notify({type:"success",message:t.data.msg})}).catch(function(){}))})},getSystemParam:function(){var e=this;this.$api.system.querySysParamById(1).then(function(t){e.addForm=t.data.data,1==e.addForm.isOpenAdvertise?(e.switchAdvertiseValue=!0,e.isShowAdvertise=!0):(e.switchAdvertiseValue=!1,e.isShowAdvertise=!1),localStorage.setItem("systemParamInfo",s()(t.data.data))}).catch(function(){})}},created:function(){this.getSystemParam()}},n={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"system-param-box"},[a("el-form",{ref:"addFormRef",staticClass:"demo-form-inline",attrs:{inline:!0,model:e.addForm,rules:e.addFormRules,"label-width":"100px"}},[a("el-row",[a("el-col",{attrs:{span:24}},[a("el-form-item",{staticClass:"param-area-item",attrs:{label:"系统简介",prop:"welcome"}},[a("el-input",{attrs:{type:"textarea",placeholder:"请输入系统简介"},model:{value:e.addForm.welcome,callback:function(t){e.$set(e.addForm,"welcome",t)},expression:"addForm.welcome"}})],1)],1)],1),e._v(" "),e._e(),e._v(" "),a("el-row",{attrs:{gutter:10}},[a("el-col",{attrs:{span:6}},[a("div",{staticClass:"isSendEmail"},[a("span",{staticClass:"switch-span"},[e._v("开启公告")]),e._v(" "),a("el-switch",{attrs:{"active-color":"#13ce66","inactive-color":"#ff4949"},on:{change:e.switchOpenAdvertise},model:{value:e.switchAdvertiseValue,callback:function(t){e.switchAdvertiseValue=t},expression:"switchAdvertiseValue"}})],1)])],1),e._v(" "),a("br"),e._v(" "),e.isShowAdvertise?a("el-row",{attrs:{gutter:10}},[a("el-col",{attrs:{span:24}},[a("el-form-item",{staticClass:"param-area-item",attrs:{label:"默认公告",prop:"defaultAdvertisement"}},[a("el-input",{attrs:{type:"textarea",placeholder:"请输入默认公告信息"},model:{value:e.addForm.defaultAdvertisement,callback:function(t){e.$set(e.addForm,"defaultAdvertisement",t)},expression:"addForm.defaultAdvertisement"}})],1)],1)],1):e._e(),e._v(" "),a("br"),e._v(" "),a("el-row",{staticClass:"add_button",attrs:{type:"flex",justify:"center",align:"middle"}},[a("el-col",{attrs:{span:2}},[a("el-button",{attrs:{type:"primary"},on:{click:e.saveSystemParam}},[e._v("保 存")])],1)],1)],1)],1)},staticRenderFns:[]};var d={data:function(){return{addForm:{requestHeaders:"",isOpenDefaultRequestHeader:0},addFormRules:{requestHeaders:[{required:!0,message:"请输入请求头信息",trigger:"blur"}]},switchRequestHeaderValue:"",isShow:""}},mounted:function(){this.getSystemParam()},methods:{getSystemParam:function(){var e=JSON.parse(localStorage.getItem("systemParamInfo"));this.addForm.isOpenDefaultRequestHeader=e.isOpenDefaultRequestHeader,this.addForm.requestHeaders=e.requestHeaders,1==e.isOpenDefaultRequestHeader?(this.switchRequestHeaderValue=!0,this.isShow=!0):(this.switchRequestHeaderValue=!1,this.isShow=!1)},switchOpenRequest:function(){this.isShow=!this.isShow},saveInterfaceParam:function(){var e=this;this.$refs.addFormRef.validate(function(t){t&&(e.addForm.updateTime=(new Date).getTime(),e.addForm.updatePerson=JSON.parse(localStorage.getItem("userInfo")).nick,e.addForm.id=1,e.switchRequestHeaderValue?e.addForm.isOpenDefaultRequestHeader=1:e.addForm.isOpenDefaultRequestHeader=0,e.$api.system.updateInterfaceParam(s()(e.addForm)).then(function(t){e.$notify({type:"success",message:t.data.msg})}).catch(function(){}))})}}},m={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"interface-param-box"},[a("el-form",{ref:"addFormRef",staticClass:"demo-form-inline",attrs:{inline:!0,model:e.addForm,rules:e.addFormRules,"label-width":"100px"}},[a("el-row",{attrs:{gutter:10}},[a("el-col",{attrs:{span:4}},[a("div",{staticClass:"isOpenSwitch"},[a("span",{staticClass:"switch-span"},[e._v("开启请求头")]),e._v(" "),a("el-switch",{attrs:{"active-color":"#13ce66","inactive-color":"#ff4949"},on:{change:e.switchOpenRequest},model:{value:e.switchRequestHeaderValue,callback:function(t){e.switchRequestHeaderValue=t},expression:"switchRequestHeaderValue"}})],1)]),e._v(" "),a("el-col",{attrs:{span:20}},[e.isShow?a("div",{staticClass:"default-request"},[a("el-form-item",{staticClass:"param-area-item",attrs:{label:"默认请求头",prop:"requestHeaders"}},[a("el-input",{attrs:{type:"textarea",placeholder:"请输入请求头信息"},model:{value:e.addForm.requestHeaders,callback:function(t){e.$set(e.addForm,"requestHeaders",t)},expression:"addForm.requestHeaders"}})],1)],1):e._e()])],1),e._v(" "),a("br"),e._v(" "),a("el-row",{staticClass:"add_button",attrs:{type:"flex",justify:"center",align:"middle"}},[a("el-col",{attrs:{span:2}},[a("el-button",{attrs:{type:"primary"},on:{click:e.saveInterfaceParam}},[e._v("保 存")])],1)],1)],1)],1)},staticRenderFns:[]};var l={data:function(){return{addForm:{jmeterInstallPath:""},addFormRules:{jmeterInstallPath:[{required:!0,message:"请输入Jmeter安装路径",trigger:"blur"},{min:1,max:255,message:"长度在 1 到 255 个字符",trigger:"blur"}]}}},mounted:function(){this.addForm.jmeterInstallPath=JSON.parse(localStorage.getItem("systemParamInfo")).jmeterInstallPath},created:function(){},methods:{savePerformanceParam:function(){var e=this;this.$refs.addFormRef.validate(function(t){t&&(e.addForm.updateTime=(new Date).getTime(),e.addForm.updatePerson=JSON.parse(localStorage.getItem("userInfo")).nick,e.addForm.id=1,e.$api.system.updatePerformanceParam(s()(e.addForm)).then(function(t){e.$notify({type:"success",message:t.data.msg})}).catch(function(){}))})}}},o={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"interface-param-box"},[a("el-form",{ref:"addFormRef",staticClass:"demo-form-inline",attrs:{inline:!0,model:e.addForm,rules:e.addFormRules,"label-width":"100px"}},[a("el-row",[a("el-col",{attrs:{span:24}},[a("el-form-item",{staticClass:"param-area-item",attrs:{label:"Jmeter路径",prop:"jmeterInstallPath"}},[a("el-input",{attrs:{type:"textarea",placeholder:"请输入Jmeter安装路径"},model:{value:e.addForm.jmeterInstallPath,callback:function(t){e.$set(e.addForm,"jmeterInstallPath",t)},expression:"addForm.jmeterInstallPath"}})],1)],1)],1),e._v(" "),a("br"),e._v(" "),a("el-row",{staticClass:"add_button",attrs:{type:"flex",justify:"center",align:"middle"}},[a("el-col",{attrs:{span:2}},[a("el-button",{attrs:{type:"primary"},on:{click:e.savePerformanceParam}},[e._v("保 存")])],1)],1)],1)],1)},staticRenderFns:[]};var c={data:function(){return{activeName:"systemParam",load:{systemParam:!0,interfaceParam:!1,performanceParam:!1}}},mounted:function(){},created:function(){},methods:{handleClick:function(e,t){!1===this.load[e.name]&&(this.load[e.name]=!0)}},components:{SystemParam:a("VU/8")(i,n,!1,function(e){a("iGx0")},"data-v-1f6d35b0",null).exports,InterfaceParam:a("VU/8")(d,m,!1,function(e){a("S5bR")},"data-v-a60b5c78",null).exports,PerformanceParam:a("VU/8")(l,o,!1,function(e){a("5PT5")},"data-v-b1c2508c",null).exports}},u={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"param-box"},[a("el-tabs",{on:{"tab-click":e.handleClick},model:{value:e.activeName,callback:function(t){e.activeName=t},expression:"activeName"}},[a("el-tab-pane",{attrs:{label:"系统",name:"systemParam"}},[a("SystemParam")],1),e._v(" "),a("el-tab-pane",{attrs:{label:"接口",name:"interfaceParam"}},[e.load.interfaceParam?a("InterfaceParam"):e._e()],1),e._v(" "),a("el-tab-pane",{attrs:{label:"性能",name:"performanceParam"}},[e.load.performanceParam?a("PerformanceParam"):e._e()],1)],1)],1)},staticRenderFns:[]};var g=a("VU/8")(c,u,!1,function(e){a("6WHa")},"data-v-ca4737d4",null);t.default=g.exports}});
|
|
//# sourceMappingURL=5.09e09cf71cdb68375bbe.js.map
|