8000 fix 支持编辑页面处理 · laraveladmin-cn/laraveladmin@6f0e7b2 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6f0e7b2

Browse files
zsping1989gitee-org
authored andcommitted
fix 支持编辑页面处理
Signed-off-by: 张世平 <214986304@qq.com>
1 parent cb6334f commit 6f0e7b2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

resources/js/routes.js

+4
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@ collect(routesConfig.group).map((group,key)=>{
3636
let path = path_arr.join('/');
3737
let path1 = ((name?name+'/':'')+path).replace(/-/g,'_');
3838
let pathName = 'pages'+path1+'.vue';
39+
if(path.indexOf('{id}')!=-1){
40+
path = path.replace('{id}',':id');
41+
pathName = pathName.replace('{id}','edit');
42+
}
3943
let route = {
4044
path: path,
4145
component: () => import(/* webpackChunkName: "[request]" */ `./${pathName}`)

0 commit comments

Comments
 (0)
0