【发布时间】:2013-06-17 17:24:13
【问题描述】:
我知道在 Rails 中创建控制器的基本命令是使用 Rails 生成控制器
但在代码中,我看到了类似下面的结构,想知道如何做到这一点?
结构如下:
生成的代码是这样的,我需要类似的东西:
module Performance
class BaseController < ApplicationController
end
end
module Performance
class GroupsController < BaseController
def show
end
def index
end
end
end
【问题讨论】:
标签: ruby-on-rails ruby-on-rails-3.2