事件上报登录
This commit is contained in:
@@ -93,11 +93,12 @@
|
|||||||
<div class="btn-wrapper">
|
<div class="btn-wrapper">
|
||||||
<div class="btn" hover-class="text-hover" @click="submit">提交</div>
|
<div class="btn" hover-class="text-hover" @click="submit">提交</div>
|
||||||
</div>
|
</div>
|
||||||
|
<AiLogin ref="login"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {mapState} from 'vuex'
|
import {mapActions, mapState} from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
appName: "上报事件",
|
appName: "上报事件",
|
||||||
@@ -122,16 +123,23 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
...mapState(['user'])
|
...mapState(['user', 'token'])
|
||||||
},
|
},
|
||||||
|
|
||||||
onLoad() {
|
onLoad() {
|
||||||
this.getDict()
|
this.autoLogin()
|
||||||
this.form.phone = this.user.phone
|
},
|
||||||
this.form.name = this.user.realName || ''
|
onShow() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.token && this.getUserInfo()
|
||||||
|
this.getDict()
|
||||||
|
this.form.phone = this.user.phone
|
||||||
|
this.form.name = this.user.realName || ''
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapActions(['autoLogin', 'getUserInfo']),
|
||||||
chooseAddress() {
|
chooseAddress() {
|
||||||
uni.authorize({
|
uni.authorize({
|
||||||
scope: 'scope.userLocation',
|
scope: 'scope.userLocation',
|
||||||
|
|||||||
Reference in New Issue
Block a user