tags: Self-study road Applets
/**
* Lifecycle Function - Listening Page Load
*/
onload: function(){
/ / Get the current page stack. The first element in the array is the homepage, the last element is the current page.
let _page = getCurrentPages()
prevPage = _page[_page.length - 2]
/ / You can print the prVEpage to see what data needed
}
The applet is judged whether or not there is a page of practice: the focus is the method of using getcurrentpages () ...
With such a scene, the user has an operation or other operation in the order details page, click the return to the order list in the upper left corner, this time you need to refresh the list of data, ...
Perform a step back to the upper page...
A page jumps to the B page, the B page belt returns to the A page. A page B page A page...
Page applet is micro-channel (page load) by the onLoad, onReady (initial page rendering is complete), onShow (page display), onHide (page hidden), onUnload (page unload) constitutes five cycles; Back ...
Not much to say that directly on the code, there is a comment in the code Then follow the code on the previous page Here you need in onshow because you need to update in real time, so you need to moni...
WX.naVigateback: Back to the previous page WX.navigateto: Keep the current page, jump to a page within the applet. WX.Redirectto: Turn off the current page and jump to a page within the app. WX.Switch...
The applet can directly manipulate the data of the previous page to realize reverse transfer...