| | |
| | | import { http } from '@/utils/service.js' |
| | | export * from '@/utils/config.js' |
| | | export * from './visitor' |
| | | export * from './staff' |
| | | |
| | | // æ¥è¯¢åå
¸å¼æ°æ® |
| | | export const getSystemDictData = (data) => { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { http } from '@/utils/service.js' |
| | | |
| | | // login |
| | | export const loginPost = (data) => { |
| | | return http({ |
| | | url: 'visitsAdmin/cloudService/web/member/accountLogin', |
| | | data |
| | | }) |
| | | } |
| | |
| | | import { http } from '@/utils/service.js' |
| | | import { methods } from 'uview-ui/libs/mixin/mixin' |
| | | |
| | | // 访客é¢çº¦è¯¦æ
|
| | | export const visitorSubDetail = (data) => { |
| | |
| | | const appID = 'wx4d7c10bdec51942b' |
| | | const AppSecret = '922c93596d134fedf5bd22a9354b3bfe' |
| | | // const scope = 'snsapi_userinfo' |
| | | let uri = encodeURIComponent('http://xiaopiqiu2.natapp1.cc') |
| | | let uri = encodeURIComponent('https://xiaopiqiu2.natapp1.cc') |
| | | let authURL = |
| | | `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${appID}&redirect_uri=${uri}&response_type=code&scope=snsapi_userinfo&state=123#wechat_redirect` |
| | | `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${appID}&redirect_uri=${uri}&response_type=code&scope=snsapi_base&state=123#wechat_redirect` |
| | | window.location.href = authURL |
| | | } |
| | | } |
| | |
| | | <view class="login_list_item"> |
| | | <image src="@/static/login_ic_phone@2x.png" mode="widthFix" /> |
| | | <input |
| | | v-model="form.idCard" |
| | | v-model="form.account" |
| | | maxlength="18" |
| | | type="number" |
| | | placeholder="è´¦å·" |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { loginPost } from '@/api' |
| | | export default { |
| | | name: 'login', |
| | | |
| | | data() { |
| | | return { |
| | | form: { |
| | | idCard: '', |
| | | password: '' |
| | | account: '', |
| | | password: '', |
| | | } |
| | | } |
| | | }, |
| | |
| | | console.log(e) |
| | | }, |
| | | onLogin() { |
| | | const { form } = this |
| | | if (!form.account) return uni.showToast({ |
| | | title: 'è´¦å·åä¸è½ä¸ºç©º', |
| | | icon: 'none' |
| | | }) |
| | | if (!form.password) return uni.showToast({ |
| | | title: 'å¯ç ä¸è½ä¸ºç©º', |
| | | icon: 'none' |
| | | }) |
| | | const appID = 'wx4d7c10bdec51942b' |
| | | const AppSecret = '922c93596d134fedf5bd22a9354b3bfe' |
| | | // const scope = 'snsapi_userinfo' |
| | | let uri = encodeURIComponent('http://xiaopiqiu2.natapp1.cc') |
| | | let uri = encodeURIComponent('https://xiaopiqiu2.natapp1.cc') |
| | | let authURL = |
| | | `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${appID}&redirect_uri=${uri}&response_type=code&scope=snsapi_userinfo&state=123#wechat_redirect` |
| | | window.location.href = authURL |
| | | |
| | | loginPost(form).then(res => { |
| | | console.log('res', res); |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | }, |
| | | onLoad() { |
| | | // this.getInfo() |
| | | this.getInfo() |
| | | }, |
| | | methods: { |
| | | getInfo() { |