重构 Routes 文件模块太多,想把定义的 admin、account、site 等等模块分别在不同文件里写,有方法吗?

lengcb · June 05, 2017 · Last by lengcb replied at June 05, 2017 · 6196 hits

我的 routes.rb 文件里面模块太多,我想把定义的 admin、account、site 等等模块分别在不同文件里写,然后在 routes.rb 文件里引用,有方法吗?

Reply to geekerzp

谢谢高手

记着一条就行 routes.rb 本身也是 ruby 文件 遵守 ruby 的语法

Reply to jicheng1014

嗯,谢谢

You need to Sign in before reply, if you don't have an account, please Sign up first.