index.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852
  1. <template>
  2. <view class="login-wrapper" :style="colorStyle">
  3. <view class="shading">
  4. <image :src="logoUrl" />
  5. </view>
  6. <view class="whiteBg" v-if="formItem === 1">
  7. <view class="list" v-if="current !== 1">
  8. <form @submit.prevent="submit">
  9. <view class="item">
  10. <view class="acea-row row-middle">
  11. <image src="../static/phone_1.png" style="width: 24rpx; height: 34rpx;"></image>
  12. <input type="text" :placeholder="$t(`输入手机号码`)" v-model="account" maxlength="11" required />
  13. </view>
  14. </view>
  15. <view class="item">
  16. <view class="acea-row row-middle">
  17. <image src="../static/code_1.png" style="width: 28rpx; height: 32rpx;"></image>
  18. <input type="password" :placeholder="$t(`填写登录密码`)" v-model="password" required />
  19. </view>
  20. </view>
  21. </form>
  22. <!-- <navigator class="forgetPwd" hover-class="none" url="/pages/users/retrievePassword/index">
  23. <span class="iconfont icon-wenti"></span>忘记密码
  24. </navigator> -->
  25. </view>
  26. <view class="list" v-if="current !== 0 || appLoginStatus || appleLoginStatus">
  27. <view class="item">
  28. <view class="acea-row row-middle">
  29. <image src="../static/phone_1.png" style="width: 24rpx; height: 34rpx;"></image>
  30. <input type="text" :placeholder="$t(`输入手机号码`)" v-model="account" :maxlength="11" />
  31. </view>
  32. </view>
  33. <view class="item">
  34. <view class="acea-row row-middle">
  35. <image src="../static/code_2.png" style="width: 28rpx; height: 32rpx;"></image>
  36. <input type="text" :placeholder="$t(`填写验证码`)" :maxlength="6" class="codeIput"
  37. v-model="captcha" />
  38. <button class="code" :disabled="disabled" :class="disabled === true ? 'on' : ''" @click="code">
  39. {{ text }}
  40. </button>
  41. </view>
  42. </view>
  43. <!-- <view class="item" v-if="isShowCode">
  44. <view class="acea-row row-middle">
  45. <image src="../static/code_2.png" style="width: 28rpx; height: 32rpx;"></image>
  46. <input type="text" :placeholder="$t(`填写验证码`)" class="codeIput" v-model="codeVal" />
  47. <view class="code" @click="again"><img :src="codeUrl" /></view>
  48. </view>
  49. </view> -->
  50. </view>
  51. <view class="logon" @click="loginMobile" v-if="current !== 0">{{$t(`登录`)}}</view>
  52. <view class="logon" @click="submit" v-if="current === 0">{{$t(`登录`)}}</view>
  53. <!-- #ifndef APP-PLUS -->
  54. <view class="tips">
  55. <view v-if="current==0" @click="current = 1">{{$t(`快速登录`)}}</view>
  56. <view v-if="current==1" @click="current = 0">{{$t(`账号登录`)}}</view>
  57. </view>
  58. <!-- #endif -->
  59. <!-- #ifdef APP-PLUS -->
  60. <view class="tips">
  61. <view v-if="current==0" @click="current = 1">{{$t(`快速登录`)}}</view>
  62. <view v-if="current==1" @click="current = 0">{{$t(`账号登录`)}}</view>
  63. </view>
  64. <!-- <view class="appLogin" v-if="!appLoginStatus && !appleLoginStatus">
  65. <view class="hds">
  66. <span class="line"></span>
  67. <p>{{$t(`其他方式登录`)}}</p>
  68. <span class="line"></span>
  69. </view>
  70. <view class="btn-wrapper">
  71. <view class="btn wx" @click="wxLogin">
  72. <span class="iconfont icon-s-weixindenglu1"></span>
  73. </view>
  74. <view class="btn mima" v-if="current == 1" @click="current =0">
  75. <span class="iconfont icon-s-mimadenglu1"></span>
  76. </view>
  77. <view class="btn yanzheng" v-if="current == 0" @click="current =1">
  78. <span class="iconfont icon-s-yanzhengmadenglu1"></span>
  79. </view>
  80. <view class="apple-btn" @click="appleLogin" v-if="appleShow">
  81. <view class="iconfont icon-s-pingguo"></view>
  82. </view>
  83. </view>
  84. </view> -->
  85. <!-- #endif -->
  86. <view class="protocol">
  87. <checkbox-group @change='ChangeIsDefault'>
  88. <checkbox :class="inAnimation?'trembling':''" @animationend='inAnimation=false'
  89. :checked="protocol ? true : false" />{{$t(`已阅读并同意`)}} <text class="main-color"
  90. @click="privacy(4)">{{$t(`《用户协议》`)}}</text>
  91. {{$t(`与`)}}<text class="main-color" @click="privacy(3)">{{$t(`《隐私协议》`)}}</text>
  92. </checkbox-group>
  93. </view>
  94. </view>
  95. <!-- <view class="bottom">
  96. <view class="ver" v-if="copyRight">{{copyRight}}</view>
  97. <view v-else class="ver">© 2014-2023
  98. <a href="https://www.crmeb.com">www.crmeb.com</a>
  99. </view>
  100. </view> -->
  101. <Verify @success="success" :captchaType="captchaType" :imgSize="{ width: '330px', height: '155px' }"
  102. ref="verify"></Verify>
  103. </view>
  104. </template>
  105. <script>
  106. import dayjs from "@/plugin/dayjs/dayjs.min.js";
  107. import sendVerifyCode from "@/mixins/SendVerifyCode";
  108. import {
  109. loginH5,
  110. loginMobile,
  111. registerVerify,
  112. register,
  113. getCodeApi,
  114. getUserInfo,
  115. appleLogin
  116. } from "@/api/user";
  117. import attrs, {
  118. required,
  119. alpha_num,
  120. chs_phone
  121. } from "@/utils/validate";
  122. import {
  123. getLogo
  124. } from "@/api/public";
  125. // import cookie from "@/utils/store/cookie";
  126. import {
  127. VUE_APP_API_URL
  128. } from "@/utils";
  129. // #ifdef APP-PLUS
  130. import {
  131. wechatAppAuth
  132. } from '@/api/api.js'
  133. // #endif
  134. const BACK_URL = "login_back_url";
  135. import colors from '@/mixins/color.js';
  136. import Verify from '../components/verify/index.vue';
  137. export default {
  138. name: "Login",
  139. components: {
  140. Verify
  141. },
  142. mixins: [sendVerifyCode, colors],
  143. data: function() {
  144. return {
  145. copyRight: '',
  146. inAnimation: false,
  147. protocol: false,
  148. navList: [this.$t(`快速登录`), this.$t(`账号登录`)],
  149. current: 1,
  150. account: "",
  151. password: "",
  152. captcha: "",
  153. formItem: 1,
  154. type: "login",
  155. logoUrl: "",
  156. keyCode: "",
  157. codeUrl: "",
  158. codeVal: "",
  159. isShowCode: false,
  160. appLoginStatus: false, // 微信登录强制绑定手机号码状态
  161. appUserInfo: null, // 微信登录保存的用户信息
  162. appleLoginStatus: false, // 苹果登录强制绑定手机号码状态
  163. appleUserInfo: null,
  164. appleShow: false, // 苹果登录版本必须要求ios13以上的
  165. keyLock: true
  166. };
  167. },
  168. watch: {
  169. formItem: function(nval, oVal) {
  170. if (nval == 1) {
  171. this.type = 'login'
  172. } else {
  173. this.type = 'register'
  174. }
  175. }
  176. },
  177. onLoad() {
  178. let self = this
  179. uni.getSystemInfo({
  180. success: (res) => {
  181. if (res.platform.toLowerCase() == 'ios' && this.getSystem(res.system)) {
  182. self.appleShow = true
  183. }
  184. }
  185. });
  186. if (uni.getStorageSync('copyRight').copyrightContext) {
  187. this.copyRight = uni.getStorageSync('copyRight').copyrightContext
  188. }
  189. },
  190. mounted() {
  191. // this.getCode();
  192. this.getLogoImage();
  193. },
  194. methods: {
  195. ChangeIsDefault(e) {
  196. this.$set(this, 'protocol', !this.protocol);
  197. },
  198. privacy(type) {
  199. uni.navigateTo({
  200. url: "/pages/users/privacy/index?type=" + type
  201. })
  202. },
  203. // IOS 版本号判断
  204. getSystem(system) {
  205. let str
  206. system.toLowerCase().indexOf('ios') === -1 ? str = system : str = system.split(' ')[1]
  207. if (str.indexOf('.'))
  208. return str.split('.')[0] >= 13
  209. return str >= 13
  210. },
  211. // 苹果登录
  212. appleLogin() {
  213. let self = this
  214. this.account = ''
  215. this.captcha = ''
  216. if (!self.protocol) {
  217. this.inAnimation = true
  218. return self.$util.Tips({
  219. title: '请先阅读并同意协议'
  220. });
  221. }
  222. uni.showLoading({
  223. title: this.$t(`登录中`)
  224. })
  225. uni.login({
  226. provider: 'apple',
  227. timeout: 10000,
  228. success(loginRes) {
  229. uni.getUserInfo({
  230. provider: 'apple',
  231. success: function(infoRes) {
  232. self.appleUserInfo = infoRes.userInfo
  233. self.appleLoginApi()
  234. },
  235. fail() {
  236. uni.showToast({
  237. title: self.$t(`获取用户信息失败`),
  238. icon: 'none',
  239. duration: 2000
  240. })
  241. },
  242. complete() {
  243. uni.hideLoading()
  244. }
  245. });
  246. },
  247. fail(error) {
  248. console.log(error)
  249. }
  250. })
  251. },
  252. // 苹果登录Api
  253. appleLoginApi() {
  254. let self = this
  255. appleLogin({
  256. openId: self.appleUserInfo.openId,
  257. email: self.appleUserInfo.email || '',
  258. phone: this.account,
  259. captcha: this.captcha
  260. }).then(({
  261. data
  262. }) => {
  263. if (data.isbind) {
  264. uni.showModal({
  265. title: self.$t(`提示`),
  266. content: self.$t(`请绑定手机号后,继续操作`),
  267. showCancel: false,
  268. success: function(res) {
  269. if (res.confirm) {
  270. self.current = 1
  271. self.appleLoginStatus = true
  272. }
  273. }
  274. });
  275. } else {
  276. self.$store.commit("LOGIN", {
  277. 'token': data.token,
  278. 'time': data.expires_time - self.$Cache.time()
  279. });
  280. let backUrl = self.$Cache.get(BACK_URL) || "/pages/index/index";
  281. self.$Cache.clear(BACK_URL);
  282. self.$store.commit("SETUID", data.userInfo.uid);
  283. uni.reLaunch({
  284. url: backUrl
  285. });
  286. }
  287. }).catch(error => {
  288. uni.showModal({
  289. title: self.$t(`提示`),
  290. content: self.$t(`错误信息`) + `${error}`,
  291. success: function(res) {
  292. if (res.confirm) {
  293. console.log(self.$t(`用户点击确定`));
  294. } else if (res.cancel) {
  295. console.log(self.$t(`用户点击取消`));
  296. }
  297. }
  298. });
  299. })
  300. },
  301. // App微信登录
  302. wxLogin() {
  303. let self = this
  304. this.account = ''
  305. this.captcha = ''
  306. if (!self.protocol) {
  307. this.inAnimation = true
  308. return self.$util.Tips({
  309. title: '请先阅读并同意协议'
  310. });
  311. }
  312. uni.showLoading({
  313. title: self.$t(`登录中`)
  314. })
  315. uni.login({
  316. provider: 'weixin',
  317. success: function(loginRes) {
  318. // 获取用户信息
  319. uni.getUserInfo({
  320. provider: 'weixin',
  321. success: function(infoRes) {
  322. self.appUserInfo = infoRes.userInfo
  323. self.wxLoginApi()
  324. },
  325. fail() {
  326. uni.showToast({
  327. title: self.$t(`获取用户信息失败`),
  328. icon: 'none',
  329. duration: 2000
  330. })
  331. },
  332. complete() {
  333. uni.hideLoading()
  334. }
  335. });
  336. },
  337. fail() {
  338. uni.showToast({
  339. title: self.$t(`登录失败`),
  340. icon: 'none',
  341. duration: 2000
  342. })
  343. }
  344. });
  345. },
  346. wxLoginApi() {
  347. let self = this
  348. wechatAppAuth({
  349. userInfo: self.appUserInfo,
  350. phone: this.account,
  351. code: this.captcha
  352. }).then(({
  353. data
  354. }) => {
  355. if (data.isbind) {
  356. uni.showModal({
  357. title: self.$t(`提示`),
  358. content: self.$t(`请绑定手机号后,继续操作`),
  359. showCancel: false,
  360. success: function(res) {
  361. if (res.confirm) {
  362. self.current = 1
  363. self.appLoginStatus = true
  364. }
  365. }
  366. });
  367. } else {
  368. self.$store.commit("LOGIN", {
  369. 'token': data.token,
  370. 'time': data.expires_time - self.$Cache.time()
  371. });
  372. let backUrl = self.$Cache.get(BACK_URL) || "/pages/index/index";
  373. self.$Cache.clear(BACK_URL);
  374. self.$store.commit("SETUID", data.userInfo.uid);
  375. uni.reLaunch({
  376. url: backUrl
  377. });
  378. }
  379. }).catch(error => {
  380. uni.showModal({
  381. title: self.$t(`提示`),
  382. content: self.$t(`错误信息`) + `${error}`,
  383. success: function(res) {
  384. if (res.confirm) {
  385. console.log(self.$t(`用户点击确定`));
  386. } else if (res.cancel) {
  387. console.log(self.$t(`用户点击取消`));
  388. }
  389. }
  390. });
  391. })
  392. },
  393. again() {
  394. this.codeUrl =
  395. VUE_APP_API_URL +
  396. "/sms_captcha?" +
  397. "key=" +
  398. this.keyCode +
  399. Date.parse(new Date());
  400. },
  401. success(data) {
  402. this.$refs.verify.hide()
  403. getCodeApi()
  404. .then(res => {
  405. this.keyCode = res.data.key;
  406. this.getCode(data);
  407. })
  408. .catch(res => {
  409. this.$util.Tips({
  410. title: res
  411. });
  412. });
  413. },
  414. code() {
  415. let that = this
  416. if (!that.protocol) {
  417. this.inAnimation = true
  418. return that.$util.Tips({
  419. title: '请先阅读并同意协议'
  420. });
  421. }
  422. if (!that.account) return that.$util.Tips({
  423. title: that.$t(`请填写手机号码`)
  424. });
  425. if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.account)) return that.$util.Tips({
  426. title: that.$t(`请输入正确的手机号码`)
  427. });
  428. this.$refs.verify.show()
  429. },
  430. async getLogoImage() {
  431. let that = this;
  432. getLogo(2).then(res => {
  433. that.logoUrl = res.data.logo_url;
  434. });
  435. },
  436. async loginMobile() {
  437. let that = this;
  438. if (!that.protocol) {
  439. this.inAnimation = true
  440. return that.$util.Tips({
  441. title: '请先阅读并同意协议'
  442. });
  443. }
  444. if (!that.account) return that.$util.Tips({
  445. title: that.$t(`请填写手机号码`)
  446. });
  447. if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.account)) return that.$util.Tips({
  448. title: that.$t(`请输入正确的手机号码`)
  449. });
  450. if (!that.captcha) return that.$util.Tips({
  451. title: that.$t(`请填写验证码`)
  452. });
  453. if (!/^[\w\d]+$/i.test(that.captcha)) return that.$util.Tips({
  454. title: that.$t(`请输入正确的验证码`)
  455. });
  456. if (that.appLoginStatus) {
  457. that.wxLoginApi()
  458. } else if (that.appleLoginStatus) {
  459. that.appleLoginApi()
  460. } else {
  461. if (this.keyLock) {
  462. this.keyLock = !this.keyLock
  463. } else {
  464. return that.$util.Tips({
  465. title: that.$t(`请勿重复点击`)
  466. });
  467. }
  468. loginMobile({
  469. phone: that.account,
  470. captcha: that.captcha,
  471. spread: that.$Cache.get("spread")
  472. })
  473. .then(res => {
  474. let data = res.data;
  475. that.$store.commit("LOGIN", {
  476. 'token': data.token,
  477. 'time': data.expires_time - this.$Cache.time()
  478. });
  479. let backUrl = that.$Cache.get(BACK_URL) || "/pages/index/index";
  480. that.$Cache.clear(BACK_URL);
  481. getUserInfo().then(res => {
  482. this.keyLock = true
  483. that.$store.commit("SETUID", res.data.uid);
  484. if (backUrl.indexOf('/pages/users/login/index') !== -1) {
  485. backUrl = '/pages/index/index';
  486. }
  487. uni.reLaunch({
  488. url: backUrl
  489. });
  490. })
  491. })
  492. .catch(res => {
  493. this.keyLock = true
  494. that.$util.Tips({
  495. title: res
  496. });
  497. });
  498. }
  499. },
  500. async register() {
  501. let that = this;
  502. if (!that.protocol) {
  503. this.inAnimation = true
  504. return that.$util.Tips({
  505. title: '请先阅读并同意协议'
  506. });
  507. }
  508. if (!that.account) return that.$util.Tips({
  509. title: that.$t(`请填写手机号码`)
  510. });
  511. if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.account)) return that.$util.Tips({
  512. title: that.$t(`请输入正确的手机号码`)
  513. });
  514. if (!that.captcha) return that.$util.Tips({
  515. title: that.$t(`请填写验证码`)
  516. });
  517. if (!/^[\w\d]+$/i.test(that.captcha)) return that.$util.Tips({
  518. title: that.$t(`请输入正确的验证码`)
  519. });
  520. if (!that.password) return that.$util.Tips({
  521. title: that.$t(`请填写密码`)
  522. });
  523. if (/^([0-9]|[a-z]|[A-Z]){0,6}$/i.test(that.password)) return that.$util.Tips({
  524. title: that.$t(`您输入的密码过于简单`)
  525. });
  526. register({
  527. account: that.account,
  528. captcha: that.captcha,
  529. password: that.password,
  530. spread: that.$Cache.get("spread")
  531. })
  532. .then(res => {
  533. that.$util.Tips({
  534. title: res
  535. });
  536. that.formItem = 1;
  537. })
  538. .catch(res => {
  539. that.$util.Tips({
  540. title: res
  541. });
  542. });
  543. },
  544. async getCode(data) {
  545. let that = this;
  546. if (!that.protocol) {
  547. this.inAnimation = true
  548. return that.$util.Tips({
  549. title: '请先阅读并同意协议'
  550. });
  551. }
  552. if (!that.account) return that.$util.Tips({
  553. title: that.$t(`请填写手机号码`)
  554. });
  555. if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(that.account)) return that.$util.Tips({
  556. title: that.$t(`请输入正确的手机号码`)
  557. });
  558. if (that.formItem == 2) that.type = "register";
  559. await registerVerify({
  560. phone: that.account,
  561. type: that.type,
  562. key: that.keyCode,
  563. captchaType: this.captchaType,
  564. captchaVerification: data.captchaVerification
  565. })
  566. .then(res => {
  567. this.sendCode()
  568. that.$util.Tips({
  569. title: res.msg
  570. });
  571. })
  572. .catch(res => {
  573. that.$util.Tips({
  574. title: res
  575. });
  576. });
  577. },
  578. navTap: function(index) {
  579. this.current = index;
  580. },
  581. async submit() {
  582. let that = this;
  583. if (!that.protocol) {
  584. this.inAnimation = true
  585. return that.$util.Tips({
  586. title: '请先阅读并同意协议'
  587. });
  588. }
  589. if (!that.account) return that.$util.Tips({
  590. title: that.$t(`请填写账号`)
  591. });
  592. if (!/^[\w\d]{5,16}$/i.test(that.account)) return that.$util.Tips({
  593. title: that.$t(`请输入正确的账号`)
  594. });
  595. if (!that.password) return that.$util.Tips({
  596. title: that.$t(`请填写密码`)
  597. });
  598. if (this.keyLock) {
  599. this.keyLock = !this.keyLock
  600. } else {
  601. return that.$util.Tips({
  602. title: that.$t(`请勿重复点击`)
  603. });
  604. }
  605. loginH5({
  606. account: that.account,
  607. password: that.password,
  608. spread: that.$Cache.get("spread")
  609. })
  610. .then(({
  611. data
  612. }) => {
  613. that.$store.commit("LOGIN", {
  614. 'token': data.token,
  615. 'time': data.expires_time - this.$Cache.time()
  616. });
  617. let backUrl = that.$Cache.get(BACK_URL) || "/pages/index/index";
  618. that.$Cache.clear(BACK_URL);
  619. getUserInfo().then(res => {
  620. this.keyLock = true
  621. that.$store.commit("SETUID", res.data.uid);
  622. uni.reLaunch({
  623. url: backUrl
  624. });
  625. }).catch(error => {
  626. this.keyLock = true
  627. })
  628. })
  629. .catch(e => {
  630. this.keyLock = true
  631. that.$util.Tips({
  632. title: e
  633. });
  634. });
  635. }
  636. }
  637. };
  638. </script>
  639. <style>
  640. page {
  641. background: #fff;
  642. }
  643. </style>
  644. <style lang="scss">
  645. .appLogin {
  646. margin-top: 60rpx;
  647. .hds {
  648. display: flex;
  649. justify-content: center;
  650. align-items: center;
  651. font-size: 24rpx;
  652. color: #B4B4B4;
  653. .line {
  654. width: 68rpx;
  655. height: 1rpx;
  656. background: #CCCCCC;
  657. }
  658. p {
  659. margin: 0 20rpx;
  660. }
  661. }
  662. .btn-wrapper {
  663. display: flex;
  664. align-items: center;
  665. justify-content: center;
  666. margin-top: 30rpx;
  667. .btn {
  668. display: flex;
  669. align-items: center;
  670. justify-content: center;
  671. width: 68rpx;
  672. height: 68rpx;
  673. border-radius: 50%;
  674. }
  675. .apple-btn {
  676. display: flex;
  677. align-items: center;
  678. justify-content: center;
  679. width: 68rpx;
  680. height: 68rpx;
  681. border-radius: 50%;
  682. background: #000;
  683. .icon-s-pingguo {
  684. color: #fff;
  685. font-size: 44rpx;
  686. }
  687. }
  688. .iconfont {
  689. font-size: 40rpx;
  690. color: #fff;
  691. }
  692. .wx {
  693. margin-right: 30rpx;
  694. background-color: #61C64F;
  695. }
  696. .mima {
  697. margin-right: 30rpx;
  698. background-color: #28B3E9;
  699. }
  700. .yanzheng {
  701. margin-right: 30rpx;
  702. background-color: #F89C23;
  703. }
  704. }
  705. }
  706. .code img {
  707. width: 100%;
  708. height: 100%;
  709. }
  710. .acea-row.row-middle {
  711. input {
  712. margin-left: 20rpx;
  713. display: block;
  714. }
  715. }
  716. .login-wrapper {
  717. padding: 30rpx;
  718. .shading {
  719. display: flex;
  720. align-items: center;
  721. justify-content: center;
  722. width: 100%;
  723. /* #ifdef APP-VUE */
  724. margin-top: 50rpx;
  725. /* #endif */
  726. /* #ifndef APP-VUE */
  727. margin-top: 200rpx;
  728. /* #endif */
  729. image {
  730. width: 240rpx;
  731. height: 240rpx;
  732. }
  733. }
  734. .whiteBg {
  735. margin-top: 100rpx;
  736. .list {
  737. border-radius: 16rpx;
  738. overflow: hidden;
  739. .item {
  740. border-bottom: 1px solid #F0F0F0;
  741. background: #fff;
  742. .row-middle {
  743. position: relative;
  744. padding: 16rpx 45rpx;
  745. input {
  746. flex: 1;
  747. font-size: 28rpx;
  748. height: 80rpx;
  749. }
  750. .code {
  751. position: absolute;
  752. right: 30rpx;
  753. top: 50%;
  754. color: var(--view-theme);
  755. font-size: 26rpx;
  756. transform: translateY(-50%);
  757. }
  758. }
  759. }
  760. }
  761. .logon {
  762. display: flex;
  763. align-items: center;
  764. justify-content: center;
  765. width: 100%;
  766. height: 86rpx;
  767. margin-top: 80rpx;
  768. background-color: var(--view-theme);
  769. border-radius: 120rpx;
  770. color: #FFFFFF;
  771. font-size: 30rpx;
  772. }
  773. .tips {
  774. margin: 30rpx;
  775. text-align: center;
  776. color: #999;
  777. }
  778. }
  779. }
  780. .protocol {
  781. margin-top: 40rpx;
  782. color: #999999;
  783. font-size: 24rpx;
  784. text-align: center;
  785. bottom: 20rpx;
  786. }
  787. .bottom {
  788. position: fixed;
  789. bottom: 30rpx;
  790. left: 0;
  791. display: flex;
  792. width: 100%;
  793. justify-content: center;
  794. color: #999999;
  795. .ver {
  796. font-size: 20rpx;
  797. }
  798. .ver-msg {
  799. margin-left: 10rpx;
  800. }
  801. a {
  802. color: #999999;
  803. margin-left: 10rpx;
  804. text-decoration: none;
  805. }
  806. }
  807. .trembling {
  808. animation: shake 0.6s;
  809. }
  810. .main-color {
  811. color: var(--view-theme);
  812. }
  813. </style>