{"version":3,"sources":["webpack:///./src/webapp/system-set/data_access/content_access/index.vue?a680","webpack:///./src/webapp/system-set/data_access/content_access/index.vue?2b63","webpack:///./src/webapp/system-set/data_access/content_access/apis.js","webpack:///src/webapp/system-set/data_access/content_access/index.vue","webpack:///./src/webapp/system-set/data_access/content_access/index.vue?f3c0","webpack:///./src/webapp/system-set/data_access/content_access/index.vue","webpack:///./src/webapp/system-set/data_access/content_access/index.vue?4561","webpack:///./src/apis/regExp.js","webpack:///./src/apis/index.js"],"names":["render","_vm","this","_h","$createElement","_c","_self","directives","name","rawName","staticClass","attrs","canAccessEjw","on","openEjw","_v","canAccessThird","openThird","_b","ref","search","table","dialogVisible","handleClose","$event","form","_e","slot","submit","staticRenderFns","mpsCustomerId","window","sessionStorage","getItem","JSON","parse","partnerId","Api","getAccessData","params","cb","err","$http","get","path","apiMps","then","res","error","deleteAccessData","delete","id","postImportData","post","getEnv","postThirdContent","data","cols","label","minWidth","prop","fuc","row","type","value","domain","auth_url","width","h","canDelete","account","click","deleteAccess","permission","form_type","openThirdUrl","bind","props","labelWidth","rules","auto","form_name","required","max","tag","placeholder","userInfo","$tools","auth","getCurrentUserInfo","mpsCustomerOrang","envUrl","mounted","$apis","Server","$axios","$message","warning","$route","query","site_type","initAccessData","$refs","env_name","methods","close","open","encodeURIComponent","location","origin","organName","$validate","valid","$getValue","success","filters","$confirm","confirmButtonText","cancelButtonText","message","catch","test","username","data_url","token","decodeURIComponent","form_id","login_url","content_status","component","email","apiCrmOS","apiCrmUs","constructor","http","axios","allError","global","isadd","response","headers","resData","msg","errors","map","item","join","obj","o","Array","forEach","push","clearAllNull","Object","assign","key","String","trim","regExp","self","stack"],"mappings":"wIAAA,W,2CCAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,WAAW,CAAC,CAACC,KAAK,aAAaC,QAAQ,iBAAiBC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OH,EAASnF,KAAK+D,SAAYoB,EAASnF,KAAKuF,QAAUJ,EAASnF,KAAKuF,OAAOC,KAAI,SAAUC,GAChJ,OAAOA,EAAK1B,WACX2B,KAAK,OAAW,gBAQ3BpD,EAAOlD,KAAOA,EACCkD","file":"js/systemSet_data_access_content_access.fdc8b518.js","sourcesContent":["export * from \"-!../../../../../node_modules/@vue/cli-service/node_modules/mini-css-extract-plugin/dist/loader.js??ref--10-oneOf-1-0!../../../../../node_modules/css-loader/dist/cjs.js??ref--10-oneOf-1-1!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-2!../../../../../node_modules/less-loader/dist/cjs.js??ref--10-oneOf-1-3!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=style&index=1&id=53e209a6&prod&lang=less\"","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:\"judgeRight\",rawName:\"v-judgeRight\"}],staticClass:\"data-access\"},[_c('div',{staticClass:\"data-access-operate\"},[_c('el-button',{attrs:{\"type\":\"primary\",\"disabled\":!_vm.canAccessEjw},on:{\"click\":_vm.openEjw}},[_vm._v(\"接入竞网建站平台\")]),_c('el-button',{attrs:{\"disabled\":!_vm.canAccessThird,\"type\":\"primary\"},on:{\"click\":_vm.openThird}},[_vm._v(\"第三方接入配置\")])],1),_c('jw-table',_vm._b({ref:\"table\",on:{\"search\":_vm.search}},'jw-table',_vm.table,false)),_c('el-dialog',{attrs:{\"title\":\"第三方接入配置\",\"visible\":_vm.dialogVisible,\"width\":\"600px\",\"custom-class\":\"data-access-dialog\",\"close-on-click-modal\":false,\"before-close\":_vm.handleClose},on:{\"update:visible\":function($event){_vm.dialogVisible=$event}}},[(_vm.dialogVisible)?_c('jw-form',_vm._b({ref:\"form\"},'jw-form',_vm.form,false)):_vm._e(),_c('span',{staticClass:\"dialog-footer\",attrs:{\"slot\":\"footer\"},slot:\"footer\"},[_c('el-button',{on:{\"click\":function($event){_vm.dialogVisible = false}}},[_vm._v(\"取 消\")]),_c('el-button',{attrs:{\"type\":\"primary\"},on:{\"click\":_vm.submit}},[_vm._v(\"保 存\")])],1)],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import Api from '@/apis/index.js'\nconst mpsCustomerId = window.sessionStorage.getItem('mps_customer_orang') && JSON.parse(window.sessionStorage.getItem('mps_customer_orang')).partnerId\nexport default class extends Api {\n // 050\n getAccessData (params, cb, err) {\n this.$http.get(`${Api.path.apiMps}${mpsCustomerId ? `/agent/${params.partnerId}` : ''}/partner/${mpsCustomerId || params.partnerId}/formauth`).then((res) => {\n cb(res)\n }, this.error(err))\n }\n deleteAccessData (params, cb, err) {\n this.$http.delete(`${Api.path.apiMps}${mpsCustomerId ? `/agent/${params.partnerId}` : ''}/partner/${mpsCustomerId || params.partnerId}/formauth/${params.id}`).then(res => {\n cb(res)\n }, this.error(err))\n }\n postImportData (params, path, cb, err) {\n this.$http.post(`${Api.path.apiMps}${mpsCustomerId ? `/agent/${path.partnerId}` : ''}/partner/${mpsCustomerId || path.partnerId}/formauth`, params).then(res => {\n cb(res)\n }, this.error(err))\n }\n getEnv (params, cb, err) {\n this.$http.get(`${Api.path.apiMps}/env`, { params }).then(res => {\n cb(res)\n }, this.error(err))\n }\n postThirdContent (params, path, cb, err) {\n this.$http.post(`${Api.path.apiMps}${mpsCustomerId ? `/agent/${path.partnerId}` : ''}/partner/${mpsCustomerId || path.partnerId}/formauth/third-party-access`, params).then(res => {\n cb(res)\n }, this.error(err))\n }\n}\n","\n\n\n\n","import mod from \"-!../../../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=53e209a6&scoped=true\"\nimport script from \"./index.vue?vue&type=script&lang=js\"\nexport * from \"./index.vue?vue&type=script&lang=js\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=53e209a6&prod&lang=less&scoped=true\"\nimport style1 from \"./index.vue?vue&type=style&index=1&id=53e209a6&prod&lang=less\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"53e209a6\",\n null\n \n)\n\nexport default component.exports","export * from \"-!../../../../../node_modules/@vue/cli-service/node_modules/mini-css-extract-plugin/dist/loader.js??ref--10-oneOf-1-0!../../../../../node_modules/css-loader/dist/cjs.js??ref--10-oneOf-1-1!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/src/index.js??ref--10-oneOf-1-2!../../../../../node_modules/less-loader/dist/cjs.js??ref--10-oneOf-1-3!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=style&index=0&id=53e209a6&prod&lang=less&scoped=true\"","export default {\n email: /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-])+/\n}\n","import regExp from './regExp'\nimport axios from 'axios'\nconst path = {\n apiMps: '/saas-ability-mps/v1',\n apiCrmOS: '/paas-ability-os/v1/',\n apiCrmUs: '/paas-ability-us/v1/'\n}\n\nclass Server {\n constructor (http = axios, allError = window.global.$message.warning) {\n this.$http = http\n this.error = function (err, isadd, cb) {\n return function (res) {\n const { response } = res\n if (!(response && response.headers && response.headers['x-response-by'] && response.headers['x-response-by'] === 'gateway')) {\n if (err) {\n err(res.data)\n }\n if (isadd || !err) {\n const resData = res.response.data\n const msg = resData.errors && resData.errors.map(function (item) {\n return item.message || item.msg\n }).join(',')\n allError(msg || resData.message || resData.msg || '系统异常,请稍后再试!')\n }\n }\n cb && cb()\n }\n }\n }\n // 提供方法清空所有为空的字段\n static clearAllNull (obj) {\n let o\n if (obj instanceof Array) {\n o = []\n obj.forEach(function (item) {\n o.push(Server.clearAllNull(item))\n })\n } else if (obj instanceof Object) {\n o = Object.assign({}, obj)\n for (const key in o) {\n if (!o[key] && o[key] !== 0) {\n delete o[key]\n } else {\n o[key] = Server.clearAllNull(o[key])\n }\n }\n }\n return o || obj\n }\n // 提供方法清空一层为空的obj字段\n static clearNull (obj) {\n const o = Object.assign({}, obj)\n for (const key in o) {\n if (!o[key] && o[key] !== 0) {\n delete o[key]\n }\n }\n return o\n }\n static clearTrim (obj) {\n const o = Object.assign({}, obj)\n for (const key in o) {\n if (!o[key] && o[key] !== 0) {\n delete o[key]\n } else if (typeof (o[key]) === 'string' || o[key] instanceof String) {\n o[key] = o[key].trim()\n }\n }\n return o\n }\n // 验证集合\n static regExp (type) {\n return regExp[type]\n }\n\n static $message (self, response) {\n if (!(response && response.headers && response.headers['x-response-by'] && response.headers['x-response-by'] === 'gateway')) {\n self.$message({\n type: 'error',\n message: (response && response.data && (response.data.msg || response.data.message || (response.data.errors && response.data.errors.map(function (item) {\n return item.message\n }).join(',')))) || '网络异常,请稍后再试'\n })\n } else if (!response.headers) {\n self.$message(response && response.stack)\n }\n }\n}\n\nServer.path = path\nexport default Server\n"],"sourceRoot":""}