当前位置:网站首页>uni-app---uni. Navigateto jump parameter use
uni-app---uni. Navigateto jump parameter use
2022-07-05 09:29:00 【Left hand holding * * right hand】
uni-app Have their own grammar . When we use it, we pass parameters , Pass string or object ,
String pass parameters : You can splice addresses
goreportdetails(id) {
uni.navigateTo({
url: '/pages/reportdetails/reportdetails?id=' + id + '&name=edit'
})
},
The object passes parameters : Sometimes parameters are lost , So with encodeURIComponent
uni.navigateTo({
url: '/pages/build/build?list=' + encodeURIComponent(JSON.stringify(this.itemList)) + '&name=' + this.name +'&totalScore=' + this.totalScore + '&content=' + this.content+ '&uid=' + this.uid,
})
Then the receiving parameters are :
onLoad(option) {
if (option) {
this.name = option.name
this.uid = option.uid
if (option.list) {
this.list = JSON.parse(decodeURIComponent(option.list));
}
}
}
边栏推荐
- Applet (use of NPM package)
- scipy. misc. imread()
- C language - input array two-dimensional array a from the keyboard, and put 3 in a × 5. The elements in the third column of the matrix are moved to the left to the 0 column, and the element rows in ea
- LeetCode 556. Next bigger element III
- Nodemon installation and use
- Kotlin introductory notes (VI) interface and function visibility modifiers
- LeetCode 496. Next larger element I
- c语言指针深入理解
- 【组队 PK 赛】本周任务已开启 | 答题挑战,夯实商品详情知识
- 信息与熵,你想知道的都在这里了
猜你喜欢

Lepton 无损压缩原理及性能分析

Kotlin introductory notes (VII) data class and singleton class
![Multiple solutions to one problem, asp Net core application startup initialization n schemes [Part 1]](/img/c4/27ae0d259abc4e61286c1f4d90c06a.png)
Multiple solutions to one problem, asp Net core application startup initialization n schemes [Part 1]

Applet global style configuration window

LeetCode 556. Next bigger element III

Project practice | excel export function

Nodejs modularization

项目实战 | Excel导出功能

Unity skframework framework (XXII), runtime console runtime debugging tool

Huber Loss
随机推荐
Svg optimization by svgo
[team PK competition] the task of this week has been opened | question answering challenge to consolidate the knowledge of commodity details
High performance spark_ Transformation performance
【ManageEngine】如何利用好OpManager的报表功能
Talking about label smoothing technology
Nodemon installation and use
OpenGL - Model Loading
SQL learning - case when then else
浅谈Label Smoothing技术
Kotlin introductory notes (III) kotlin program logic control (if, when)
Kotlin introductory notes (VII) data class and singleton class
An article takes you into the world of cookies, sessions, and tokens
Applet (use of NPM package)
Android 隐私沙盒开发者预览版 3: 隐私安全和个性化体验全都要
nodejs_ fs. writeFile
[object array A and object array B take out different elements of ID and assign them to the new array]
阿里十年测试带你走进APP测试的世界
高性能Spark_transformation性能
Kotlin introductory notes (I) kotlin variables and non variables
Applet customization component