Merge branch 'develop'
Former-commit-id: f3aa24b82ad931b87b132a540c19a2e30ce36dce
This commit is contained in:
+1
-4
@@ -56,11 +56,8 @@ router.beforeEach((to, from, next) => {
|
||||
router.afterEach(to => {
|
||||
// 进度条
|
||||
NProgress.done()
|
||||
// 需要的信息
|
||||
const app = router.app
|
||||
const { name, params, query, fullPath } = to
|
||||
// 多页控制 打开新的页面
|
||||
app.$store.dispatch('d2admin/page/open', { name, params, query, fullPath })
|
||||
store.dispatch('d2admin/page/open', to)
|
||||
// 更改标题
|
||||
util.title(to.meta.title)
|
||||
})
|
||||
|
||||
@@ -125,7 +125,7 @@ export default {
|
||||
* @class current
|
||||
* @description 打开一个新的页面
|
||||
* @param {Object} state vuex state
|
||||
* @param {Object} param { name, params, query, fullPath } 路由信息
|
||||
* @param {Object} param 从路由钩子的 to 对象上获取 { name, params, query, fullPath } 路由信息
|
||||
*/
|
||||
open ({ state, commit, dispatch }, { name, params, query, fullPath }) {
|
||||
return new Promise(async resolve => {
|
||||
|
||||
Reference in New Issue
Block a user