当前位置:网站首页>Apicloud openframe realizes the transfer and return of parameters to the previous page - basic improvement
Apicloud openframe realizes the transfer and return of parameters to the previous page - basic improvement
2022-07-06 01:46:00 【yehaocheng520】
In writing today apicloud When , Meet a need , It's about putting A The parameters of the page are passed to B page ,B After a series of operations on the page , Then pass the data to A page .
The implementation of this function will be introduced in detail below :
1. take A The delivery of the page to B page
api.openFrame({
name: 'relationPartNoReview',
url: './relationPartNoReview.html',
rect: {
x:0,
y:0,
w:'auto',
h:'auto'
},
reload:true,
animation:{
type:"none",
duration:1
},
pageParam: {
partNo: this.partNo
}
});
In the above code pageParam Object partNo Is to pass on to B Parameters of the page .
2.B Page to receive A Parameters passed by the page
apiready = function () {
var pageParam = api.pageParam;
var vm = new Vue({
el:'#xxx',
data(){
return{
partNo:pageParam.partNo
}
}
})
}
3.B Page passes parameters to A page
You can use sendEvent and addEventListener To deal with it .
B How to write the page :
api.sendEvent({
name:'refreshCheck',
extra:{
id:this.xxx.id
}
})
A How to write the page :
api.addEventListener({
name:'refreshCheck',
},function(ret,err){
if(ret.value&&ret.value.id){
// Received B Processing operations after the data transferred from the page
}
})
complete !!!
边栏推荐
- Superfluid_ HQ hacked analysis
- C web page open WinForm exe
- Basic operations of databases and tables ----- primary key constraints
- [detailed] several ways to quickly realize object mapping
- 阿里测开面试题
- 竞价推广流程
- GBase 8c数据库升级报错
- Regular expressions: examples (1)
- ClickOnce 不支持请求执行级别“requireAdministrator”
- 使用npm发布自己开发的工具包笔记
猜你喜欢

Redis string type

Selenium waiting mode

Huawei converged VLAN principle and configuration

A Cooperative Approach to Particle Swarm Optimization

Leetcode sum of two numbers

TrueType字体文件提取关键信息

Basic operations of database and table ----- delete data table

NiO related knowledge (II)
![[Jiudu OJ 09] two points to find student information](/img/35/25aac51fa3e08558b1f6e2541762b6.jpg)
[Jiudu OJ 09] two points to find student information

插卡4G工业路由器充电桩智能柜专网视频监控4G转以太网转WiFi有线网速测试 软硬件定制
随机推荐
Force buckle 1020 Number of enclaves
Extracting key information from TrueType font files
Ali test Open face test
【网络攻防实训习题】
一图看懂!为什么学校教了你Coding但还是不会的原因...
leetcode3、實現 strStr()
插卡4G工业路由器充电桩智能柜专网视频监控4G转以太网转WiFi有线网速测试 软硬件定制
Redis-字符串类型
Dynamics 365 开发协作最佳实践思考
Internship: unfamiliar annotations involved in the project code and their functions
【详细】快速实现对象映射的几种方式
[le plus complet du réseau] | interprétation complète de MySQL explicite
通过PHP 获取身份证相关信息 获取生肖,获取星座,获取年龄,获取性别
Folio. Ink is a free, fast and easy-to-use image sharing tool
How does Huawei enable debug and how to make an image port
leetcode刷题_反转字符串中的元音字母
NLP第四范式:Prompt概述【Pre-train,Prompt(提示),Predict】【刘鹏飞】
[Jiudu OJ 09] two points to find student information
D22:indeterminate equation (indefinite equation, translation + problem solution)
2022 PMP project management examination agile knowledge points (8)