dry_crud 1.7.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +15 -0
- data/MIT-LICENSE +1 -1
- data/README.rdoc +126 -87
- data/VERSION +1 -1
- data/lib/generators/dry_crud/dry_crud_generator.rb +42 -22
- data/lib/generators/dry_crud/templates/INSTALL +5 -5
- data/lib/generators/dry_crud/templates/app/assets/stylesheets/crud.scss +0 -20
- data/lib/generators/dry_crud/templates/app/assets/stylesheets/sample.scss +24 -4
- data/lib/generators/dry_crud/templates/app/controllers/crud/generic_model.rb +89 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/nestable.rb +70 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/rememberable.rb +64 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/render_callbacks.rb +46 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/responder.rb +31 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/searchable.rb +55 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud/sortable.rb +63 -0
- data/lib/generators/dry_crud/templates/app/controllers/crud_controller.rb +66 -69
- data/lib/generators/dry_crud/templates/app/controllers/list_controller.rb +23 -326
- data/lib/generators/dry_crud/templates/app/helpers/actions_helper.rb +64 -0
- data/lib/generators/dry_crud/templates/app/helpers/crud/form_builder.rb +331 -0
- data/lib/generators/dry_crud/templates/app/helpers/crud/table_builder.rb +280 -0
- data/lib/generators/dry_crud/templates/app/helpers/form_helper.rb +52 -0
- data/lib/generators/dry_crud/templates/app/helpers/format_helper.rb +164 -0
- data/lib/generators/dry_crud/templates/app/helpers/i18n_helper.rb +85 -0
- data/lib/generators/dry_crud/templates/app/helpers/table_helper.rb +83 -0
- data/lib/generators/dry_crud/templates/app/helpers/utility_helper.rb +84 -0
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_edit.html.erb +3 -3
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_edit.html.haml +3 -3
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_index.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_index.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_show.html.erb +3 -3
- data/lib/generators/dry_crud/templates/app/views/crud/_actions_show.html.haml +3 -3
- data/lib/generators/dry_crud/templates/app/views/crud/_attrs.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/_attrs.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/_form.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/_form.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/edit.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/edit.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/new.html.erb +2 -2
- data/lib/generators/dry_crud/templates/app/views/crud/new.html.haml +2 -2
- data/lib/generators/dry_crud/templates/app/views/crud/show.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/crud/show.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/layouts/_flash.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/layouts/_nav.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/layouts/_nav.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/layouts/crud.html.erb +15 -7
- data/lib/generators/dry_crud/templates/app/views/layouts/crud.html.haml +18 -8
- data/lib/generators/dry_crud/templates/app/views/list/_search.html.erb +3 -3
- data/lib/generators/dry_crud/templates/app/views/list/_search.html.haml +3 -3
- data/lib/generators/dry_crud/templates/app/views/list/index.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/list/index.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/shared/_error_messages.html.erb +1 -1
- data/lib/generators/dry_crud/templates/app/views/shared/_error_messages.html.haml +1 -1
- data/lib/generators/dry_crud/templates/app/views/shared/_labeled.html.erb +2 -4
- data/lib/generators/dry_crud/templates/app/views/shared/_labeled.html.haml +2 -3
- data/lib/generators/dry_crud/templates/config/initializers/field_error_proc.rb +5 -1
- data/lib/generators/dry_crud/templates/config/locales/crud.de.yml +64 -0
- data/lib/generators/dry_crud/templates/config/locales/{en_crud.yml → crud.en.yml} +2 -2
- data/lib/generators/dry_crud/templates/spec/controllers/crud_test_models_controller_spec.rb +241 -231
- data/lib/generators/dry_crud/templates/spec/helpers/crud/form_builder_spec.rb +226 -0
- data/lib/generators/dry_crud/templates/spec/helpers/{standard_table_builder_spec.rb → crud/table_builder_spec.rb} +36 -34
- data/lib/generators/dry_crud/templates/spec/helpers/form_helper_spec.rb +238 -0
- data/lib/generators/dry_crud/templates/spec/helpers/format_helper_spec.rb +244 -0
- data/lib/generators/dry_crud/templates/spec/helpers/i18n_helper_spec.rb +132 -0
- data/lib/generators/dry_crud/templates/spec/helpers/table_helper_spec.rb +265 -0
- data/lib/generators/dry_crud/templates/spec/helpers/utility_helper_spec.rb +74 -0
- data/lib/generators/dry_crud/templates/spec/support/crud_controller_examples.rb +185 -100
- data/lib/generators/dry_crud/templates/spec/support/crud_controller_test_helper.rb +58 -49
- data/lib/generators/dry_crud/templates/test/{functional → controllers}/crud_test_models_controller_test.rb +112 -91
- data/lib/generators/dry_crud/templates/test/{unit/helpers/standard_form_builder_test.rb → helpers/crud/form_builder_test.rb} +79 -62
- data/lib/generators/dry_crud/templates/test/{unit/helpers/standard_table_builder_test.rb → helpers/crud/table_builder_test.rb} +31 -28
- data/lib/generators/dry_crud/templates/test/helpers/custom_assertions_test.rb +85 -0
- data/lib/generators/dry_crud/templates/test/helpers/form_helper_test.rb +129 -0
- data/lib/generators/dry_crud/templates/test/helpers/format_helper_test.rb +163 -0
- data/lib/generators/dry_crud/templates/test/helpers/i18n_helper_test.rb +79 -0
- data/lib/generators/dry_crud/templates/test/helpers/table_helper_test.rb +217 -0
- data/lib/generators/dry_crud/templates/test/helpers/utility_helper_test.rb +63 -0
- data/lib/generators/dry_crud/templates/test/{functional → support}/crud_controller_test_helper.rb +70 -59
- data/lib/generators/dry_crud/templates/test/{crud_test_model.rb → support/crud_test_model.rb} +107 -75
- data/lib/generators/dry_crud/templates/test/support/custom_assertions.rb +83 -0
- metadata +83 -146
- data/Rakefile +0 -211
- data/lib/generators/dry_crud/templates/app/helpers/crud_helper.rb +0 -168
- data/lib/generators/dry_crud/templates/app/helpers/list_helper.rb +0 -27
- data/lib/generators/dry_crud/templates/app/helpers/standard_form_builder.rb +0 -261
- data/lib/generators/dry_crud/templates/app/helpers/standard_helper.rb +0 -304
- data/lib/generators/dry_crud/templates/app/helpers/standard_table_builder.rb +0 -178
- data/lib/generators/dry_crud/templates/spec/helpers/crud_helper_spec.rb +0 -146
- data/lib/generators/dry_crud/templates/spec/helpers/list_helper_spec.rb +0 -154
- data/lib/generators/dry_crud/templates/spec/helpers/standard_form_builder_spec.rb +0 -215
- data/lib/generators/dry_crud/templates/spec/helpers/standard_helper_spec.rb +0 -387
- data/lib/generators/dry_crud/templates/test/custom_assertions.rb +0 -78
- data/lib/generators/dry_crud/templates/test/unit/custom_assertions_test.rb +0 -117
- data/lib/generators/dry_crud/templates/test/unit/helpers/crud_helper_test.rb +0 -111
- data/lib/generators/dry_crud/templates/test/unit/helpers/list_helper_test.rb +0 -123
- data/lib/generators/dry_crud/templates/test/unit/helpers/standard_helper_test.rb +0 -281
- data/test/templates/Gemfile +0 -46
- data/test/templates/app/controllers/admin/cities_controller.rb +0 -7
- data/test/templates/app/controllers/admin/countries_controller.rb +0 -13
- data/test/templates/app/controllers/ajax_controller.rb +0 -9
- data/test/templates/app/controllers/people_controller.rb +0 -13
- data/test/templates/app/controllers/vips_controller.rb +0 -19
- data/test/templates/app/helpers/cities_helper.rb +0 -9
- data/test/templates/app/helpers/people_helper.rb +0 -8
- data/test/templates/app/models/city.rb +0 -28
- data/test/templates/app/models/country.rb +0 -16
- data/test/templates/app/models/person.rb +0 -12
- data/test/templates/app/views/admin/cities/_actions_index.html.erb +0 -2
- data/test/templates/app/views/admin/cities/_actions_index.html.haml +0 -2
- data/test/templates/app/views/admin/cities/_attrs.html.erb +0 -1
- data/test/templates/app/views/admin/cities/_attrs.html.haml +0 -1
- data/test/templates/app/views/admin/cities/_form.html.erb +0 -7
- data/test/templates/app/views/admin/cities/_form.html.haml +0 -5
- data/test/templates/app/views/admin/cities/_hello.html.erb +0 -1
- data/test/templates/app/views/admin/cities/_hello.html.haml +0 -1
- data/test/templates/app/views/admin/cities/_list.html.erb +0 -3
- data/test/templates/app/views/admin/cities/_list.html.haml +0 -3
- data/test/templates/app/views/admin/countries/_list.html.erb +0 -4
- data/test/templates/app/views/admin/countries/_list.html.haml +0 -3
- data/test/templates/app/views/ajax/_actions_index.html.erb +0 -8
- data/test/templates/app/views/ajax/_actions_index.html.haml +0 -8
- data/test/templates/app/views/ajax/_actions_show.html.erb +0 -4
- data/test/templates/app/views/ajax/_actions_show.html.haml +0 -4
- data/test/templates/app/views/ajax/_form.html.erb +0 -2
- data/test/templates/app/views/ajax/_form.html.haml +0 -2
- data/test/templates/app/views/ajax/_hello.html.erb +0 -1
- data/test/templates/app/views/ajax/_hello.html.haml +0 -1
- data/test/templates/app/views/ajax/ajax.js.erb +0 -1
- data/test/templates/app/views/ajax/ajax.js.haml +0 -1
- data/test/templates/app/views/ajax/edit.js.erb +0 -1
- data/test/templates/app/views/ajax/edit.js.haml +0 -1
- data/test/templates/app/views/ajax/show.js.erb +0 -1
- data/test/templates/app/views/ajax/show.js.haml +0 -1
- data/test/templates/app/views/ajax/update.js.erb +0 -5
- data/test/templates/app/views/ajax/update.js.haml +0 -5
- data/test/templates/app/views/layouts/_nav.html.erb +0 -6
- data/test/templates/app/views/layouts/_nav.html.haml +0 -5
- data/test/templates/app/views/layouts/bootstrap.html.erb +0 -68
- data/test/templates/app/views/layouts/bootstrap.html.haml +0 -49
- data/test/templates/app/views/people/_attrs.html.erb +0 -5
- data/test/templates/app/views/people/_attrs.html.haml +0 -4
- data/test/templates/app/views/people/_list.html.erb +0 -1
- data/test/templates/app/views/people/_list.html.haml +0 -1
- data/test/templates/config/database.yml +0 -21
- data/test/templates/config/locales/en_cities.yml +0 -56
- data/test/templates/config/routes.rb +0 -32
- data/test/templates/db/migrate/20100511174904_create_people_and_cities.rb +0 -26
- data/test/templates/db/seeds.rb +0 -74
- data/test/templates/spec/controllers/admin/cities_controller_spec.rb +0 -74
- data/test/templates/spec/controllers/admin/countries_controller_spec.rb +0 -56
- data/test/templates/spec/controllers/people_controller_spec.rb +0 -80
- data/test/templates/spec/routing/cities_routing_spec.rb +0 -11
- data/test/templates/spec/routing/countries_routing_spec.rb +0 -11
- data/test/templates/test/fixtures/cities.yml +0 -11
- data/test/templates/test/fixtures/countries.yml +0 -11
- data/test/templates/test/fixtures/people.yml +0 -14
- data/test/templates/test/functional/admin/cities_controller_test.rb +0 -59
- data/test/templates/test/functional/admin/countries_controller_test.rb +0 -42
- data/test/templates/test/functional/people_controller_test.rb +0 -68
data/test/templates/Gemfile
DELETED
@@ -1,46 +0,0 @@
|
|
1
|
-
source 'http://rubygems.org'
|
2
|
-
|
3
|
-
gem 'rails', '>= 3.2'
|
4
|
-
|
5
|
-
# Bundle edge Rails instead:
|
6
|
-
# gem 'rails', :git => 'git://github.com/rails/rails.git'
|
7
|
-
|
8
|
-
gem 'sqlite3', :platforms => :ruby
|
9
|
-
|
10
|
-
platforms :jruby do
|
11
|
-
gem 'jdbc-sqlite3'
|
12
|
-
gem 'activerecord-jdbcsqlite3-adapter'
|
13
|
-
end
|
14
|
-
|
15
|
-
gem 'json'
|
16
|
-
|
17
|
-
gem 'haml'
|
18
|
-
|
19
|
-
gem 'kaminari'
|
20
|
-
|
21
|
-
gem 'rspec-rails'
|
22
|
-
|
23
|
-
# Gems used only for assets and not required
|
24
|
-
# in production environments by default.
|
25
|
-
group :assets do
|
26
|
-
gem 'sass-rails' #, '~> 3.2.3'
|
27
|
-
gem 'coffee-rails' #, '~> 3.2.1'
|
28
|
-
gem 'uglifier' #, '>= 1.0.3'
|
29
|
-
gem 'bootstrap-sass-rails'
|
30
|
-
gem 'therubyracer', :require => RUBY_PLATFORM.include?('linux') && 'v8'
|
31
|
-
end
|
32
|
-
|
33
|
-
gem 'jquery-rails'
|
34
|
-
|
35
|
-
# To use ActiveModel has_secure_password
|
36
|
-
# gem 'bcrypt-ruby', '~> 3.0.0'
|
37
|
-
|
38
|
-
# Use unicorn as the web server
|
39
|
-
# gem 'unicorn'
|
40
|
-
|
41
|
-
# Deploy with Capistrano
|
42
|
-
# gem 'capistrano'
|
43
|
-
|
44
|
-
# To use debugger
|
45
|
-
# gem 'ruby-debug'
|
46
|
-
# gem 'ruby-debug19', :require => 'ruby-debug'
|
@@ -1,13 +0,0 @@
|
|
1
|
-
class PeopleController < AjaxController
|
2
|
-
|
3
|
-
self.search_columns = [:name, :children, :rating, :income, :birthdate, :remarks, 'cities.name']
|
4
|
-
|
5
|
-
self.sort_mappings = {:city_id => 'cities.name'}
|
6
|
-
|
7
|
-
private
|
8
|
-
|
9
|
-
def list_entries
|
10
|
-
super.includes(:city => :country).order('people.name, countries.code, cities.name')
|
11
|
-
end
|
12
|
-
|
13
|
-
end
|
@@ -1,19 +0,0 @@
|
|
1
|
-
class VipsController < ListController
|
2
|
-
|
3
|
-
self.search_columns = [:name, :children, :rating, :remarks, 'cities.name']
|
4
|
-
|
5
|
-
self.sort_mappings = {:city_id => 'cities.name'}
|
6
|
-
|
7
|
-
private
|
8
|
-
|
9
|
-
class << self
|
10
|
-
def model_class
|
11
|
-
Person
|
12
|
-
end
|
13
|
-
end
|
14
|
-
|
15
|
-
def list_entries
|
16
|
-
super.where('rating > 5').includes(:city => :country).order('people.name, countries.code, cities.name')
|
17
|
-
end
|
18
|
-
|
19
|
-
end
|
@@ -1,28 +0,0 @@
|
|
1
|
-
class City < ActiveRecord::Base
|
2
|
-
|
3
|
-
attr_protected nil
|
4
|
-
|
5
|
-
belongs_to :country
|
6
|
-
has_many :people
|
7
|
-
|
8
|
-
validates :name, :presence => true
|
9
|
-
validates :country, :presence => true
|
10
|
-
|
11
|
-
before_destroy :protect_with_inhabitants
|
12
|
-
|
13
|
-
default_scope includes(:country).order('countries.code, cities.name')
|
14
|
-
|
15
|
-
def to_s
|
16
|
-
"#{name} (#{country.code})"
|
17
|
-
end
|
18
|
-
|
19
|
-
private
|
20
|
-
|
21
|
-
def protect_with_inhabitants
|
22
|
-
if people.exists?
|
23
|
-
errors.add(:base, :protect_with_inhabitants)
|
24
|
-
false
|
25
|
-
end
|
26
|
-
end
|
27
|
-
|
28
|
-
end
|
@@ -1,16 +0,0 @@
|
|
1
|
-
class Country < ActiveRecord::Base
|
2
|
-
|
3
|
-
attr_protected nil
|
4
|
-
|
5
|
-
has_many :cities, :dependent => :destroy
|
6
|
-
|
7
|
-
validates :name, :presence => true
|
8
|
-
validates :code, :presence => true
|
9
|
-
|
10
|
-
default_scope order('countries.name')
|
11
|
-
|
12
|
-
def to_s
|
13
|
-
name
|
14
|
-
end
|
15
|
-
|
16
|
-
end
|
@@ -1 +0,0 @@
|
|
1
|
-
<%= render_attrs @city, :people %>
|
@@ -1 +0,0 @@
|
|
1
|
-
= render_attrs entry, :people
|
@@ -1 +0,0 @@
|
|
1
|
-
hello from cities
|
@@ -1 +0,0 @@
|
|
1
|
-
hello from cities
|
@@ -1,8 +0,0 @@
|
|
1
|
-
<%= render :partial => 'crud/actions_index' %>
|
2
|
-
|
3
|
-
<%= link_action ti(:'link.ajax'), nil, {:action => 'ajax'}, :method => :get, :remote => true %>
|
4
|
-
<div id="response"></div>
|
5
|
-
|
6
|
-
<% content_for :javascripts do %>
|
7
|
-
var sayHello = function() { alert('Hello'); };
|
8
|
-
<% end %>
|
@@ -1 +0,0 @@
|
|
1
|
-
hello from ajax
|
@@ -1 +0,0 @@
|
|
1
|
-
hello from ajax
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#response').html("<%= escape_javascript(render 'hello') %>");
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#response').html("#{escape_javascript(render 'hello')}");
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#content').html('<%= escape_javascript(render 'form', :remote => true) %>');
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#content').html('#{escape_javascript(render 'form', :remote => true)}');
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#content').html('<%= escape_javascript(render 'attrs') %>');
|
@@ -1 +0,0 @@
|
|
1
|
-
$('#content').html('#{escape_javascript(render 'attrs')}');
|
@@ -1,6 +0,0 @@
|
|
1
|
-
<%= link_to 'MyApp', root_path, :class => 'brand' %>
|
2
|
-
<ul class="nav">
|
3
|
-
<li><%= link_to t(:'global.menu.people'), people_path %></li>
|
4
|
-
<li><%= link_to t(:'global.menu.countries'), admin_countries_path %></li>
|
5
|
-
<li><%= link_to t(:'global.menu.vips'), vips_path %></li>
|
6
|
-
</ul>
|
@@ -1,68 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
|
3
|
-
<html lang="en">
|
4
|
-
<head>
|
5
|
-
<meta charset="utf-8" />
|
6
|
-
<title><%= strip_tags(@title) %></title>
|
7
|
-
<%= csrf_meta_tag %>
|
8
|
-
|
9
|
-
<!-- HTML5 shim, for IE6-8 support of HTML elements -->
|
10
|
-
<!--[if lt IE 9]>
|
11
|
-
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js" type="text/javascript"></script>
|
12
|
-
<![endif]-->
|
13
|
-
|
14
|
-
<%= stylesheet_link_tag 'application', :media => 'all' %>
|
15
|
-
<style type="text/css">
|
16
|
-
body { padding-top: 70px; }
|
17
|
-
h1 { margin-bottom: 10px; }
|
18
|
-
</style>
|
19
|
-
|
20
|
-
<!-- fav and touch icons -->
|
21
|
-
<link href="images/favicon.ico" rel="shortcut icon">
|
22
|
-
<link href="images/apple-touch-icon.png" rel="apple-touch-icon">
|
23
|
-
<link href="images/apple-touch-icon-72x72.png" rel="apple-touch-icon" sizes="72x72">
|
24
|
-
<link href="images/apple-touch-icon-114x114.png" rel="apple-touch-icon" sizes="114x114">
|
25
|
-
|
26
|
-
<%= yield :head %>
|
27
|
-
</head>
|
28
|
-
<body>
|
29
|
-
|
30
|
-
<div class="navbar navbar-fixed-top">
|
31
|
-
<div class="navbar-inner">
|
32
|
-
<div class="container">
|
33
|
-
<%= render 'layouts/nav' %>
|
34
|
-
</div>
|
35
|
-
</div>
|
36
|
-
</div>
|
37
|
-
|
38
|
-
<div class="container">
|
39
|
-
|
40
|
-
<h1><%= @title %></h1>
|
41
|
-
|
42
|
-
<%= render :partial => 'layouts/flash', :collection => [:notice, :alert], :as => :level %>
|
43
|
-
|
44
|
-
<div class="actions btn-toolbar">
|
45
|
-
<div class="pull-right">
|
46
|
-
<%= yield :actions %>
|
47
|
-
</div>
|
48
|
-
<div class="pull-left">
|
49
|
-
<%= yield :tools %>
|
50
|
-
</div>
|
51
|
-
</div>
|
52
|
-
|
53
|
-
<div id="content">
|
54
|
-
<%= yield %>
|
55
|
-
</div>
|
56
|
-
|
57
|
-
<footer>
|
58
|
-
<p>© code!z <%= Time.zone.now.year %></p>
|
59
|
-
</footer>
|
60
|
-
|
61
|
-
</div>
|
62
|
-
|
63
|
-
<!-- Javascript placed at the end of the document so the pages load faster -->
|
64
|
-
<%= javascript_include_tag 'application' %>
|
65
|
-
<%= javascript_tag yield(:javascripts) if content_for?(:javascripts) %>
|
66
|
-
|
67
|
-
</body>
|
68
|
-
</html>
|
@@ -1,49 +0,0 @@
|
|
1
|
-
!!! 5
|
2
|
-
|
3
|
-
%html
|
4
|
-
%head
|
5
|
-
%meta{:charset => 'utf-8'}
|
6
|
-
%title= strip_tags(@title)
|
7
|
-
= csrf_meta_tag
|
8
|
-
|
9
|
-
<!-- HTML5 shim, for IE6-8 support of HTML elements -->
|
10
|
-
<!--[if lt IE 9]>
|
11
|
-
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js" type="text/javascript"></script>
|
12
|
-
<![endif]-->
|
13
|
-
|
14
|
-
= stylesheet_link_tag 'application', :media => 'all'
|
15
|
-
%style{:type => "text/css"}
|
16
|
-
body { padding-top: 70px; }
|
17
|
-
h1 { margin-bottom: 10px; }
|
18
|
-
|
19
|
-
%link{:href => "images/favicon.ico", :rel => "shortcut icon"}
|
20
|
-
%link{:href => "images/apple-touch-icon.png", :rel => "apple-touch-icon"}
|
21
|
-
%link{:href => "images/apple-touch-icon-72x72.png", :rel => "apple-touch-icon", :sizes => "72x72"}
|
22
|
-
%link{:href => "images/apple-touch-icon-114x114.png", :rel => "apple-touch-icon", :sizes => "114x114"}
|
23
|
-
|
24
|
-
= yield :head
|
25
|
-
|
26
|
-
%body
|
27
|
-
|
28
|
-
.navbar.navbar-fixed-top
|
29
|
-
.navbar-inner
|
30
|
-
.container= render 'layouts/nav'
|
31
|
-
|
32
|
-
.container
|
33
|
-
|
34
|
-
%h1= @title
|
35
|
-
|
36
|
-
= render :partial => 'layouts/flash', :collection => [:notice, :alert], :as => :level
|
37
|
-
|
38
|
-
.actions.btn-toolbar
|
39
|
-
.pull-right= yield :actions
|
40
|
-
.pull-left= yield :tools
|
41
|
-
|
42
|
-
#content= yield
|
43
|
-
|
44
|
-
%footer
|
45
|
-
%p
|
46
|
-
© code!z #{Time.zone.now.year}
|
47
|
-
|
48
|
-
= javascript_include_tag 'application'
|
49
|
-
= javascript_tag yield(:javascripts) if content_for?(:javascripts)
|