| | |
| | | const router = createRouter() |
| | | |
| | | router.afterEach((to, from, next) => { |
| | | console.log(to,"to") |
| | | if ((to.path === "/overview/overviewList" || to.path === "/productManage/productList") && to.params.name) { |
| | | console.log(from, next) |
| | | to.meta.title = to.params.name |
| | | document.title = to.meta.title |
| | | } else if (to.path === "/reportForm/inOutboundDetail" && to.params.name) { |
| | | to.meta.title = "出入库明细" |
| | | } else if (to.name === "inboundOutboundDetail") { |
| | | to.meta.title = to.params.name + "/出入库明细" |
| | | document.title = to.meta.title |
| | | } |
| | | }) |