class GenRouting

Public Class Methods

new(args=[], options={}, config={}) click to toggle source
Calls superclass method
# File lib/jt-mobile-kit-generator/gen_routing/gen_routing.rb, line 6
def initialize(args=[], options={}, config={})
  super
  self.destination_root= ""
end

Public Instance Methods

gen() click to toggle source
# File lib/jt-mobile-kit-generator/gen_routing/gen_routing.rb, line 13
def gen
  page_name = name
  controller_name = name
  content = ERB.new File.read("#{GenRouting.source_root}/routing.js.erb")
  inject_into_file "js/routes.js",content.result(binding), :after => "//routing generate"
end