| | |
| | | return { |
| | | agreed: false, |
| | | form: { |
| | | account: '', |
| | | password: '', |
| | | telephone: '' |
| | | telephone: '', |
| | | password: '' |
| | | } |
| | | }; |
| | | }, |
| | |
| | | }); |
| | | return _context.abrupt("return"); |
| | | case 3: |
| | | if (_this.form.account) { |
| | | if (_this.form.telephone) { |
| | | _context.next = 6; |
| | | break; |
| | | } |
| | |
| | | }); |
| | | return _context.abrupt("return"); |
| | | case 9: |
| | | if (_this.form.telephone) { |
| | | _context.next = 12; |
| | | break; |
| | | } |
| | | uni.showToast({ |
| | | title: '请输入手机号', |
| | | icon: 'none' |
| | | }); |
| | | return _context.abrupt("return"); |
| | | case 12: |
| | | uni.showLoading({ |
| | | title: '登录中...', |
| | | mask: true |
| | | }); |
| | | _context.prev = 13; |
| | | _context.next = 16; |
| | | _context.prev = 10; |
| | | _context.next = 13; |
| | | return _this.$u.api.shopLogin({ |
| | | openid: _this.openid, |
| | | password: _this.form.password, |
| | | telephone: _this.form.telephone |
| | | }); |
| | | case 16: |
| | | case 13: |
| | | res = _context.sent; |
| | | uni.hideLoading(); |
| | | if (res.code === 200) { |
| | |
| | | icon: 'none' |
| | | }); |
| | | } |
| | | _context.next = 25; |
| | | _context.next = 22; |
| | | break; |
| | | case 21: |
| | | _context.prev = 21; |
| | | _context.t0 = _context["catch"](13); |
| | | case 18: |
| | | _context.prev = 18; |
| | | _context.t0 = _context["catch"](10); |
| | | uni.hideLoading(); |
| | | uni.showToast({ |
| | | title: '登录失败', |
| | | icon: 'none' |
| | | }); |
| | | case 25: |
| | | case 22: |
| | | case "end": |
| | | return _context.stop(); |
| | | } |
| | | } |
| | | }, _callee, null, [[13, 21]]); |
| | | }, _callee, null, [[10, 18]]); |
| | | }))(); |
| | | }, |
| | | goToService: function goToService() { |