diff --git a/api_taster.gemspec b/api_taster.gemspec index 6f5666b..6363724 100644 --- a/api_taster.gemspec +++ b/api_taster.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |s| s.files = `git ls-files`.split($\) s.test_files = Dir["spec/**/*"] - s.add_dependency 'rails', '~> 4.0.0' + s.add_dependency 'rails', '~> 4.1.0' s.add_dependency 'jquery-rails' s.add_dependency 'sass-rails' s.add_dependency 'bootstrap-sass', '~> 2.1' diff --git a/lib/api_taster/form_builder.rb b/lib/api_taster/form_builder.rb index 10c8f19..c623c99 100644 --- a/lib/api_taster/form_builder.rb +++ b/lib/api_taster/form_builder.rb @@ -1,6 +1,7 @@ module ApiTaster class FormBuilder < AbstractController::Base include AbstractController::Rendering + include ActionView::Layouts include ActionView::Context include ActionView::Helpers::CaptureHelper @@ -48,7 +49,7 @@ def add_to_buffer(params, parent_labels = []) def add_element_to_buffer(parent_labels, label, value) @_buffer += render( - :partial => 'api_taster/routes/param_form_element', + :template => 'api_taster/routes/_param_form_element', :locals => { :label => "#{print_labels(parent_labels)}#{label}", :label_text => label, @@ -59,7 +60,7 @@ def add_element_to_buffer(parent_labels, label, value) def add_legend_to_buffer(parent_labels, label) @_buffer += render( - :partial => 'api_taster/routes/param_form_legend', + :template => 'api_taster/routes/_param_form_legend', :locals => { :label => print_labels(parent_labels.clone << label) } ) end diff --git a/lib/api_taster/version.rb b/lib/api_taster/version.rb index c02dea4..a7cb31f 100644 --- a/lib/api_taster/version.rb +++ b/lib/api_taster/version.rb @@ -1,3 +1,3 @@ module ApiTaster - VERSION = "0.7.0" + VERSION = "0.8.0" end