获取页面栈:
语法:
let pages = getCurrentPages();
设置页面栈:
小程序语法:
pages.data
H5语法:
pages
let pages = getCurrentPages();
let page = pages[pages.length - 2];
if(page.route == "pages/confirmOrder/confirmOrder") {// #ifdef MP-WEIXINif(page.data.address.id == id) {page.$vm.address = {};};// #endif// #ifdef H5if(page.address.id == id) {page.$vm.address = {};};// #endif
};