Authored by 陈峰

commit

... ... @@ -2,14 +2,15 @@
export function createYoRouter(router, store) {
return {
goBack(num) {
const backNum = Math.abs(num);
const {history} = store.state.yoho;
// const backNum = Math.abs(num);
// const {history} = store.state.yoho;
if (history.length > backNum) {
const backRoute = history[history.length - (backNum + 1)];
// if (history.length > backNum) {
// const backRoute = history[history.length - (backNum + 1)];
backRoute && router.push(backRoute.fullPath);
}
// backRoute && router.push(backRoute.fullPath);
// }
router.go(num);
}
};
}
... ...