You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
13 KiB
1 lines
13 KiB
{"version":3,"sources":["uni-app:///main.js","webpack:///C:/Users/18634/Desktop/项目/xxdj1/user/pages/channel/apply.vue?563e","webpack:///C:/Users/18634/Desktop/项目/xxdj1/user/pages/channel/apply.vue?ec51","webpack:///C:/Users/18634/Desktop/项目/xxdj1/user/pages/channel/apply.vue?05e4","webpack:///C:/Users/18634/Desktop/项目/xxdj1/user/pages/channel/apply.vue?e14f","uni-app:///user/pages/channel/apply.vue"],"names":["wx","__webpack_require_UNI_MP_PLUGIN__","__webpack_require__","createPage","Page","components","data","channelInd","channelList","isLoad","options","form","id","user_name","mobile","cate_id","text","rule","name","checkType","errorMsg","regType","lockTap","computed","primaryColor","subColor","userInfo","location","onLoad","methods","initIndex","refresh","Promise","channelInfo","list","bg","initRefresh","pickerChange","validate","item","submit","param","msg","title","setTimeout","url","openType"],"mappings":";;;;;;;;;;;;;AAAA;AAE2D;AAC3D;AACA;AAHA;AACAA,EAAE,CAACC,iCAAiC,GAAGC,mBAAmB;AAG1DC,UAAU,CAACC,cAAI,CAAC,C;;;;;;;;;;;;;ACLhB;AAAA;AAAA;AAAA;AAAA;AAAkH;AAClH;AACyD;AACL;;;AAGpD;AACqK;AACrK,gBAAgB,+KAAU;AAC1B,EAAE,2EAAM;AACR,EAAE,gFAAM;AACR,EAAE,yFAAe;AACjB;AACA;AACA;AACA;AACA;AACA,EAAE,oFAAU;AACZ;AACA;;AAEA;AACe,gF;;;;;;;;;;;;ACtBf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;ACvBA;AAAA;AAAA;AAAA;AAA+lB,CAAgB,ynBAAG,EAAC,C;;;;;;;;;;;;;;;;;;;;;;;ACiDnnB;AAIA;AAAA;AAAA,eACA;EACAC;EACAC;IACA;MACAC;MACAC;MACAC;MACAC;MACAC;QACAC;QACAC;QAAA;QACAC;QAAA;QACAC;QAAA;QACAC;MACA;MACAC;QACAC;QACAC;QACAC;QACAC;MACA,GACA;QACAH;QACAC;QACAC;MACA,GACA;QACAF;QACAC;QACAC;MACA,EACA;MACAE;IACA;EACA;EACAC;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;EACA;EACAC;IAAA;IAAA;MAAA;QAAA;UAAA;YAAA;cACA;cACA;cAAA;cAAA,OACA;YAAA;cACA;YAAA;YAAA;cAAA;UAAA;QAAA;MAAA;IAAA;EACA;EACAC,uDACA,yCACA;IACAC;MAAA;QAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBAAAC;gBAAA;gBAAA,OASAC,0EACAC,cACA;cAAA;gBAAA;gBAAA;gBAFAC;gBAAA5B;gBAGA;kBACA6B;gBACA;gBACA;gBAAA,IACA7B;kBAAA;kBAAA;gBAAA;gBACA;gBAAA;cAAA;gBAGA;kBACA;gBACA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IACA;IACA8B;MACA;IACA;IACAC;MACA;MACA;IACA;IACA;IACAC;MACA;MACA;QACA,IACApB,OACAqB,KADArB;QAEAoB;MACA;MACA;MACA;IACA;IACAE;MAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBACAC;gBACAC;gBAAA,KACAA;kBAAA;kBAAA;gBAAA;gBACA;kBACAC;gBACA;gBAAA;cAAA;gBAAA,KAGA;kBAAA;kBAAA;gBAAA;gBAAA;cAAA;gBACA;gBACAF;gBACA;gBAAA;gBAAA;gBAAA,OAEA;cAAA;gBACA;gBACA;kBACAE;gBACA;gBACAC;kBACA;kBACA;oBACAC;oBACAC;kBACA;gBAEA;gBAAA;gBAAA;cAAA;gBAAA;gBAAA;gBAEAF;kBACA;kBACA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IAGA;EAAA;AAEA;AAAA,2B","file":"user/pages/channel/apply.js","sourcesContent":["import 'uni-pages';\n// @ts-ignore\nwx.__webpack_require_UNI_MP_PLUGIN__ = __webpack_require__;import '@dcloudio/uni-stat/dist/uni-stat.es.js';\nimport Vue from 'vue'\nimport Page from './user/pages/channel/apply.vue'\ncreatePage(Page)","import { render, staticRenderFns, recyclableRender, components } from \"./apply.vue?vue&type=template&id=25034821&\"\nvar renderjs\nimport script from \"./apply.vue?vue&type=script&lang=js&\"\nexport * from \"./apply.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\runtime\\\\componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null,\n false,\n components,\n renderjs\n)\n\ncomponent.options.__file = \"user/pages/channel/apply.vue\"\nexport default component.exports","export * from \"-!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\templateLoader.js??vue-loader-options!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--17-0!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\template.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-uni-app-loader\\\\page-meta.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./apply.vue?vue&type=template&id=25034821&\"","var components\nvar render = function () {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n var g0 = _vm.isLoad\n ? _vm.channelInd != -1 && _vm.channelList.length > 0\n : null\n var g1 = _vm.isLoad ? _vm.form.text.length : null\n var g2 = _vm.isLoad && !(g1 > 300) ? _vm.form.text.length : null\n _vm.$mp.data = Object.assign(\n {},\n {\n $root: {\n g0: g0,\n g1: g1,\n g2: g2,\n },\n }\n )\n}\nvar recyclableRender = false\nvar staticRenderFns = []\nrender._withStripped = true\n\nexport { render, staticRenderFns, recyclableRender, components }","import mod from \"-!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--13-1!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./apply.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--13-1!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./apply.vue?vue&type=script&lang=js&\"","<template>\r\n\t<view class=\"apply-pages\" v-if=\"isLoad\">\r\n\t\t<view class=\"apply-form\">\r\n\t\t\t<view class=\"fill-base mt-md radius-16\">\r\n\t\t\t\t<view class=\"flex-between pl-lg pr-lg b-1px-b\">\r\n\t\t\t\t\t<view class=\"item-text\">您的姓名</view>\r\n\t\t\t\t\t<input v-model=\"form.user_name\" type=\"text\" class=\"item-input flex-1\" maxlength=\"20\"\r\n\t\t\t\t\t\t:placeholder=\"rule[0].errorMsg\" />\r\n\t\t\t\t</view>\r\n\t\t\t\t<view class=\"flex-between pl-lg pr-lg b-1px-b\">\r\n\t\t\t\t\t<view class=\"item-text\">手机号码</view>\r\n\t\t\t\t\t<input v-model=\"form.mobile\" type=\"text\" class=\"item-input flex-1\"\r\n\t\t\t\t\t\t:placeholder=\"rule[1].errorMsg\" />\r\n\t\t\t\t</view>\r\n\t\t\t\t<view class=\"flex-between pl-lg pr-lg b-1px-b\">\r\n\t\t\t\t\t<view class=\"item-text\">申请渠道</view>\r\n\t\t\t\t\t<view class=\"item-input flex-1 text\">\r\n\t\t\t\t\t\t<picker @change=\"pickerChange($event)\" :value=\"channelInd\" :range=\"channelList\"\r\n\t\t\t\t\t\t\trange-key=\"title\">\r\n\t\t\t\t\t\t\t<view class=\"flex-between\" style=\"color: #A9A9A9;\">\r\n\t\t\t\t\t\t\t\t{{channelInd!=-1 && channelList.length > 0?channelList[channelInd].title:'请选择您能接入的渠道'}}\r\n\t\t\t\t\t\t\t\t<i class=\"iconfont icon-right ml-sm\" style=\"font-size: 28rpx;\"></i>\r\n\t\t\t\t\t\t\t</view>\r\n\t\t\t\t\t\t</picker>\r\n\t\t\t\t\t</view>\r\n\t\t\t\t</view>\r\n\t\t\t</view>\r\n\t\t\t<view class=\"fill-base mt-md radius-16\">\r\n\t\t\t\t<view class=\"flex-between pl-lg pr-lg\">\r\n\t\t\t\t\t<view class=\"item-text\">备注信息</view>\r\n\t\t\t\t\t<input :disabled=\"true\" type=\"text\" class=\"item-input flex-1\" />\r\n\t\t\t\t</view>\r\n\t\t\t\t<textarea v-model=\"form.text\" class=\"item-textarea pd-lg\" maxlength=\"300\" placeholder=\"输入备注信息\" />\r\n\t\t\t\t<view class=\"text-right pb-lg pr-lg\">\r\n\t\t\t\t\t{{form.text.length>300?300:form.text.length}}/300\r\n\t\t\t\t</view>\r\n\t\t\t</view>\r\n\t\t</view>\r\n\r\n\t\t<view class=\"space-max-footer\"></view>\r\n\r\n\t\t<auth :needAuth=\"userInfo && !userInfo.nickName\" :must=\"true\" type=\"userInfo\" @go=\"submit\">\r\n\t\t\t<fix-bottom-button :text=\"[{text:'确定申请',type:'confirm'}]\" bgColor=\"#fff\"></fix-bottom-button>\r\n\t\t</auth>\r\n\r\n\t</view>\r\n</template>\r\n\r\n<script>\r\n\timport {\r\n\t\tmapState,\r\n\t\tmapActions,\r\n\t\tmapMutations\r\n\t} from \"vuex\"\r\n\texport default {\r\n\t\tcomponents: {},\r\n\t\tdata() {\r\n\t\t\treturn {\r\n\t\t\t\tchannelInd: -1,\r\n\t\t\t\tchannelList: [],\r\n\t\t\t\tisLoad: false,\r\n\t\t\t\toptions: {},\r\n\t\t\t\tform: {\r\n\t\t\t\t\tid: 0,\r\n\t\t\t\t\tuser_name: '', //姓名 \r\n\t\t\t\t\tmobile: '', //手机号 \r\n\t\t\t\t\tcate_id: '', // 渠道\r\n\t\t\t\t\ttext: ''\r\n\t\t\t\t},\r\n\t\t\t\trule: [{\r\n\t\t\t\t\t\tname: \"user_name\",\r\n\t\t\t\t\t\tcheckType: \"isNotNull\",\r\n\t\t\t\t\t\terrorMsg: \"请输入您的真实姓名\",\r\n\t\t\t\t\t\tregType: 2\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tname: \"mobile\",\r\n\t\t\t\t\t\tcheckType: \"isMobile\",\r\n\t\t\t\t\t\terrorMsg: \"请输入常用手机号码\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tname: \"cate_id\",\r\n\t\t\t\t\t\tcheckType: \"isNotNull\",\r\n\t\t\t\t\t\terrorMsg: \"请选择您能接入的渠道\"\r\n\t\t\t\t\t}\r\n\t\t\t\t],\r\n\t\t\t\tlockTap: false\r\n\t\t\t}\r\n\t\t},\r\n\t\tcomputed: mapState({\r\n\t\t\tprimaryColor: state => state.config.configInfo.primaryColor,\r\n\t\t\tsubColor: state => state.config.configInfo.subColor,\r\n\t\t\tuserInfo: state => state.user.userInfo,\r\n\t\t\tlocation: state => state.user.location,\r\n\t\t}),\r\n\t\tasync onLoad(options) {\r\n\t\t\tthis.$util.showLoading()\r\n\t\t\tthis.options = options\r\n\t\t\tawait this.initIndex()\r\n\t\t\tthis.isLoad = true\r\n\t\t},\r\n\t\tmethods: {\r\n\t\t\t...mapActions(['getUserInfo']),\r\n\t\t\t...mapMutations(['updateUserItem']),\r\n\t\t\tasync initIndex(refresh = false) {\r\n\t\t\t\t// #ifdef H5\r\n\t\t\t\tif (!refresh && this.$jweixin.isWechat()) {\r\n\t\t\t\t\tawait this.$jweixin.initJssdk();\r\n\t\t\t\t\tthis.$jweixin.wxReady(() => {\r\n\t\t\t\t\t\tthis.$jweixin.hideOptionMenu()\r\n\t\t\t\t\t})\r\n\t\t\t\t}\r\n\t\t\t\t// #endif\r\n\t\t\t\tlet [list, data] = await Promise.all([this.$api.channel.channelCateSelect(), this.$api.channel\r\n\t\t\t\t\t.channelInfo()\r\n\t\t\t\t])\r\n\t\t\t\tthis.$util.setNavigationBarColor({\r\n\t\t\t\t\tbg: this.primaryColor\r\n\t\t\t\t})\r\n\t\t\t\tthis.channelList = list\r\n\t\t\t\tif (!data.id) {\r\n\t\t\t\t\tthis.$util.hideAll()\r\n\t\t\t\t\treturn\r\n\t\t\t\t}\r\n\t\t\t\tfor (let key in this.form) {\r\n\t\t\t\t\tthis.form[key] = data[key]\r\n\t\t\t\t}\r\n\t\t\t\tthis.$util.hideAll()\r\n\t\t\t},\r\n\t\t\tinitRefresh() {\r\n\t\t\t\tthis.initIndex(true)\r\n\t\t\t},\r\n\t\t\tpickerChange(e, val) {\r\n\t\t\t\tthis.channelInd = e.target.value\r\n\t\t\t\tthis.form.cate_id = this.channelList[this.channelInd].id\r\n\t\t\t},\r\n\t\t\t//表单验证\r\n\t\t\tvalidate(param) {\r\n\t\t\t\tlet validate = new this.$util.Validate();\r\n\t\t\t\tthis.rule.map(item => {\r\n\t\t\t\t\tlet {\r\n\t\t\t\t\t\tname,\r\n\t\t\t\t\t} = item\r\n\t\t\t\t\tvalidate.add(param[name], item);\r\n\t\t\t\t})\r\n\t\t\t\tlet message = validate.start();\r\n\t\t\t\treturn message;\r\n\t\t\t},\r\n\t\t\tasync submit() {\r\n\t\t\t\tlet param = this.$util.deepCopy(this.form)\r\n\t\t\t\tlet msg = this.validate(param);\r\n\t\t\t\tif (msg) {\r\n\t\t\t\t\tthis.$util.showToast({\r\n\t\t\t\t\t\ttitle: msg\r\n\t\t\t\t\t});\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\tif (this.lockTap) return\r\n\t\t\t\tthis.lockTap = true\r\n\t\t\t\tparam.text = param.text.length > 300 ? param.text.substring(0, 300) : param.text\r\n\t\t\t\tthis.$util.showLoading()\r\n\t\t\t\ttry {\r\n\t\t\t\t\tawait this.$api.channel.applyChannel(param)\r\n\t\t\t\t\tthis.$util.hideAll()\r\n\t\t\t\t\tthis.$util.showToast({\r\n\t\t\t\t\t\ttitle: `提交成功`\r\n\t\t\t\t\t});\r\n\t\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t\tthis.$util.back()\r\n\t\t\t\t\t\tthis.$util.goUrl({\r\n\t\t\t\t\t\t\turl: '/user/pages/apply-result?type=3',\r\n\t\t\t\t\t\t\topenType: `redirectTo`\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t}, 1000)\r\n\t\t\t\t} catch (e) {\r\n\t\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t\tthis.lockTap = false\r\n\t\t\t\t\t\tthis.$util.hideAll()\r\n\t\t\t\t\t}, 2000)\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n</script>\r\n\r\n\r\n<style lang=\"scss\">\r\n</style>\r\n"],"sourceRoot":""} |