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 line
6.9 KiB
1 line
6.9 KiB
5 months ago
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["user-pages-salesman-apply"],{"1ef5":function(t,e,n){"use strict";n("7a82");var a=n("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("d81d");var i=a(n("5530")),s=a(n("c7eb")),r=a(n("1da1")),u=n("26cb"),o={components:{},data:function(){return{isLoad:!1,options:{},tipArr:{1:[{text:"您已经成功提交申请",color:0},{text:"审核将在3个工作日内出结果,请耐心等待",color:0}],2:[{text:"恭喜您,审核通过!",color:0},{text:"您已具备业务员资格,快去分享体验吧~",color:0}],3:[{text:"请联系平台管理人员询问原因",color:0}],4:[{text:"请联系平台管理人员询问失败原因",color:0}]},buttonArr:{1:[{text:"个人中心",type:"cancel"}],2:[{text:"去分享",type:"confirm"}],3:[{text:"个人中心",type:"cancel"}],4:[{text:"再次申请",type:"confirm"},{text:"个人中心",type:"cancel"}]},title:{"-1":"申请业务员",1:"等待审核",2:"",3:"取消授权",4:"申请失败"},image:{1:"https://lbqny.migugu.com/admin/public/apply_wait.jpg",2:"https://lbqny.migugu.com/admin/public/apply_suc.jpg",3:"https://lbqny.migugu.com/admin/public/apply_fail.jpg",4:"https://lbqny.migugu.com/admin/public/apply_fail.jpg"},salesman_status:-1,form:{id:0,admin_id:0,user_name:"",phone:""},rule:[{name:"user_name",checkType:"isNotNull",errorMsg:"请输入您的真实姓名",regType:2},{name:"phone",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}}),onLoad:function(t){var e=this;return(0,r.default)((0,s.default)().mark((function n(){var a,i,r,u,o;return(0,s.default)().wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(e.$util.showLoading(),a=t,i=a.admin_id,r=void 0===i?0:i,!r){n.next=8;break}return n.next=5,e.updateCommonOptions(t);case 5:n.t0=n.sent,n.next=9;break;case 8:n.t0=t;case 9:return t=n.t0,e.options=t,n.next=13,e.initIndex();case 13:u=e.title,o=e.salesman_status,uni.setNavigationBarTitle({title:u[o]}),e.isLoad=!0;case 16:case"end":return n.stop()}}),n)})))()},methods:(0,i.default)((0,i.default)((0,i.default)({},(0,u.mapActions)(["getConfigInfo","getUserInfo","updateCommonOptions"])),(0,u.mapMutations)(["updateUserItem"])),{},{initIndex:function(){var t=arguments,e=this;return(0,r.default)((0,s.default)().mark((function n(){var a,i,r,u,o,l,c;return(0,s.default)().wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(a=t.length>0&&void 0!==t[0]&&t[0],a||!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.salesman.salesmanInfo();case 7:if(i=n.sent,e.$util.setNavigationBarColor({bg:e.primaryColor}),i.id){for(o in r=e.options.admin_id,u=void 0===r?0:r,u&&(i.admin_id=u),e.form)e.form[o]=i[o];l=i.status,c=i.sh_text,e.salesman_status=u||4!=l?l:-1,4==l&&c&&(e.tipArr[4][0].text=c)}e.$util.hideAll();case 11:case"end":return n.stop()}}),n)})))()},initRefresh:function(){this.initIndex(!0)},confirm:function(){var t=this;return(0,r.default)((0,s.default)().mark((function e(){var n,a;return(0,s.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.salesman_status,4!=n){e.next=5;break}return t.salesman_status=-1,uni.setNavigationBarTitle({title:"申请业务员"}),e.abrupt("return");case 5:a=2==n?"/user/pages/salesman/income":"/pages/mine",t.$util.log(a),t.$util.goUrl({url:a,openType:"reLaunch"});case 8:case"end":return e.stop()}}),e)})))()},validate:function(t){var e=new this.$util.Validate;this.rule.map((function(n){var a=n.name;e.add(t[a],n)}));var n=e.start();return n},submit:function(){var t=this;return(0,r.default)((0,s.default)().mark((function e(){var n,a,i;return(0,s.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.$util.deepCopy(t.form),a=t.validate(n),!a){e.next=5;break}return t.$util.showToast({title:a}),e.ab
|