这听起来很奇怪,但是听我说……我需要能够向我的其他控制器发出相应的POST请求. SimpleController基本上是更详细的控制器的简化版本.我怎么能这样做呢?
class VerboseController < ApplicationController def create # lots of required params end end class SimpleController < ApplicationController def create # prepare the params required for VerboseController.create # now call the VerboseController.create with the new params end end
也许我过度思考这个问题,但我不知道该怎么做.