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
24 KiB

{"version":3,"sources":["webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?1c64","webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?f80f","webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?cce9","webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?0155","uni-app:///components/auth.vue","webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?34d5","webpack:///C:/Users/18634/Desktop/项目/xxdj1/components/auth.vue?b0c2"],"names":["components","name","props","needAuth","type","default","must","userMust","showAuth","btn_text","computed","primaryColor","subColor","configInfo","commonOptions","userInfo","created","data","contentList","phone","setting","pType","pMust","authTime","timer","subForm","short_code","rule","checkType","errorMsg","regText","lockTap","methods","init","authPhone","e","console","authUserProfile","uni","desc","success","res","encryptedData","iv","fail","toUpdateUserInfo","coupon_atv_id","toShowAuth","go","toResetItem","validate","item","toSend","msg","title","time","clearTimeout","setTimeout","submit","param"],"mappings":";;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAiH;AACjH;AACwD;AACL;AACc;;;AAGjE;AACqK;AACrK,gBAAgB,+KAAU;AAC1B,EAAE,0EAAM;AACR,EAAE,+EAAM;AACR,EAAE,wFAAe;AACjB;AACA;AACA;AACA;AACA;AACA,EAAE,mFAAU;AACZ;AACA;;AAEA;AACe,gF;;;;;;;;;;;;ACvBf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;ACRA;AAAA;AAAA;AAAA;AAA8lB,CAAgB,wnBAAG,EAAC,C;;;;;;;;;;;;;;;;;;;;;;ACkGlnB;AAIA;AAAA;AAAA,gBACA;EACAA;EACAC;EACAC;IACAC;MACAC;MACAC;QACA;MACA;IACA;IACAC;MACAF;MACAC;QACA;MACA;IACA;IACAE;MACAH;MACAC;QACA;MACA;IACA;IACAG;MACAJ;MACAC;QACA;MACA;IACA;IACAD;MACAA;MACAC;QACA;MACA;IACA;IACAI;MACAL;MACAC;QACA;MACA;IACA;EACA;EACAK;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;IACAC;MAAA;IAAA;EACA;EACAC;IACA;EACA;EACAC;IACA;MACAC;QACAH;QACAI;QACAC;MACA;MACAC;MACAC;MACAC;MACAC;MACAC;QACAN;QACAO;MACA;MACAC;QACA1B;QACA2B;QACAC;QACAC;MACA;QACA7B;QACA2B;QACAC;QACAC;MACA;MACAC;IACA;EACA;EACAC,yCACA;IACAC;MACA,IACA7B,OAGA,KAHAA;QACAE,OAEA,KAFAA;QACAE,WACA,KADAA;MAEA;MACA;MACA;MACA;IACA;IACA0B;MAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBAEAZ,QACA,MADAA;gBAAA;gBAAA,OAEA;kBACAa;gBACA;cAAA;gBAFAhB;gBAGAiB;gBAAA,IACAjB;kBAAA;kBAAA;gBAAA;gBACA;gBAAA,iCACA;cAAA;gBAEA;gBACA;gBACAiB;gBAAA,IACA;kBAAA;kBAAA;gBAAA;gBAAA;cAAA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IAEA;IACAC;MAAA;MAAA;QAAA;UAAA;YAAA;cAAA;gBAaAC;kBACAC;kBAAA;kBACAC;oBACA,oBAIAC,IAHA1B;sBAAAA;sBACA2B,gBAEAD,IAFAC;sBACAC,KACAF,IADAE;oBAEA;sBACAD;sBACAC;oBACA;oBACA;kBACA;kBACAC;oBACAR;oBACA;kBACA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IAEA;IACAS;MAAA;QAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBAAA9B;gBAEAO,QACA,OADAA;gBAAA,KAEAP;kBAAA;kBAAA;gBAAA;gBAAA,wBAGA,qBADA+B;gBAEA/B;gBAAA;gBAAA,OACA;cAAA;gBAEAqB;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IACA;IACAW;MACA,2BAEA,cADA5B;QAAAA;MAEA;MACA;MACAiB;MACA;MAQA;IACA;IACAY;MAAA;MACA;MACA;MACA;MACA;MACA;IACA;IACAC;MACA;MACA;MACA;QACA9B;QACAO;MACA;IACA;IACA;IACAwB;MAAA;MACA;MACA;QACA,IACAjD,OACAkD,KADAlD;QAEA;QACAiD;MACA;MACA;MACA;IACA;IACAE;MAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBAEA7B,WACA,OADAA;gBAAA,KAEAA;kBAAA;kBAAA;gBAAA;gBAAA;cAAA;gBAAA,uBAGA,eADAJ;gBAEAkC;kBACAlC;gBACA;gBAAA,KACAkC;kBAAA;kBAAA;gBAAA;gBACA;kBACAC;gBACA;gBAAA;cAAA;gBAAA,KAGA;kBAAA;kBAAA;gBAAA;gBAAA;cAAA;gBACA;gBACA;gBAAA;gBAAA;gBAAA,OAEA;kBACAnC;gBACA;cAAA;gBACA;gBACA;gBACAoC;gBACA;kBACA;oBACAC;oBACA;kBACA;kBACAD;kBACA;gBACA;gBAAA;gBAAA;cAAA;gBAAA;gBAAA;gBAEAE;kBACA;kBACA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IAEA;IACAC;MAAA;MAAA;QAAA;QAAA;UAAA;YAAA;cAAA;gBACAC;gBACAN;gBAAA,KACAA;kBAAA;kBAAA;gBAAA;gBACA;kBACAC;gBACA;gBAAA;cAAA;gBAAA,MAIAK;kBAAA;kBAAA;gBAAA;gBACA;kBACAL;gBACA;gBAAA;cAAA;gBAAA,KAIA;kBAAA;kBAAA;gBAAA;gBAAA;cAAA;gBACA;gBACA;gBAAA;gBAAA;gBAAA,OAEA;cAAA;gBACA;gBACA;gBACA;gBACA;gBAAA;gBAAA,OACA;cAAA;gBACAG;kBACA;gBACA;gBAAA;gBAAA;cAAA;gBAAA;gBAAA;gBAEAA;kBACA;kBACA;gBACA;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA;IAEA;EAAA;AAEA;AAAA,4B;;;;;;;;;;;;;ACpYA;AAAA;AAAA;AAAA;AAAyoC,CAAgB,+mCAAG,EAAC,C;;;;;;;;;;;ACA7pC;AACA,OAAO,KAAU,EAAE,kBAKd","file":"components/auth.js","sourcesContent":["import { render, staticRenderFns, recyclableRender, components } from \"./auth.vue?vue&type=template&id=547ff13a&\"\nvar renderjs\nimport script from \"./auth.vue?vue&type=script&lang=js&\"\nexport * from \"./auth.vue?vue&type=script&lang=js&\"\nimport style0 from \"./auth.vue?vue&type=style&index=0&lang=scss&\"\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 = \"components/auth.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!./auth.vue?vue&type=template&id=547ff13a&\"","var components\nvar render = function () {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\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!./auth.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!./auth.vue?vue&type=script&lang=js&\"","<template>\r\n\t<view style=\"width:100%\">\r\n\t\t<block v-if=\"needAuth\">\r\n\t\t\t<view @tap=\"toShowAuth\">\r\n\t\t\t\t<slot></slot>\r\n\t\t\t</view>\r\n\t\t</block>\r\n\t\t<block v-else>\r\n\t\t\t<view @tap=\"go(1)\">\r\n\t\t\t\t<slot></slot>\r\n\t\t\t</view>\r\n\t\t</block>\r\n\r\n\t\t<uni-popup ref=\"show_auth_item\">\r\n\t\t\t<view class=\"auth-box fill-base flex-column flex-center text-center radius-26\">\r\n\t\t\t\t<view class=\"space-md\"></view>\r\n\t\t\t\t<block v-if=\"pType === 'userInfo'\">\r\n\t\t\t\t\t<view class=\"flex-center pd-lg\">\r\n\t\t\t\t\t\t<view class=\"auth-info\" style=\"overflow: hidden;\">\r\n\t\t\t\t\t\t\t<open-data class=\"auth-info\" type=\"userAvatarUrl\"></open-data>\r\n\t\t\t\t\t\t</view>\r\n\t\t\t\t\t\t<veiw class=\"auth-info flex-center\" style=\"background:white;padding: 0rpx 40rpx;\">\r\n\t\t\t\t\t\t\t<i class=\"iconfont icon-zhuanhuan\" style=\"font-size:40rpx;color:#999\"></i>\r\n\t\t\t\t\t\t</veiw>\r\n\t\t\t\t\t\t<view class=\"auth-info flex-center\" :style=\"{backgroundColor:primaryColor}\">\r\n\t\t\t\t\t\t\t<i class=\"iconfont icon-xiaochengxu c-base\" style=\"font-size:40rpx;\"></i>\r\n\t\t\t\t\t\t</view>\r\n\t\t\t\t\t</view>\r\n\t\t\t\t</block>\r\n\t\t\t\t<block v-if=\"pType == 'phone'\">\r\n\t\t\t\t\t<image class=\"auth-img\" :src=\"`https://lbqny.migugu.com/admin/public/auth.png`\">\r\n\t\t\t\t\t</image>\r\n\t\t\t\t</block>\r\n\t\t\t\t<view class=\"space-sm\"></view>\r\n\t\t\t\t<view class=\"f-caption\" :style=\"{color:primaryColor}\">{{contentList[pType][0]}}</view>\r\n\t\t\t\t<view class=\"space-lg\"></view>\r\n\t\t\t\t<view class=\"space-lg\"></view>\r\n\t\t\t\t<block v-if=\"pType === 'userInfo'\">\r\n\t\t\t\t\t<button @tap.stop=\"authUserProfile\" hover-class=\"btn-hover\" class=\"clear-btn flex-center auth-btn\"\r\n\t\t\t\t\t\t:style=\"{backgroundColor:primaryColor,color:'white'}\">{{btn_text||contentList[pType][1]}}</button>\r\n\t\t\t\t</block>\r\n\t\t\t\t<block v-if=\"pType === 'phone'\">\r\n\t\t\t\t\t<button open-type=\"getPhoneNumber\" hover-class=\"btn-hover\" @getphonenumber=\"authPhone\"\r\n\t\t\t\t\t\tclass=\"clear-btn flex-center auth-btn\" :style=\"{backgroundColor:primaryColor,color:'white'}\">\r\n\t\t\t\t\t\t{{btn_text||contentList[pType][1]}}\r\n\t\t\t\t\t</button>\r\n\t\t\t\t</block>\r\n\t\t\t\t<block v-if=\"pType === 'setting'\">\r\n\t\t\t\t\t<button open-type=\"openSetting\" hover-class=\"btn-hover\" @opensetting=\"openSetting\"\r\n\t\t\t\t\t\tclass=\"clear-btn flex-center auth-btn\" :style=\"{backgroundColor:primaryColor,color:'white'}\">\r\n\t\t\t\t\t\t{{btn_text||contentList[pType][1]}}\r\n\t\t\t\t\t</button>\r\n\t\t\t\t</block>\r\n\t\t\t\t<view @tap=\"go(pType == 'phone' && !userInfo.phone ? 2 : 1)\" class=\"f-caption c-caption mt-md\"\r\n\t\t\t\t\tv-if=\"!must\">{{pType=='userInfo'?'暂不授权':'暂不登录'}}</view>\r\n\t\t\t\t<view class=\"space-md\"></view>\r\n\t\t\t</view>\r\n\t\t</uni-popup>\r\n\r\n\r\n\t\t<uni-popup ref=\"show_phone_item\" :maskClick=\"false\">\r\n\t\t\t<view class=\"common-popup-content popup-phone pd-lg flex-center flex-column fill-base\">\r\n\t\t\t\t<view class=\"f-md-title c-black\">请输入手机号</view>\r\n\t\t\t\t<view class=\"space-lg pb-lg\"></view>\r\n\t\t\t\t<view class=\"space-lg pb-lg\"></view>\r\n\t\t\t\t<view class=\"flex-center mb-lg\">\r\n\t\t\t\t\t<view class=\"input-info sm mr-md radius-16\">\r\n\t\t\t\t\t\t<input v-model=\"subForm.phone\" type=\"number\"\r\n\t\t\t\t\t\t\tclass=\"item-input flex-y-center pl-lg pr-lg f-sm-title c-title\"\r\n\t\t\t\t\t\t\tplaceholder-class=\"c-placeholder\" :placeholder=\"rule[0].errorMsg\" />\r\n\t\t\t\t\t</view>\r\n\t\t\t\t\t<view @tap=\"toSend\" class=\"send-btn flex-center c-base radius-16\"\r\n\t\t\t\t\t\t:style=\"{background:primaryColor}\">\r\n\t\t\t\t\t\t{{authTime>0?`(${authTime}s)`:'发送'}}\r\n\t\t\t\t\t</view>\r\n\t\t\t\t</view>\r\n\t\t\t\t<view class=\"input-info radius-16\">\r\n\t\t\t\t\t<input v-model=\"subForm.short_code\" type=\"number\"\r\n\t\t\t\t\t\tclass=\"item-input flex-y-center pl-lg pr-lg f-sm-title c-title\" maxlength=\"6\"\r\n\t\t\t\t\t\tplaceholder-class=\"c-placeholder\" :placeholder=\"rule[1].errorMsg\" />\r\n\t\t\t\t</view>\r\n\t\t\t\t<view class=\"button\">\r\n\t\t\t\t\t<view @tap.stop=\"go(3)\" class=\"item-child\">\r\n\t\t\t\t\t\t取消\r\n\t\t\t\t\t</view>\r\n\t\t\t\t\t<view @tap.stop=\"submit\" class=\"item-child\" :style=\"{background: primaryColor,color:'#fff'}\">\r\n\t\t\t\t\t\t确定\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</uni-popup>\r\n\r\n\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\tname: 'auth',\r\n\t\tprops: {\r\n\t\t\tneedAuth: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn false\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tmust: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn false\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tuserMust: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn true\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tshowAuth: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn false\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\ttype: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn 'phone'\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tbtn_text: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault () {\r\n\t\t\t\t\treturn ''\r\n\t\t\t\t}\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\tconfigInfo: state => state.config.configInfo,\r\n\t\t\tcommonOptions: state => state.user.commonOptions,\r\n\t\t\tuserInfo: state => state.user.userInfo,\r\n\t\t}),\r\n\t\tcreated() {\r\n\t\t\tthis.init();\r\n\t\t},\r\n\t\tdata() {\r\n\t\t\treturn {\r\n\t\t\t\tcontentList: {\r\n\t\t\t\t\tuserInfo: ['尊贵的用户,获取授权是为了能更好的为你服务', '立即授权'],\r\n\t\t\t\t\tphone: ['尊贵的用户,登录后我们才能更好的为你服务', '立即登录'],\r\n\t\t\t\t\tsetting: ['为了功能正常使用,你需要打开设置并开启获取相应权限', '打开设置'],\r\n\t\t\t\t},\r\n\t\t\t\tpType: '',\r\n\t\t\t\tpMust: '',\r\n\t\t\t\tauthTime: 0,\r\n\t\t\t\ttimer: null,\r\n\t\t\t\tsubForm: {\r\n\t\t\t\t\tphone: '',\r\n\t\t\t\t\tshort_code: ''\r\n\t\t\t\t},\r\n\t\t\t\trule: [{\r\n\t\t\t\t\tname: \"phone\",\r\n\t\t\t\t\tcheckType: \"isMobile\",\r\n\t\t\t\t\terrorMsg: \"请输入手机号\",\r\n\t\t\t\t\tregText: \"手机号\"\r\n\t\t\t\t}, {\r\n\t\t\t\t\tname: \"short_code\",\r\n\t\t\t\t\tcheckType: \"isNotNull\",\r\n\t\t\t\t\terrorMsg: \"请输入短信验证码\",\r\n\t\t\t\t\tregText: \"短信验证码\"\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\tmethods: {\r\n\t\t\t...mapActions(['getUserInfo', 'getAuthUserProfile', 'getAuthPhone', ]),\r\n\t\t\tinit() {\r\n\t\t\t\tlet {\r\n\t\t\t\t\ttype,\r\n\t\t\t\t\tmust,\r\n\t\t\t\t\tshowAuth\r\n\t\t\t\t} = this\r\n\t\t\t\tthis.$set(this, 'pType', type)\r\n\t\t\t\tthis.$set(this, 'pMust', must)\r\n\t\t\t\tif (!showAuth) return\r\n\t\t\t\tthis.$refs.show_auth_item.open()\r\n\t\t\t},\r\n\t\t\tasync authPhone(e) {\r\n\t\t\t\tlet {\r\n\t\t\t\t\tpMust\r\n\t\t\t\t} = this\r\n\t\t\t\tlet phone = await this.getAuthPhone({\r\n\t\t\t\t\te,\r\n\t\t\t\t})\r\n\t\t\t\tconsole.log(pMust, phone, \"===== pMust auth_phone\");\r\n\t\t\t\tif (!phone) {\r\n\t\t\t\t\tthis.go(pMust ? 2 : 1)\r\n\t\t\t\t\treturn false\r\n\t\t\t\t} else {\r\n\t\t\t\t\tthis.$set(this, 'pType', 'userInfo')\r\n\t\t\t\t\tthis.$set(this, 'pMust', this.userMust)\r\n\t\t\t\t\tconsole.log(this.PType, this.pMust, \"====auth_to_userInfo\");\r\n\t\t\t\t\tif (!this.pMust) return\r\n\t\t\t\t\tthis.$refs.show_auth_item.open()\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tasync authUserProfile(e) {\r\n\t\t\t\t// #ifdef APP-PLUS\r\n\t\t\t\tuni.getUserInfo({\r\n\t\t\t\t\tprovider: 'weixin',\r\n\t\t\t\t\tsuccess: res => {\r\n\t\t\t\t\t\tlet {\r\n\t\t\t\t\t\t\tuserInfo = {}\r\n\t\t\t\t\t\t} = res\r\n\t\t\t\t\t\tthis.toUpdateUserInfo(userInfo)\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\t// #ifndef APP-PLUS\r\n\t\t\t\tuni.getUserProfile({\r\n\t\t\t\t\tdesc: '用于完善个人资料', // 声明获取用户个人信息后的用途,后续会展示在弹窗中,请谨慎填写\r\n\t\t\t\t\tsuccess: (res) => {\r\n\t\t\t\t\t\tlet {\r\n\t\t\t\t\t\t\tuserInfo = {},\r\n\t\t\t\t\t\t\t\tencryptedData,\r\n\t\t\t\t\t\t\t\tiv,\r\n\t\t\t\t\t\t} = res\r\n\t\t\t\t\t\tlet param = Object.assign({}, userInfo, {\r\n\t\t\t\t\t\t\tencryptedData,\r\n\t\t\t\t\t\t\tiv,\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\tthis.toUpdateUserInfo(param)\r\n\t\t\t\t\t},\r\n\t\t\t\t\tfail: (res) => {\r\n\t\t\t\t\t\tconsole.log(res, \"=====fail\");\r\n\t\t\t\t\t\tthis.toUpdateUserInfo()\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},\r\n\t\t\tasync toUpdateUserInfo(userInfo = {}) {\r\n\t\t\t\tlet {\r\n\t\t\t\t\tpMust\r\n\t\t\t\t} = this\r\n\t\t\t\tif (userInfo.nickName) {\r\n\t\t\t\t\tlet {\r\n\t\t\t\t\t\tcoupon_atv_id = 0\r\n\t\t\t\t\t} = this.commonOptions\r\n\t\t\t\t\tuserInfo.coupon_atv_id = coupon_atv_id\r\n\t\t\t\t\tawait this.getAuthUserProfile(userInfo)\r\n\t\t\t\t}\r\n\t\t\t\tconsole.log(pMust, userInfo, \"===== pMust auth_userinfo\");\r\n\t\t\t\tthis.go(pMust && !userInfo.nickName ? 2 : 1);\r\n\t\t\t},\r\n\t\t\ttoShowAuth() {\r\n\t\t\t\tlet {\r\n\t\t\t\t\tphone = ''\r\n\t\t\t\t} = this.userInfo\r\n\t\t\t\tlet type = !phone ? 'phone' : 'userInfo'\r\n\t\t\t\tthis.$set(this, 'pType', type)\r\n\t\t\t\tconsole.log(this.userInfo, phone, this.pType, \"=====toShowAuth\")\r\n\t\t\t\tlet refs_key = 'show_auth_item'\r\n\t\t\t\t// #ifndef MP-WEIXIN\r\n\t\t\t\trefs_key = 'show_phone_item'\r\n\t\t\t\tif (this.configInfo.short_code_status * 1 == 0) {\r\n\t\t\t\t\tthis.go(1)\r\n\t\t\t\t\treturn\r\n\t\t\t\t}\r\n\t\t\t\t// #endif\r\n\t\t\t\tthis.$refs[refs_key].open()\r\n\t\t\t},\r\n\t\t\tgo(type = 1) {\r\n\t\t\t\tthis.lockTap = false\r\n\t\t\t\tthis.$emit(type == 1 ? 'go' : 'hide')\r\n\t\t\t\tlet refs_key = type == 3 ? 'show_phone_item' : 'show_auth_item'\r\n\t\t\t\tthis.$refs[refs_key].close();\r\n\t\t\t\tthis.toResetItem()\r\n\t\t\t},\r\n\t\t\ttoResetItem() {\r\n\t\t\t\tthis.timer && clearTimeout(this.timer)\r\n\t\t\t\tthis.authTime = 0\r\n\t\t\t\tthis.subForm = {\r\n\t\t\t\t\tphone: '',\r\n\t\t\t\t\tshort_code: ''\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\t//表单验证\r\n\t\t\tvalidate(param, is_send = false) {\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\tif (name == 'short_code' && is_send) return\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 toSend() {\r\n\t\t\t\tlet {\r\n\t\t\t\t\tauthTime\r\n\t\t\t\t} = this\r\n\t\t\t\tif (authTime) return\r\n\t\t\t\tlet {\r\n\t\t\t\t\tphone = ''\r\n\t\t\t\t} = this.subForm\r\n\t\t\t\tlet msg = this.validate({\r\n\t\t\t\t\tphone\r\n\t\t\t\t}, true);\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\tthis.$util.showLoading()\r\n\t\t\t\ttry {\r\n\t\t\t\t\tawait this.$api.user.sendShortMsg({\r\n\t\t\t\t\t\tphone\r\n\t\t\t\t\t})\r\n\t\t\t\t\tthis.$util.hideAll()\r\n\t\t\t\t\tthis.lockTap = false\r\n\t\t\t\t\tlet time = 60\r\n\t\t\t\t\tthis.timer = setInterval(() => {\r\n\t\t\t\t\t\tif (time === 0) {\r\n\t\t\t\t\t\t\tclearTimeout(this.timer)\r\n\t\t\t\t\t\t\treturn\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\ttime--\r\n\t\t\t\t\t\tthis.authTime = time\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\t\t\t},\r\n\t\t\tasync submit() {\r\n\t\t\t\tlet param = this.$util.deepCopy(this.subForm)\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\r\n\t\t\t\tif (param.short_code.length != 6) {\r\n\t\t\t\t\tthis.$util.showToast({\r\n\t\t\t\t\t\ttitle: `请输入6位数短信验证码`\r\n\t\t\t\t\t})\r\n\t\t\t\t\treturn\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (this.lockTap) return\r\n\t\t\t\tthis.lockTap = true\r\n\t\t\t\tthis.$util.showLoading()\r\n\t\t\t\ttry {\r\n\t\t\t\t\tawait this.$api.user.bindUserPhone(param)\r\n\t\t\t\t\tthis.$util.hideAll()\r\n\t\t\t\t\tthis.lockTap = false\r\n\t\t\t\t\tthis.$refs.show_phone_item.close()\r\n\t\t\t\t\tthis.toResetItem()\r\n\t\t\t\t\tawait this.getUserInfo()\r\n\t\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t\tthis.$emit('go')\r\n\t\t\t\t\t}, 500)\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\t\t\t}\r\n\t\t},\r\n\t}\r\n</script>\r\n\r\n\r\n\r\n<style lang=\"scss\">\r\n\t.auth-box {\r\n\t\twidth: 630rpx;\r\n\t\theight: auto;\r\n\t\tpadding: 30rpx;\r\n\r\n\t\t.auth-img {\r\n\t\t\twidth: 322rpx;\r\n\t\t\theight: 341rpx;\r\n\t\t\t/* background: #f4f6f8; */\r\n\t\t}\r\n\r\n\t\t.auth-btn {\r\n\t\t\twidth: 367rpx;\r\n\t\t\theight: 90rpx;\r\n\t\t\tborder-radius: 90rpx;\r\n\t\t}\r\n\r\n\t\t.auth-info {\r\n\t\t\twidth: 80rpx;\r\n\t\t\theight: 80rpx;\r\n\t\t\tbackground: #f4f6f8;\r\n\t\t\tborder-radius: 50%;\r\n\t\t}\r\n\r\n\t}\r\n\r\n\r\n\t.popup-phone {\r\n\t\twidth: 630rpx;\r\n\r\n\t\t.input-info {\r\n\t\t\twidth: 570rpx;\r\n\t\t\theight: 90rpx;\r\n\t\t\tbackground: #F7F7F7;\r\n\r\n\t\t\t.item-input {\r\n\t\t\t\theight: 90rpx;\r\n\t\t\t\tfont-size: 32rpx;\r\n\t\t\t\ttext-align: left;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t.input-info.sm {\r\n\t\t\twidth: 400rpx;\r\n\t\t}\r\n\r\n\t\t.send-btn {\r\n\t\t\twidth: 150rpx;\r\n\t\t\theight: 90rpx;\r\n\t\t}\r\n\t}\r\n</style>\r\n","import mod from \"-!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!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!./auth.vue?vue&type=style&index=0&lang=scss&\"; export default mod; export * from \"-!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!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!./auth.vue?vue&type=style&index=0&lang=scss&\"","// extracted by mini-css-extract-plugin\n if(module.hot) {\n // 1693645334147\n var cssReload = require(\"D:/HBuilderX/plugins/uniapp-cli/node_modules/mini-css-extract-plugin/dist/hmr/hotModuleReplacement.js\")(module.id, {\"hmr\":true,\"publicPath\":\"../../\",\"locals\":false});\n module.hot.dispose(cssReload);\n module.hot.accept(undefined, cssReload);\n }\n "],"sourceRoot":""}