zx/public/static/js/pages-users-user_pwd_edit-i...

1 line
7.0 KiB
JavaScript
Raw Normal View History

2024-07-02 15:32:59 +08:00
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-users-user_pwd_edit-index"],{"09390":function(t,e,n){"use strict";n("6a54");var a=n("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var s=a(n("2634")),i=a(n("2fdc")),r=a(n("1ab3")),o=n("02aa"),c=n("672a"),u=n("8f59"),d=a(n("283c")),l=n("e44d"),f={mixins:[r.default],components:{Verify:d.default},data:function(){return{userInfo:{},phone:"",password:"",captcha:"",qr_password:""}},computed:(0,u.mapGetters)(["isLogin"]),onLoad:function(){this.isLogin?this.getUserInfo():(0,l.toLogin)()},methods:{getUserInfo:function(){var t=this;(0,c.getUserInfo)().then((function(e){var n=e.data.phone,a=n.substr(0,3)+"****"+n.substr(7);t.$set(t,"userInfo",e.data),t.phone=a}))},code:function(t){var e=this;return(0,i.default)((0,s.default)().mark((function t(){var n;return(0,s.default)().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(n=e,n.userInfo.phone){t.next=3;break}return t.abrupt("return",n.$util.Tips({title:"手机号码不存在,无法发送验证码!"}));case 3:return t.next=5,(0,o.registerVerify)(n.userInfo.phone).then((function(t){n.$util.Tips({title:t.message}),n.sendCode()})).catch((function(t){return n.$util.Tips({title:t})}));case 5:case"end":return t.stop()}}),t)})))()},editPwd:function(t){var e=this,n=t.detail.value.password,a=t.detail.value.qr_password,s=t.detail.value.captcha;return n?a!=n?e.$util.Tips({title:"两次输入的密码不一致!"}):s?void(0,o.phoneRegisterReset)({account:e.userInfo.phone,captcha:s,password:n}).then((function(t){return e.$util.Tips({title:t.message},{tab:3,url:1})})).catch((function(t){return e.$util.Tips({title:t})})):e.$util.Tips({title:"请输入验证码"}):e.$util.Tips({title:"请输入新密码"})},success:function(t){this.$refs.verify.hide(),this.code(t)},handleVerify:function(){this.$refs.verify.show()}}};e.default=f},"1ab3":function(t,e,n){"use strict";n("6a54"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a={data:function(){return{disabled:!1,text:"获取验证码"}},methods:{sendCode:function(){var t=this;if(!this.disabled){this.disabled=!0;var e=60;this.text="剩余 "+e+"s";var n=setInterval((function(){e-=1,e<0&&clearInterval(n),t.text="剩余 "+e+"s",t.text<"剩余 0s"&&(t.disabled=!1,t.text="重新获取")}),1e3)}}}};e.default=a},"2ec5":function(t,e,n){"use strict";t.exports=function(t,e){return e||(e={}),t=t&&t.__esModule?t.default:t,"string"!==typeof t?t:(/^['"].*['"]$/.test(t)&&(t=t.slice(1,-1)),e.hash&&(t+=e.hash),/["'() \t\n]/.test(t)||e.needQuotes?'"'.concat(t.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):t)}},"45bd":function(t,e,n){"use strict";var a=n("9bc8"),s=n.n(a);s.a},5560:function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return s})),n.d(e,"a",(function(){}));var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",[n("v-uni-view",{staticClass:"ChangePassword"},[n("v-uni-form",{attrs:{"report-submit":"true"},on:{submit:function(e){arguments[0]=e=t.$handleEvent(e),t.editPwd.apply(void 0,arguments)}}},[n("v-uni-view",{staticClass:"phone"},[t._v("当前手机号:"+t._s(t.phone))]),n("v-uni-view",{staticClass:"list"},[n("v-uni-view",{staticClass:"item"},[n("v-uni-input",{attrs:{type:"password",placeholder:"设置新密码","placeholder-class":"placeholder",name:"password",value:t.password}})],1),n("v-uni-view",{staticClass:"item"},[n("v-uni-input",{attrs:{type:"password",placeholder:"确认新密码","placeholder-class":"placeholder",name:"qr_password",value:t.qr_password}})],1),n("v-uni-view",{staticClass:"item acea-row row-between-wrapper"},[n("v-uni-input",{staticClass:"codeIput",attrs:{type:"number",placeholder:"填写验证码","placeholder-class":"placeholder",name:"captcha",value:t.captcha}}),n("v-uni-button",{staticClass:"code font-color",class:!0===t.disabled?"on":"",attrs:{disabled:t.disabled},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.handleVerify.apply(void 0,arguments)}}},[t._v(t._s(t.text))])],1)],1),n("v-uni-button",{staticClass:"confirmBnt bg-