jialh
2025-08-01 17ea4b4d7b1ddf8d4eb345af7440df9b42df9614
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
<template>
    <view>
        <!--index.wxml-->
        <my-person ref="myPersonRef"></my-person>
 
        <my-menu></my-menu>
 
        <my-system ref="mySystem"></my-system>
        
        <!-- <community-recommend></community-recommend> -->
    </view>
</template>
 
<script>
    /** index.js **/
    import context from '../../lib/java110/Java110Context.js';
    const factory = context.factory; //获取app实例
    const constant = context.constant;
    //获取app实例
    const app = getApp().globalData;
    import conf from '../../conf/config.js';
    import {
        getHcCode
    } from '../../api/webView/webViewApi.js'
    import {
        encodeUrl
    } from '../../lib/java110/utils/UrlUtil.js'
    import {
        getCurCommunity
    } from '../../api/community/communityApi.js'
    import {
        setStorageSync
    } from '../../lib/java110/utils/StorageUtil.js'
    import mapping from '../../constant/MappingConstant.js'
 
    import {
        hasLogin
    } from '../../lib/java110/page/Page.js'
    import {
        hasOwner
    } from '../../api/owner/ownerApi.js'
    import {
        queryOwnerAccount
    } from '../../api/user/userApi.js'
 
    import myPerson from '@/components/my/my-person.vue'
    import myMenu from '@/components/my/my-menu.vue'
    import mySystem from '@/components/my/my-system.vue'
    import communityRecommend from '@/components/community-recommend.vue';
    export default {
        data() {
            return {
                property: {},
                // 用户信息    
            };
        },
        components: {
            myPerson,
            myMenu,
            mySystem,
            communityRecommend
        },
        props: {},
        onLoad: function(options) {
            this.vc.onLoad(options, () => {
                this.loadOwnerAccount();
            });
        },
        onShow: function() {
            let _that = this; //查询用户信息
            if (this.$refs.myPersonRef) {
                this.$refs.myPersonRef.refreshPageLoginInfo();
            }
            if (this.$refs.mySystem) {
                this.$refs.mySystem._judgeHasLogin();
            }
 
        },
        methods: {
            // 原onShow方法
            // 自动登录后 刷新页面登录信息
            onGotUserInfo: function(e) {
                console.log("nickname=" + JSON.stringify(e.detail.userInfo));
            },
            // 我的服务跳转
            to_serve(v) {
                this.vc.navigateTo({
                    url: v.href,
                })
            },
        }
    };
</script>
<style lang="less">
    @import "./my.css";
</style>