公共登录类

This commit is contained in:
唐明明
2021-07-26 15:01:43 +08:00
parent 6f29bdc89f
commit f77f474602
10 changed files with 1338 additions and 2514 deletions

View File

@@ -5,7 +5,8 @@
</view>
</template>
<script>
<script>
import { auth } from '@/apis/interfaces/auth'
export default {
data() {
return {
@@ -44,21 +45,18 @@
}]
}
},
success : auth => {
console.log(auth)
uniCloud.callFunction({
name: "phone-login",
data: {
access_token: auth.authResult.access_token + '111',
openid : auth.authResult.openid
}
}).then(res=>{
success : result => {
auth({
access_token: result.authResult.access_token,
openid : result.authResult.openid
}).then(res => {
console.log(res)
}).catch(err=>{
console.log(err)
})
},
fail : err => {
uni.showToast({
title: err.errMsg
})
console.log(err)
}
})