quanwei
2 days ago 73b874c72ad55eb9eef21c36160ac0de58f0189e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<template>
    <view v-if="!loading">
        <template v-if="status==2">
            <myorder></myorder>
        </template>
        <template v-if="status==1">
            <shoplist></shoplist>
        </template>
    </view>
</template>
 
<script>
    import myorder from '../order/myorder.vue'
    import shoplist from './shop_list.vue'
    export default {
        components: {
            myorder,
            shoplist
        },
        data() {
            return {
                status: 1,
                loading: true
            }
        },
        onReady() {
            let tit = ''
            if (this.status == 1) {
                tit = '店铺'
            } else if (this.status == 2) {
                tit = '订单'
            }
 
            uni.setNavigationBarTitle({
                title: tit
            });
        },
        onShow() {
            let self = this;
            console.log(1)
            self.loading = true;
            uni.showLoading({
                title: ''
            })
            setTimeout(function() {
                self.loading = false;
                uni.hideLoading()
            }, 100);
        },
        onLoad() {
            this.status = uni.getStorageSync('middle');
        },
        mounted() {
 
        },
        methods: {
 
        }
    }
</script>
 
<style>
 
</style>