标签:gate download 页面 file tabbar 路由 log new 跳转
1.最简单是tabBar
app.json中:pages里面要声明,在tabBar里面同样操作,因为是JSON文件,所以所有内容都是字符串
{
"pages": [
"pages/index/index",
"pages/logs/index"
],
"window": {
"navigationBarTitleText": "Demo"
},
"tabBar": {
"list": [{
"pagePath": "pages/index/index",
"text": "首页"
}, {
"pagePath": "pages/logs/logs",
"text": "日志"
}]
},
"networkTimeout": {
"request": 10000,
"downloadFile": 10000
},
"debug": true
}
2.打开新页面,
wx.navigateTo({
url: ‘test?id=1‘
})
3.是第二种的扩展,自定义属性,data- 根据属性值拼接路径
组件
滑块组件属性都写在标签里
当e.detail.value内容比较多时,一个一个赋值麻烦
var propertyName = e.currentTarget.dataset.propertyName
var newData = {}
newData[propertyName] = e.detail.value
this.setData(newData)
标签:gate download 页面 file tabbar 路由 log new 跳转
原文地址:https://www.cnblogs.com/xiaobai1/p/9368637.html