下单页面调整,确认订单页面调整
This commit is contained in:
16
utils/uniapp.js
Normal file
16
utils/uniapp.js
Normal file
@@ -0,0 +1,16 @@
|
||||
export const back=()=>{
|
||||
console.log('back');
|
||||
try {
|
||||
const arr= getCurrentPages()
|
||||
if(arr.length>=2){
|
||||
return uni.navigateBack()
|
||||
}else{
|
||||
uni.reLaunch({
|
||||
url:'/pages/index/index'
|
||||
})
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('页面返回出错',error)
|
||||
//TODO handle the exception
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user