(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["user-pages-distribution-apply"],{"15b5":function(t,e,n){"use strict";n.r(e);var i=n("b836"),a=n("a888");for(var r in a)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(r);var s=n("f0c5"),u=Object(s["a"])(a["default"],i["b"],i["c"],!1,null,"40cb436e",null,!1,i["a"],void 0);e["default"]=u.exports},"15cf":function(t,e,n){"use strict";n("7a82");var i=n("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("d81d");var a=i(n("5530")),r=i(n("c7eb")),s=i(n("1da1")),u=n("26cb"),o={components:{},data:function(){return{cityIndex:0,cityList:[],isLoad:!1,options:{},form:{id:0,user_name:"",mobile:"",text:""},rule:[{name:"user_name",checkType:"isNotNull",errorMsg:"请输入您的真实姓名",regType:2},{name:"mobile",checkType:"isMobile",errorMsg:"请输入常用手机号码"}],lockTap:!1}},computed:(0,u.mapState)({primaryColor:function(t){return t.config.configInfo.primaryColor},subColor:function(t){return t.config.configInfo.subColor},userInfo:function(t){return t.user.userInfo},location:function(t){return t.user.location}}),onLoad:function(t){var e=this;return(0,s.default)((0,r.default)().mark((function n(){return(0,r.default)().wrap((function(n){while(1)switch(n.prev=n.next){case 0:return e.$util.showLoading(),e.options=t,n.next=4,e.initIndex();case 4:e.isLoad=!0;case 5:case"end":return n.stop()}}),n)})))()},methods:(0,a.default)((0,a.default)((0,a.default)({},(0,u.mapActions)(["getUserInfo"])),(0,u.mapMutations)(["updateUserItem"])),{},{initIndex:function(){var t=arguments,e=this;return(0,s.default)((0,r.default)().mark((function n(){var i,a,s;return(0,r.default)().wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(i=t.length>0&&void 0!==t[0]&&t[0],i||!e.$jweixin.isWechat()){n.next=5;break}return n.next=4,e.$jweixin.initJssdk();case 4:e.$jweixin.wxReady((function(){e.$jweixin.hideOptionMenu()}));case 5:return n.next=7,e.$api.mine.resellerInfo();case 7:if(a=n.sent,e.$util.setNavigationBarColor({bg:e.primaryColor}),a.id){n.next=12;break}return e.$util.hideAll(),n.abrupt("return");case 12:for(s in e.form)e.form[s]=a[s];e.$util.hideAll();case 14:case"end":return n.stop()}}),n)})))()},initRefresh:function(){this.initIndex(!0)},validate:function(t){var e=new this.$util.Validate;this.rule.map((function(n){var i=n.name;e.add(t[i],n)}));var n=e.start();return n},submit:function(){var t=this;return(0,s.default)((0,r.default)().mark((function e(){var n,i;return(0,r.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.$util.deepCopy(t.form),i=t.validate(n),!i){e.next=5;break}return t.$util.showToast({title:i}),e.abrupt("return");case 5:if(!t.lockTap){e.next=7;break}return e.abrupt("return");case 7:return t.lockTap=!0,t.$util.showLoading(),n.text=n.text.length>300?n.text.substring(0,300):n.text,e.prev=10,e.next=13,t.$api.mine.applyReseller(n);case 13:t.$util.hideAll(),t.$util.showToast({title:"提交成功"}),setTimeout((function(){t.$util.back(),t.$util.goUrl({url:"/user/pages/apply-result?type=2",openType:"redirectTo"})}),1e3),e.next=21;break;case 18:e.prev=18,e.t0=e["catch"](10),setTimeout((function(){t.lockTap=!1,t.$util.hideAll()}),2e3);case 21:case"end":return e.stop()}}),e,null,[[10,18]])})))()}})};e.default=o},a888:function(t,e,n){"use strict";n.r(e);var i=n("15cf"),a=n.n(i);for(var r in i)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(r);e["default"]=a.a},b836:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.isLoad?n("v-uni-view",{staticClass:"apply-pages"},[n("v-uni-view",{staticClass:"apply-form"},[n("v-uni-view",{staticClass:"fill-base mt-md radius-16"},[n("v-uni-view",{staticClass:"flex-between pl-lg pr-lg b-1px-b"},[n("v-uni-view",{staticClass:"item-text"},[t._v("您的姓名")]),n("v-uni-input",{staticClass:"item-input flex-1",attrs:{type:"text",maxlength:"20",placeholder:t.rule[0].errorMsg},model:{value:t.form.user_name,callback:function(e){t.$set(t.form,"user_name",e)},expression:"form.user_name"}})],1),n("v-uni-view",{staticClass:"flex-between pl-lg pr-lg b-1px-b"},[n("v-uni-view",{staticClass:"item-text"},[t._v("手机号码")]),n("v-uni-input",{staticClass:"item-input flex-1",attrs:{type:"text",placeholder:t.rule[1].errorMsg},model:{value:t.form.mobile,callback:function(e){t.$set(t.form,"mobile",e)},expression:"form.mobile"}})],1)],1),n("v-uni-view",{staticClass:"fill-base mt-md radius-16"},[n("v-uni-view",{staticClass:"flex-between pl-lg pr-lg"},[n("v-uni-view",{staticClass:"item-text"},[t._v("备注信息")]),n("v-uni-input",{staticClass:"item-input flex-1",attrs:{disabled:!0,type:"text"}})],1),n("v-uni-textarea",{staticClass:"item-textarea pd-lg",attrs:{maxlength:"300",placeholder:"输入备注信息"},model:{value:t.form.text,callback:function(e){t.$set(t.form,"text",e)},expression:"form.text"}}),n("v-uni-view",{staticClass:"text-right pb-lg pr-lg"},[t._v(t._s(t.form.text.length>300?300:t.form.text.length)+"/300")])],1)],1),n("v-uni-view",{staticClass:"space-max-footer"}),n("auth",{attrs:{needAuth:t.userInfo&&!t.userInfo.nickName,must:!0,type:"userInfo"},on:{go:function(e){arguments[0]=e=t.$handleEvent(e),t.submit.apply(void 0,arguments)}}},[n("fix-bottom-button",{attrs:{text:[{text:"确定申请",type:"confirm"}],bgColor:"#fff"}})],1)],1):t._e()},a=[]}}]);