1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-459274f3"],{7424:function(t,e,i){"use strict";i.r(e);var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"app-container"},[i("el-tabs",{on:{"tab-click":t.handleClick},model:{value:t.activeName,callback:function(e){t.activeName=e},expression:"activeName"}},[i("el-tab-pane",{attrs:{label:"微信H5支付设置",name:"first"}},[i("el-form",{ref:"h5DataForm",attrs:{model:t.h5SettingForm,rules:t.h5Rules}},[i("el-form-item",{attrs:{label:"公众号appId:",prop:"settingAppid"}},[i("el-col",{attrs:{span:6}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingAppid,callback:function(e){t.$set(t.h5SettingForm,"settingAppid",e)},expression:"h5SettingForm.settingAppid"}})],1)],1),i("el-form-item",{attrs:{label:"H5支付支付商户号:",prop:"settingMchId"}},[[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingMchId,callback:function(e){t.$set(t.h5SettingForm,"settingMchId",e)},expression:"h5SettingForm.settingMchId"}})],1)]],2),i("el-form-item",{attrs:{label:"H5支付商户密钥key:",prop:"settingKey"}},[[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingKey,callback:function(e){t.$set(t.h5SettingForm,"settingKey",e)},expression:"h5SettingForm.settingKey"}})],1)]],2),i("el-form-item",{attrs:{label:"H5支付回调地址notifyUrl:",prop:"settingNotifyUrl"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingNotifyUrl,callback:function(e){t.$set(t.h5SettingForm,"settingNotifyUrl",e)},expression:"h5SettingForm.settingNotifyUrl"}})],1)],1),i("el-form-item",{attrs:{label:"H5支付成功地址redirectUrl:",prop:"settingRedirectUrl"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingRedirectUrl,callback:function(e){t.$set(t.h5SettingForm,"settingRedirectUrl",e)},expression:"h5SettingForm.settingRedirectUrl"}})],1)],1),i("el-form-item",{attrs:{label:"H5支付方式tradeType:",prop:"settingTradeType"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingTradeType,callback:function(e){t.$set(t.h5SettingForm,"settingTradeType",e)},expression:"h5SettingForm.settingTradeType"}})],1)],1),i("el-form-item",{attrs:{label:"H5签名方式sighType:",prop:"settingSighType"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.h5SettingForm.settingSighType,callback:function(e){t.$set(t.h5SettingForm,"settingSighType",e)},expression:"h5SettingForm.settingSighType"}})],1),i("span",[t._v("注: 默认为MD5签名")])],1),i("el-button",{staticClass:"filter-item",attrs:{type:"primary",icon:"el-icon-edit"},on:{click:t.h5Setting}},[t._v("提交")])],1)],1),i("el-tab-pane",{attrs:{label:"微信小程序设置",name:"second"}},[i("el-form",{ref:"smallAppDataForm",attrs:{model:t.smallAppSettingForm,rules:t.smallAppRules}},[i("el-form-item",{attrs:{label:"小程序appId:",prop:"settingAppid"}},[i("el-col",{attrs:{span:6}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingAppid,callback:function(e){t.$set(t.smallAppSettingForm,"settingAppid",e)},expression:"smallAppSettingForm.settingAppid"}})],1)],1),i("el-form-item",{attrs:{label:"小程序appSecret:",prop:"settingAppSecret"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingAppSecret,callback:function(e){t.$set(t.smallAppSettingForm,"settingAppSecret",e)},expression:"smallAppSettingForm.settingAppSecret"}})],1)],1),i("el-form-item",{attrs:{label:"小程序支付支付商户号:",prop:"settingMchId"}},[[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingMchId,callback:function(e){t.$set(t.smallAppSettingForm,"settingMchId",e)},expression:"smallAppSettingForm.settingMchId"}})],1)]],2),i("el-form-item",{attrs:{label:"小程序支付商户密钥key:",prop:"settingKey"}},[[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingKey,callback:function(e){t.$set(t.smallAppSettingForm,"settingKey",e)},expression:"smallAppSettingForm.settingKey"}})],1)]],2),i("el-form-item",{attrs:{label:"微信小程序回调地址notifyUrl:",prop:"settingNotifyUrl"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingNotifyUrl,callback:function(e){t.$set(t.smallAppSettingForm,"settingNotifyUrl",e)},expression:"smallAppSettingForm.settingNotifyUrl"}})],1)],1),i("el-form-item",{attrs:{label:"微信小程序支付方式tradeType:",prop:"settingTradeType"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingTradeType,callback:function(e){t.$set(t.smallAppSettingForm,"settingTradeType",e)},expression:"smallAppSettingForm.settingTradeType"}})],1)],1),i("el-form-item",{attrs:{label:"微信小程序支付签名方式sighType:",prop:"settingSighType"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.smallAppSettingForm.settingSighType,callback:function(e){t.$set(t.smallAppSettingForm,"settingSighType",e)},expression:"smallAppSettingForm.settingSighType"}})],1),i("span",[t._v("注: 默认为MD5签名")])],1),i("el-button",{staticClass:"filter-item",attrs:{type:"primary",icon:"el-icon-edit"},on:{click:t.mallAppSetting}},[t._v("提交")])],1)],1),i("el-tab-pane",{attrs:{label:"七牛云设置",name:"third"}},[i("el-form",{ref:"qiniuDataForm",attrs:{model:t.qiniuSettingForm,rules:t.qiniuAppRules}},[i("el-form-item",{attrs:{label:"七牛云accessKey:",prop:"settingAccessKey"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.qiniuSettingForm.settingAccessKey,callback:function(e){t.$set(t.qiniuSettingForm,"settingAccessKey",e)},expression:"qiniuSettingForm.settingAccessKey"}})],1)],1),i("el-form-item",{attrs:{label:"七牛云secretKey:",prop:"settingSecretKey"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.qiniuSettingForm.settingSecretKey,callback:function(e){t.$set(t.qiniuSettingForm,"settingSecretKey",e)},expression:"qiniuSettingForm.settingSecretKey"}})],1)],1),i("el-form-item",{attrs:{label:"七牛云bucket: ",prop:"settingBucket"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.qiniuSettingForm.settingBucket,callback:function(e){t.$set(t.qiniuSettingForm,"settingBucket",e)},expression:"qiniuSettingForm.settingBucket"}})],1)],1),i("el-form-item",{attrs:{label:"七牛云服务器区域地址: ",prop:"settingUploadQiniuUrl"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.qiniuSettingForm.settingUploadQiniuUrl,callback:function(e){t.$set(t.qiniuSettingForm,"settingUploadQiniuUrl",e)},expression:"qiniuSettingForm.settingUploadQiniuUrl"}})],1)],1),i("el-form-item",{attrs:{label:"上传成功前缀域名: ",prop:"settingUploadQiniuAddr"}},[i("el-col",{attrs:{span:4}},[i("el-input",{staticStyle:{width:"200px"},attrs:{autocomplete:"off"},model:{value:t.qiniuSettingForm.settingUploadQiniuAddr,callback:function(e){t.$set(t.qiniuSettingForm,"settingUploadQiniuAddr",e)},expression:"qiniuSettingForm.settingUploadQiniuAddr"}})],1)],1),i("el-button",{staticClass:"filter-item",attrs:{type:"primary",icon:"el-icon-edit"},on:{click:t.qiniuSetting}},[t._v("提交")])],1)],1),t.isManage?i("el-tab-pane",{attrs:{label:"系统设置",name:"forth"}},[i("el-form",[i("el-button",{staticClass:"filter-item",attrs:{type:"primary",icon:"el-icon-edit"},on:{click:t.systemSetting}},[t._v("提交")])],1)],1):t._e()],1)],1)},r=[],s=(i("5ab2"),i("6d57"),i("e10e"),i("88d6")),l=i("52c1"),a=i("90e7");i("bc3a");function o(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,n)}return i}function p(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?o(Object(i),!0).forEach((function(e){Object(s["a"])(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):o(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var g={data:function(){return{activeName:"first",form:{},h5SettingForm:{},isAddH5Setting:!1,isAddSmallAppSetting:!1,isAddQiniuSetting:!1,smallAppSettingForm:{},qiniuSettingForm:{},systemSettingForm:{},isManage:!1,h5Rules:{settingAppid:[{required:!0,message:"H5 APPid不能为空",trigger:"blur"}],settingMchId:[{required:!0,message:"H5 MchId不能为空",trigger:"blur"}],settingKey:[{required:!0,message:"H5 Key不能为空",trigger:"blur"}],settingNotifyUrl:[{required:!0,message:"H5 回调地址NotifyUrl不能为空",trigger:"blur"}],settingRedirectUrl:[{required:!0,message:"H5 支付后重定向地址RedirectUrl不能为空",trigger:"blur"}],settingTradeType:[{required:!0,message:"H5 支付支付方式TradeType不能为空",trigger:"blur"}],settingSighType:[{required:!0,message:"H5 支付签名方式SighType不能为空",trigger:"blur"}]},smallAppRules:{settingAppid:[{required:!0,message:"微信小程序 Appid不能为空",trigger:"blur"}],settingAppSecret:[{required:!0,message:"微信小程序 AppSecret不能为空",trigger:"blur"}],settingMchId:[{required:!0,message:"微信小程序 MchId不能为空",trigger:"blur"}],settingKey:[{required:!0,message:"微信小程序 Key不能为空",trigger:"blur"}],settingNotifyUrl:[{required:!0,message:"微信小程序 支付回调地址NotifyUrl不能为空",trigger:"blur"}],settingTradeType:[{required:!0,message:"微信小程序 支付方式TradeType不能为空",trigger:"blur"}],settingSighType:[{required:!0,message:"微信小程序 加密类型TradeType不能为空",trigger:"blur"}]},qiniuAppRules:{settingAccessKey:[{required:!0,message:"七牛云 AccessKey不能为空",trigger:"blur"}],settingSecretKey:[{required:!0,message:"七牛云 SecretKey不能为空",trigger:"blur"}],settingBucket:[{required:!0,message:"七牛云 Bucket不能为空",trigger:"blur"}],settingUploadQiniuUrl:[{required:!0,message:"七牛云 服务器存储区域地址不能为空",trigger:"blur"}],settingUploadQiniuAddr:[{required:!0,message:"七牛云 存储空间域名地址不能为空",trigger:"blur"}]}}},computed:p({},Object(l["b"])(["userInfo"])),created:function(){9===this.userInfo.userType&&(this.isManage=!0),this.getH5SettingList(),this.getSmallAppSettingList(),this.getQiniuSettingList()},methods:{handleClick:function(t,e){},getH5SettingList:function(){var t=this;this.h5SettingForm.orgId=this.userInfo.orgId,this.h5SettingForm.settingType=1,Object(a["b"])(this.h5SettingForm).then((function(e){console.log(e),0===e.data.length?t.isAddH5Setting=!0:t.h5SettingForm=e.data[0]}))},getSmallAppSettingList:function(){var t=this;this.smallAppSettingForm.orgId=this.userInfo.orgId,this.smallAppSettingForm.settingType=2,Object(a["b"])(this.smallAppSettingForm).then((function(e){0===e.data.length?t.isAddSmallAppSetting=!0:t.smallAppSettingForm=e.data[0]}))},getQiniuSettingList:function(){var t=this;this.qiniuSettingForm.orgId=this.userInfo.orgId,this.qiniuSettingForm.settingType=3,Object(a["b"])(this.qiniuSettingForm).then((function(e){0===e.data.length?t.isAddQiniuSetting=!0:t.qiniuSettingForm=e.data[0]}))},h5Setting:function(){var t=this;this.$refs["h5DataForm"].validate((function(e){e&&(t.isAddH5Setting?Object(a["a"])(t.h5SettingForm).then((function(e){t.$notify({title:"微信H5设置添加",message:e.msg,type:200===e.status?"success":"error",duration:2e3}),window.location.reload()})):(console.log("存在数据,进行修改"),Object(a["c"])(t.h5SettingForm).then((function(e){t.$notify({title:"微信H5设置更新",message:e.msg,type:200===e.status?"success":"error",duration:2e3}),window.location.reload()}))))}))},mallAppSetting:function(){var t=this;this.$refs["smallAppDataForm"].validate((function(e){e&&(t.isAddSmallAppSetting?Object(a["a"])(t.smallAppSettingForm).then((function(e){t.$notify({title:"微信小程序设置添加",message:e.msg,type:200===e.status?"success":"error",duration:2e3}),window.location.reload()})):Object(a["c"])(t.smallAppSettingForm).then((function(e){t.$notify({title:"微信小程序设置更新",message:e.msg,type:200===e.status?"success":"error",duration:2e3}),window.location.reload()})))}))},qiniuSetting:function(){var t=this;this.$refs["qiniuDataForm"].validate((function(e){e&&(t.isAddQiniuSetting?Object(a["a"])(t.qiniuSettingForm).then((function(e){t.$notify({title:"七牛云设置添加",message:e.msg,type:200===e.status?"success":"error",duration:2e3}),window.location.reload()})):Object(a["c"])(t.qiniuSettingForm).then((function(e){t.$notify({title:"七牛云设置更新",message:e.msg,type:200===e.status?"success":"error",duration:2e3})})))}))},systemSetting:function(){}}},c=g,m=i("4023"),u=Object(m["a"])(c,n,r,!1,null,null,null);e["default"]=u.exports},"90e7":function(t,e,i){"use strict";i.d(e,"a",(function(){return r})),i.d(e,"c",(function(){return s})),i.d(e,"b",(function(){return l}));var n=i("b775");function r(t){return Object(n["a"])({url:"/setting/addSetting",method:"post",data:t})}function s(t){return Object(n["a"])({url:"/setting/updateSetting",method:"put",data:t})}function l(t){return Object(n["a"])({url:"/setting/getSettingList",method:"post",data:t})}}}]);
|