(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["user-pages-phone-code"],{"055c":function(t,e,n){var i=n("24fb");e=i(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */uni-page-body[data-v-46084acc]{background:#fff}body.?%PAGE?%[data-v-46084acc]{background:#fff}.mine-pages-phone .title[data-v-46084acc]{font-size:%?54?%;margin-top:%?80?%}.mine-pages-phone .confirm-btn[data-v-46084acc]{width:%?630?%;height:%?110?%;background:#f7f7f7;margin-top:%?40?%}.mine-pages-phone .confirm-btn .item-input[data-v-46084acc]{height:%?110?%}',""]),t.exports=e},"0702":function(t,e,n){var i=n("24fb");e=i(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.xt__verify-code[data-v-2227a166]{position:relative;width:100%;box-sizing:border-box}.xt__verify-code .xt__input[data-v-2227a166]{height:100%;width:200%;position:absolute;left:-100%;z-index:1}.xt__verify-code .xt__cursor[data-v-2227a166]{position:absolute;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);display:inline-block;width:2px;-webkit-animation-name:cursor-data-v-2227a166;animation-name:cursor-data-v-2227a166;-webkit-animation-duration:.8s;animation-duration:.8s;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.xt__verify-code .xt__input-ground[data-v-2227a166]{display:flex;justify-content:space-between;align-items:center;width:100%;box-sizing:border-box}.xt__verify-code .xt__input-ground .xt__box[data-v-2227a166]{position:relative;display:inline-block;width:%?88?%;height:%?100?%;background:#f7f7f7;border-radius:%?12?%;margin-left:%?20?%}.xt__verify-code .xt__input-ground .xt__box-bottom[data-v-2227a166]{border-bottom:%?1?% solid #009254}.xt__verify-code .xt__input-ground .xt__box-box[data-v-2227a166]{border:%?1?% solid #009254}.xt__verify-code .xt__input-ground .xt__box-middle[data-v-2227a166]{border:none}.xt__verify-code .xt__input-ground .xt__box .xt__middle-line[data-v-2227a166]{position:absolute;top:50%;left:50%;width:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);border-bottom-width:2px;border-bottom-style:solid}.xt__verify-code .xt__input-ground .xt__box .xt__code-text[data-v-2227a166]{position:absolute;top:50%;left:50%;font-size:%?58?%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.xt__verify-code .xt__input-ground .xt__box[data-v-2227a166]:nth-child(1){margin-left:0}@-webkit-keyframes cursor-data-v-2227a166{0%{opacity:1}100%{opacity:0}}@keyframes cursor-data-v-2227a166{0%{opacity:1}100%{opacity:0}}',""]),t.exports=e},1331:function(t,e,n){"use strict";n.r(e);var i=n("2e5a"),r=n.n(i);for(var o in i)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(o);e["default"]=r.a},"1ce7":function(t,e,n){"use strict";n.r(e);var i=n("7faf"),r=n.n(i);for(var o in i)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(o);e["default"]=r.a},"2d28":function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",{staticClass:"mine-pages-phone flex-center flex-column"},[n("v-uni-view",{staticClass:"title c-black"},[t._v("请输入验证码")]),n("v-uni-view",{staticClass:"flex-y-center f-caption c-caption mt-lg"},[t._v("验证码已发送至"),n("v-uni-view",{staticClass:"ml-sm",style:{color:t.primaryColor}},[t._v(t._s(t.subForm.phone))])],1),n("v-uni-view",{staticClass:"space-lg"}),n("v-uni-view",{staticClass:"space-lg"}),n("v-uni-view",{staticClass:"space-md"}),n("v-uni-view",[n("xt-verify-code",{on:{confirm:function(e){arguments[0]=e=t.$handleEvent(e),t.confirm.apply(void 0,arguments)}},model:{value:t.subForm.short_code,callback:function(e){t.$set(t.subForm,"short_code",e)},expression:"subForm.short_code"}})],1),n("v-uni-view",{staticClass:"flex-center f-caption c-caption mt-lg"},[t.authTime>0?n("v-uni-view",{staticClass:"flex-center"},[n("v-uni-view",{staticClass:"c-title mr-sm"},[t._v(t._s(t.authTime+"s"))]),t._v("后")],1):t._e(),n("v-uni-view",{style:{color:t.authTime>0?"":t.primaryColor},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.toResetCode.apply(void 0,arguments)}}},[t._v("重新获取")])],1),n("v-uni-view",{staticClass:"confirm-btn flex-center f-sm-title text-bold c-base radius-16",style:{background:t.subForm.short_code.length>0?t.primaryColor:"#CCE9DD"},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.submit.apply(void 0,arguments)}}},[t._v("确定")])],1)},r=[]},"2e5a":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 r=i(n("5530")),o=i(n("c7eb")),a=i(n("1da1")),u=n("26cb"),s=i(n("3c23")),c={components:{xtVerifyCode:s.default},data:function(){return{isLoad:!1,options:{},authTime:60,timer:null,subForm:{phone:"",short_code:""},rule:[{name:"short_code",checkType:"isNotNull",errorMsg:"请输入短信验证码",regText:"短信验证码"}],lockTap:!1}},computed:(0,u.mapState)({primaryColor:function(t){return t.config.configInfo.primaryColor},subColor:function(t){return t.config.configInfo.subColor}}),onLoad:function(t){var e=this;return(0,a.default)((0,o.default)().mark((function n(){var i;return(0,o.default)().wrap((function(n){while(1)switch(n.prev=n.next){case 0:e.$util.setNavigationBarColor({color:"#000000",bg:"#ffffff"}),i=t.phone,e.subForm.phone=i,e.initIndex();case 4:case"end":return n.stop()}}),n)})))()},methods:(0,r.default)((0,r.default)((0,r.default)({},(0,u.mapActions)(["getUserInfo"])),(0,u.mapMutations)(["updateUserItem"])),{},{initIndex:function(){var t=this;return(0,a.default)((0,o.default)().mark((function e(){var n;return(0,o.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=60,t.timer=setInterval((function(){0!==n?(n--,t.authTime=n):clearTimeout(t.timer)}),1e3);case 2:case"end":return e.stop()}}),e)})))()},initRefresh:function(){this.initIndex()},toResetCode:function(){var t=this;return(0,a.default)((0,o.default)().mark((function e(){var n,i;return(0,o.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.authTime,!n){e.next=3;break}return e.abrupt("return");case 3:return t.timer&&clearTimeout(t.timer),i=t.subForm.phone,e.next=7,t.$api.user.sendShortMsg({phone:i});case 7:t.$util.showToast({title:"验证码发送成功"}),t.initRefresh();case 9:case"end":return e.stop()}}),e)})))()},confirm:function(){},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,a.default)((0,o.default)().mark((function e(){var n,i;return(0,o.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.$util.deepCopy(t.subForm),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(),e.prev=9,e.next=12,t.$api.user.bindUserPhone(n);case 12:t.$util.hideAll(),t.lockTap=!1,t.timer&&clearTimeout(t.timer),setTimeout((function(){t.$util.goUrl({url:"/pages/service",openType:"reLaunch"})}),1e3),e.next=21;break;case 18:e.prev=18,e.t0=e["catch"](9),setTimeout((function(){t.lockTap=!1,t.$util.hideAll()}),2e3);case 21:case"end":return e.stop()}}),e,null,[[9,18]])})))()}})};e.default=c},"3c23":function(t,e,n){"use strict";n.r(e);var i=n("cebe"),r=n("1ce7");for(var o in r)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);n("b49a");var a=n("f0c5"),u=Object(a["a"])(r["default"],i["b"],i["c"],!1,null,"2227a166",null,!1,i["a"],void 0);e["default"]=u.exports},"7cba":function(t,e,n){"use strict";var i=n("e64f"),r=n.n(i);r.a},"7faf":function(t,e,n){"use strict";n("7a82"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("a9e3"),n("ac1f"),n("d3b7"),n("159b"),n("14d9");var i={name:"xt-verify-code",props:{value:{type:String,default:function(){return""}},type:{type:String,default:function(){return"box"}},inputType:{type:String,default:function(){return"number"}},size:{type:Number,default:function(){return 6}},isFocus:{type:Boolean,default:function(){return!0}},isPassword:{type:Boolean,default:function(){return!1}},cursorColor:{type:String,default:function(){return"#cccccc"}},boxNormalColor:{type:String,default:function(){return"#f7f7f7"}},boxActiveColor:{type:String,default:function(){return"#009254"}}},model:{prop:"value",event:"input"},data:function(){return{cursorVisible:!1,cursorHeight:35,code:"",codeCursorLeft:[],itemSize:6}},created:function(){this.cursorVisible=this.isFocus,this.validatorSize()},mounted:function(){this.init()},methods:{validatorSize:function(){this.size<=6&&this.size>0?this.itemSize=Math.floor(this.size):this.itemSize=6},init:function(){this.getCodeCursorLeft(),this.setCursorHeight()},getElement:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"single",n=arguments.length>2?arguments[2]:void 0;uni.createSelectorQuery().in(this)["array"===e?"selectAll":"select"](t).boundingClientRect().exec((function(t){n(t[0])}))},setCursorHeight:function(){var t=this;this.getElement(".xt__box","single",(function(e){t.cursorHeight=.6*e.height}))},getCodeCursorLeft:function(){var t=this;this.getElement("#xt__input-ground","single",(function(e){var n=e.left;t.getElement(".xt__box","array",(function(e){t.codeCursorLeft=[],e.forEach((function(e){t.codeCursorLeft.push(e.left-n+e.width/2)}))}))}))},input:function(t){var e=t.detail.value;this.cursorVisible=e.length!==this.itemSize,this.$emit("input",e),this.inputSuccess(e)},inputSuccess:function(t){t.length===this.itemSize&&this.$emit("confirm",t)},inputFocus:function(){this.cursorVisible=this.code.length!==this.itemSize},inputBlur:function(){this.cursorVisible=!1}},watch:{value:function(t){this.code=t}},filters:{codeFormat:function(t,e){var n="";return t&&(n=e?"*":t),n}}};e.default=i},"9ac9":function(t,e,n){"use strict";n.r(e);var i=n("2d28"),r=n("1331");for(var o in r)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);n("7cba");var a=n("f0c5"),u=Object(a["a"])(r["default"],i["b"],i["c"],!1,null,"46084acc",null,!1,i["a"],void 0);e["default"]=u.exports},b49a:function(t,e,n){"use strict";var i=n("d104"),r=n.n(i);r.a},cebe:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",{staticClass:"xt__verify-code"},[n("v-uni-input",{staticClass:"xt__input",attrs:{id:"xt__input",value:t.code,focus:t.isFocus,password:t.isPassword,type:t.inputType,maxlength:t.itemSize},on:{input:function(e){arguments[0]=e=t.$handleEvent(e),t.input.apply(void 0,arguments)},focus:function(e){arguments[0]=e=t.$handleEvent(e),t.inputFocus.apply(void 0,arguments)},blur:function(e){arguments[0]=e=t.$handleEvent(e),t.inputBlur.apply(void 0,arguments)}}}),t.cursorVisible&&"middle"!==t.type?n("v-uni-view",{staticClass:"xt__cursor",style:{left:t.codeCursorLeft[t.code.length]+"px",height:t.cursorHeight+"px",backgroundColor:t.cursorColor},attrs:{id:"xt__cursor"}}):t._e(),n("v-uni-view",{staticClass:"xt__input-ground",attrs:{id:"xt__input-ground"}},[t._l(t.itemSize,(function(e,i){return[n("v-uni-view",{key:i,class:["xt__box","xt__box-"+t.type,"xt__box::after"],style:{borderColor:t.code.length===i&&t.cursorVisible?t.boxActiveColor:t.boxNormalColor}},["middle"!==t.type||t.code[i]?t._e():n("v-uni-view",{staticClass:"xt__middle-line",style:{borderColor:t.boxActiveColor}}),n("v-uni-text",{staticClass:"xt__code-text"},[t._v(t._s(t._f("codeFormat")(t.code[i],t.isPassword)))])],1)]}))],2)],1)},r=[]},d104:function(t,e,n){var i=n("0702");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=n("4f06").default;r("54af0132",i,!0,{sourceMap:!1,shadowMode:!1})},e64f:function(t,e,n){var i=n("055c");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=n("4f06").default;r("281c1dc4",i,!0,{sourceMap:!1,shadowMode:!1})}}]);