|
<template name="reload">
<view>
<img src="../../image/home00.png" onclick="goIndex()" />
<img src="../../image/home01.png" onclick="goIndex()" />
</view>
</template>
<script>
export default {
name: "reload",
apiready() { //like created
this.goIndex()
},
data() {
return {
};
},
methods: {
//跳转系统主页
goIndex() {
var param = {
"name": "root",
"tabBar": {
"frames": [{
"title": "首页",
"name": "tab-chat",
"url": "../tab-chat/tab-chat.stml"
}, {
"title": "课程",
"name": "course",
"url": "../tab-course/tab-course.stml"
}, {
"title": "发现",
"name": "discover",
"url": "../tab-discover/tab-discover.stml"
}, {
"title": "我的",
"name": "user",
"url": "../tab-user/tab-user.stml"
}],
"list": [{
"text": "首页",
"iconPath": "../../image/home00.png",
"selectedIconPath": "../../image/home01.png"
}, {
"text": "课程",
"iconPath": "../../image/course00.png",
"selectedIconPath": "../../image/course01.png"
}, {
"text": "发现",
"iconPath": "../../image/discover00.png",
"selectedIconPath": "../../image/discover01.png"
}, {
"text": "我的",
"iconPath": "../../image/user00.png",
"selectedIconPath": "../../image/user01.png"
}],
"textOffset": 6,
"color": "#999999",
"selectedColor": "#333333",
"scrollEnabled": false
}
};
api.openTabLayout(param);
}
}
}
</script>
<style>
</style>这个是 reload.stml 文件我已经验证过, 路径是对的,请帮帮看看是哪里的问题。登录进去没有跳转到主页。
|
|