engine_room 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +10 -0
- data/Gemfile +4 -0
- data/Gemfile.lock +159 -0
- data/MIT-LICENSE +20 -0
- data/README.rdoc +44 -0
- data/Rakefile +30 -0
- data/TODO +3 -0
- data/app/controllers/engine_room/content_controller.rb +117 -0
- data/app/controllers/engine_room/fields_controller.rb +119 -0
- data/app/controllers/engine_room/models_controller.rb +89 -0
- data/app/controllers/engine_room/pages_controller.rb +17 -0
- data/app/controllers/engine_room/sections_controller.rb +74 -0
- data/app/controllers/engine_room/users_controller.rb +84 -0
- data/app/controllers/er_devise/passwords_controller.rb +6 -0
- data/app/controllers/er_devise/registrations_controller.rb +8 -0
- data/app/controllers/er_devise/sessions_controller.rb +6 -0
- data/app/helpers/engine_room/content_helper.rb +103 -0
- data/app/helpers/engine_room/models_helper.rb +21 -0
- data/app/models/field.rb +89 -0
- data/app/models/section.rb +68 -0
- data/app/models/user.rb +31 -0
- data/app/views/engine_room/content/_form.html.erb +13 -0
- data/app/views/engine_room/content/_overview.html.erb +28 -0
- data/app/views/engine_room/content/_sidebar.html.erb +14 -0
- data/app/views/engine_room/content/edit.html.erb +38 -0
- data/app/views/engine_room/content/index.html.erb +1 -0
- data/app/views/engine_room/content/new.html.erb +1 -0
- data/app/views/engine_room/content/overview.html.erb +3 -0
- data/app/views/engine_room/fields/_form.html.erb +57 -0
- data/app/views/engine_room/fields/edit.html.erb +1 -0
- data/app/views/engine_room/fields/new.html.erb +1 -0
- data/app/views/engine_room/models/_form.html.erb +0 -0
- data/app/views/engine_room/models/edit.html.erb +14 -0
- data/app/views/engine_room/models/index.html.erb +16 -0
- data/app/views/engine_room/models/new.html.erb +14 -0
- data/app/views/engine_room/models/overview.html.erb +14 -0
- data/app/views/engine_room/pages/dashboard.html.erb +1 -0
- data/app/views/engine_room/pages/settings.html.erb +1 -0
- data/app/views/engine_room/sections/_form.html.erb +34 -0
- data/app/views/engine_room/sections/_sidebar.html.erb +11 -0
- data/app/views/engine_room/sections/edit.html.erb +81 -0
- data/app/views/engine_room/sections/index.html.erb +3 -0
- data/app/views/engine_room/sections/new.html.erb +1 -0
- data/app/views/engine_room/users/_form.html.erb +47 -0
- data/app/views/engine_room/users/edit.html.erb +11 -0
- data/app/views/engine_room/users/index.html.erb +24 -0
- data/app/views/engine_room/users/new.html.erb +1 -0
- data/app/views/er_devise/mailer/confirmation_instructions.html.erb +5 -0
- data/app/views/er_devise/mailer/reset_password_instructions.html.erb +8 -0
- data/app/views/er_devise/mailer/unlock_instructions.html.erb +7 -0
- data/app/views/er_devise/passwords/edit.html.erb +16 -0
- data/app/views/er_devise/passwords/new.html.erb +13 -0
- data/app/views/er_devise/registrations/edit.html.erb +42 -0
- data/app/views/er_devise/registrations/new.html.erb +21 -0
- data/app/views/er_devise/sessions/new.html.erb +23 -0
- data/app/views/er_devise/shared/_links.erb +19 -0
- data/app/views/layouts/engine_room.html.erb +103 -0
- data/app/views/layouts/login.html.erb +71 -0
- data/app/views/shared/_content_layout_selector.html.erb +45 -0
- data/app/views/shared/_error_messages.html.erb +17 -0
- data/config/initializers/devise.rb +146 -0
- data/config/initializers/locale.rb +5 -0
- data/config/locales/devise.de.yml +42 -0
- data/config/locales/devise.en.yml +39 -0
- data/config/locales/engine_room.de.yml +33 -0
- data/config/locales/engine_room.en.yml +42 -0
- data/config/routes.rb +62 -0
- data/engine_room.gemspec +35 -0
- data/lib/engine_room.rb +17 -0
- data/lib/engine_room/action_controller/controller_methods.rb +21 -0
- data/lib/engine_room/action_view/view_methods.rb +8 -0
- data/lib/engine_room/active_record/record_methods.rb +18 -0
- data/lib/engine_room/crummy/custom_renderer.rb +63 -0
- data/lib/engine_room/engine.rb +40 -0
- data/lib/engine_room/railties/tasks.rake +6 -0
- data/lib/engine_room/version.rb +3 -0
- data/lib/generators/engine_room/create_image_generator.rb +26 -0
- data/lib/generators/engine_room/setup_generator.rb +30 -0
- data/lib/generators/engine_room/templates/001_devise_create_users.rb +28 -0
- data/lib/generators/engine_room/templates/002_create_sections.rb +16 -0
- data/lib/generators/engine_room/templates/003_create_fields.rb +18 -0
- data/lib/generators/engine_room/templates/004_create_images.rb +19 -0
- data/lib/generators/engine_room/templates/image.rb +4 -0
- data/lib/tasks/dummy.rake +45 -0
- data/lib/tasks/templates/migrate/050_create_dogs.rb +18 -0
- data/lib/tasks/templates/models/dog.rb +3 -0
- data/public/images/er/accept.png +0 -0
- data/public/images/er/add.png +0 -0
- data/public/images/er/add_small.png +0 -0
- data/public/images/er/ajax-loader.gif +0 -0
- data/public/images/er/attach.png +0 -0
- data/public/images/er/back_disabled.jpg +0 -0
- data/public/images/er/back_enabled.jpg +0 -0
- data/public/images/er/bg/header_gradient_center.jpg +0 -0
- data/public/images/er/bg/header_gradient_left.jpg +0 -0
- data/public/images/er/bg/header_gradient_right.jpg +0 -0
- data/public/images/er/cancel.png +0 -0
- data/public/images/er/cog.png +0 -0
- data/public/images/er/database_add.png +0 -0
- data/public/images/er/delete.png +0 -0
- data/public/images/er/delete_small.png +0 -0
- data/public/images/er/down_arrow.gif +0 -0
- data/public/images/er/down_arrow.png +0 -0
- data/public/images/er/email.png +0 -0
- data/public/images/er/exclamation.png +0 -0
- data/public/images/er/forward_disabled.jpg +0 -0
- data/public/images/er/forward_enabled.jpg +0 -0
- data/public/images/er/help.png +0 -0
- data/public/images/er/image_add.png +0 -0
- data/public/images/er/information.png +0 -0
- data/public/images/er/link.png +0 -0
- data/public/images/er/loader.gif +0 -0
- data/public/images/er/telephone.png +0 -0
- data/public/images/er/up_arrow.gif +0 -0
- data/public/images/er/up_arrow.png +0 -0
- data/public/images/er/user.png +0 -0
- data/public/images/er/wrench.png +0 -0
- data/public/images/er/zoom.png +0 -0
- data/public/javascripts/er/dd_belatedpng.js +328 -0
- data/public/javascripts/er/fancybox/blank.gif +0 -0
- data/public/javascripts/er/fancybox/fancy_close.png +0 -0
- data/public/javascripts/er/fancybox/fancy_loading.png +0 -0
- data/public/javascripts/er/fancybox/fancy_nav_left.png +0 -0
- data/public/javascripts/er/fancybox/fancy_nav_right.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_e.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_n.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_ne.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_nw.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_s.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_se.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_sw.png +0 -0
- data/public/javascripts/er/fancybox/fancy_shadow_w.png +0 -0
- data/public/javascripts/er/fancybox/fancy_title_left.png +0 -0
- data/public/javascripts/er/fancybox/fancy_title_main.png +0 -0
- data/public/javascripts/er/fancybox/fancy_title_over.png +0 -0
- data/public/javascripts/er/fancybox/fancy_title_right.png +0 -0
- data/public/javascripts/er/fancybox/fancybox-x.png +0 -0
- data/public/javascripts/er/fancybox/fancybox-y.png +0 -0
- data/public/javascripts/er/fancybox/fancybox.png +0 -0
- data/public/javascripts/er/fancybox/jquery.fancybox-1.3.4.css +359 -0
- data/public/javascripts/er/fancybox/jquery.fancybox-1.3.4.pack.js +46 -0
- data/public/javascripts/er/jquery-1.4.4.min.js +167 -0
- data/public/javascripts/er/jquery-ui-1.8.6.custom.min.js +477 -0
- data/public/javascripts/er/modernizr-1.5.min.js +28 -0
- data/public/javascripts/er/plugins.js +48 -0
- data/public/javascripts/er/rails.js +156 -0
- data/public/javascripts/er/script.js +50 -0
- data/public/stylesheets/.gitkeep +0 -0
- data/public/stylesheets/admin.css +417 -0
- data/public/stylesheets/boilerplate.css +264 -0
- data/public/stylesheets/handheld.css +7 -0
- data/public/stylesheets/login.css +125 -0
- data/public/stylesheets/skin.css +2 -0
- data/public/stylesheets/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/public/stylesheets/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/public/stylesheets/smoothness/images/ui-icons_222222_256x240.png +0 -0
- data/public/stylesheets/smoothness/images/ui-icons_2e83ff_256x240.png +0 -0
- data/public/stylesheets/smoothness/images/ui-icons_454545_256x240.png +0 -0
- data/public/stylesheets/smoothness/images/ui-icons_888888_256x240.png +0 -0
- data/public/stylesheets/smoothness/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/public/stylesheets/smoothness/jquery-ui-1.8.6.custom.css +479 -0
- data/spec/controllers/content_controller_spec.rb +132 -0
- data/spec/controllers/fields_controller_spec.rb +103 -0
- data/spec/controllers/models_controller_spec.rb +65 -0
- data/spec/controllers/pages_controller_spec.rb +40 -0
- data/spec/controllers/sections_controller_spec.rb +124 -0
- data/spec/dummy/Rakefile +7 -0
- data/spec/dummy/app/controllers/application_controller.rb +3 -0
- data/spec/dummy/app/helpers/application_helper.rb +2 -0
- data/spec/dummy/app/views/layouts/application.html.erb +14 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +45 -0
- data/spec/dummy/config/boot.rb +10 -0
- data/spec/dummy/config/database.yml +22 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +26 -0
- data/spec/dummy/config/environments/production.rb +49 -0
- data/spec/dummy/config/environments/test.rb +35 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/inflections.rb +10 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +7 -0
- data/spec/dummy/config/initializers/session_store.rb +8 -0
- data/spec/dummy/config/locales/en.yml +5 -0
- data/spec/dummy/config/routes.rb +58 -0
- data/spec/dummy/public/404.html +26 -0
- data/spec/dummy/public/422.html +26 -0
- data/spec/dummy/public/500.html +26 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/public/javascripts/application.js +2 -0
- data/spec/dummy/public/javascripts/controls.js +965 -0
- data/spec/dummy/public/javascripts/dragdrop.js +974 -0
- data/spec/dummy/public/javascripts/effects.js +1123 -0
- data/spec/dummy/public/javascripts/prototype.js +6001 -0
- data/spec/dummy/public/javascripts/rails.js +175 -0
- data/spec/dummy/public/stylesheets/.gitkeep +0 -0
- data/spec/dummy/script/rails +6 -0
- data/spec/engine_room_spec.rb +7 -0
- data/spec/factories.rb +32 -0
- data/spec/integration/navigation_spec.rb +9 -0
- data/spec/models/dog_spec.rb +14 -0
- data/spec/models/field_spec.rb +74 -0
- data/spec/models/section_spec.rb +70 -0
- data/spec/models/user_spec.rb +77 -0
- data/spec/routing/models_routing_spec.rb +66 -0
- data/spec/spec_helper.rb +39 -0
- data/spec/support/devise.rb +3 -0
- metadata +492 -0
@@ -0,0 +1 @@
|
|
1
|
+
<%= render 'form' %>
|
@@ -0,0 +1,47 @@
|
|
1
|
+
<%= render 'shared/error_messages', :object => @user %>
|
2
|
+
|
3
|
+
<%
|
4
|
+
form_path = (["edit_current_user","update_current_user"].include?(params[:action])) ? engine_room_current_user_path : nil
|
5
|
+
%>
|
6
|
+
|
7
|
+
<%= form_for [:engine_room, @user], :url => form_path, :html => { :id => "edit_user" } do |f| %>
|
8
|
+
<div class="field">
|
9
|
+
<%= f.label :username %>
|
10
|
+
<%= f.text_field :username %>
|
11
|
+
</div>
|
12
|
+
|
13
|
+
<div class="field">
|
14
|
+
<%= f.label :email %>
|
15
|
+
<%= f.text_field :email %>
|
16
|
+
</div>
|
17
|
+
|
18
|
+
<% if current_er_devise_user.is_admin? %>
|
19
|
+
<div class="field">
|
20
|
+
<%= f.label :is_admin, "Is admin?" %>
|
21
|
+
<%= f.check_box :is_admin %>
|
22
|
+
</div>
|
23
|
+
<% end %>
|
24
|
+
|
25
|
+
<div class="field">
|
26
|
+
<%= f.label :password %>
|
27
|
+
<%= f.password_field :password %>
|
28
|
+
<i>leave blank if you don't want to change it</i>
|
29
|
+
</div>
|
30
|
+
|
31
|
+
<div class="field">
|
32
|
+
<%= f.label :password_confirmation %>
|
33
|
+
<%= f.password_field :password_confirmation %>
|
34
|
+
</div>
|
35
|
+
|
36
|
+
<% if(@user.id) %>
|
37
|
+
<div class="field">
|
38
|
+
<%= f.label :current_password %>
|
39
|
+
<%= f.password_field :current_password %>
|
40
|
+
<i>we need your current password to confirm your changes</i>
|
41
|
+
</div>
|
42
|
+
<% end %>
|
43
|
+
|
44
|
+
<div class="actions">
|
45
|
+
<button type="submit"><%= t('.submit_button') %></button>
|
46
|
+
</div>
|
47
|
+
<% end %>
|
@@ -0,0 +1,11 @@
|
|
1
|
+
<%= render 'form' %>
|
2
|
+
|
3
|
+
<h2><%= t('.cancel_account') %></h2>
|
4
|
+
|
5
|
+
<%
|
6
|
+
delete_path = (["edit_current_user","update_current_user"].include?(params[:action])) ? engine_room_current_user_path : engine_room_user_path(@user)
|
7
|
+
%>
|
8
|
+
|
9
|
+
<div class="box">
|
10
|
+
<p>Unhappy? <%= link_to "Cancel my account", delete_path, :confirm => "Are you sure?", :method => :delete %>.</p>
|
11
|
+
</div>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
<%= link_to "Create New User", new_engine_room_user_path, :class => "button" %>
|
2
|
+
|
3
|
+
<div class="box">
|
4
|
+
<table>
|
5
|
+
<tr>
|
6
|
+
<th>ID</th>
|
7
|
+
<th>Username</th>
|
8
|
+
<th>Email</th>
|
9
|
+
<th>Admin?</th>
|
10
|
+
<th>Last SignedIn</th>
|
11
|
+
<th>Actions</th>
|
12
|
+
</tr>
|
13
|
+
<% @users.each do |user| %>
|
14
|
+
<tr>
|
15
|
+
<td><%= user.id %></td>
|
16
|
+
<td><%= link_to user.username, edit_engine_room_user_path(user) %></td>
|
17
|
+
<td><%= user.email %></td>
|
18
|
+
<td><%= user.is_admin==1 ? "yes" : "" %></td>
|
19
|
+
<td><%= user.last_sign_in_at.strftime("%b %d, %Y - %H:%M") %></td>
|
20
|
+
<td><%= link_to "delete", engine_room_user_path(user), :confirm => "Are you sure?", :method => :delete %></td>
|
21
|
+
</tr>
|
22
|
+
<% end %>
|
23
|
+
</table>
|
24
|
+
</div>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= render 'form' %>
|
@@ -0,0 +1,8 @@
|
|
1
|
+
<p>Hello <%= @resource.email %>!</p>
|
2
|
+
|
3
|
+
<p>Someone has requested a link to change your password, and you can do this through the link below.</p>
|
4
|
+
|
5
|
+
<p><%= link_to 'Change my password', edit_password_url(@resource, :reset_password_token => @resource.reset_password_token) %></p>
|
6
|
+
|
7
|
+
<p>If you didn't request this, please ignore this email.</p>
|
8
|
+
<p>Your password won't change until you access the link above and create a new one.</p>
|
@@ -0,0 +1,7 @@
|
|
1
|
+
<p>Hello <%= @resource.email %>!</p>
|
2
|
+
|
3
|
+
<p>Your account has been locked due to an excessive amount of unsuccessful sign in attempts.</p>
|
4
|
+
|
5
|
+
<p>Click the link below to unlock your account:</p>
|
6
|
+
|
7
|
+
<p><%= link_to 'Unlock my account', unlock_url(@resource, :unlock_token => @resource.unlock_token) %></p>
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<h2>Change your password</h2>
|
2
|
+
|
3
|
+
<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put }) do |f| %>
|
4
|
+
<%= devise_error_messages! %>
|
5
|
+
<%= f.hidden_field :reset_password_token %>
|
6
|
+
|
7
|
+
<p><%= f.label :password %><br />
|
8
|
+
<%= f.password_field :password %></p>
|
9
|
+
|
10
|
+
<p><%= f.label :password_confirmation %><br />
|
11
|
+
<%= f.password_field :password_confirmation %></p>
|
12
|
+
|
13
|
+
<p><%= f.submit "Change my password" %></p>
|
14
|
+
<% end %>
|
15
|
+
|
16
|
+
<%= render :partial => "devise/shared/links" %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<h2>/engine_room /forgot_password?</h2>
|
2
|
+
|
3
|
+
<%= devise_error_messages! %>
|
4
|
+
|
5
|
+
<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post }) do |f| %>
|
6
|
+
|
7
|
+
<p><%= f.label :email %><br />
|
8
|
+
<%= f.text_field :email %></p>
|
9
|
+
|
10
|
+
<p><button type="submmit">Send me reset password instructions</button></p>
|
11
|
+
<% end %>
|
12
|
+
|
13
|
+
<%= render :partial => "devise/shared/links" %>
|
@@ -0,0 +1,42 @@
|
|
1
|
+
<h1><%= t('.title') %></h1>
|
2
|
+
|
3
|
+
<%= devise_error_messages! %>
|
4
|
+
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :put }) do |f| %>
|
5
|
+
|
6
|
+
<div class="field">
|
7
|
+
<%= f.label :username %>
|
8
|
+
<%= f.text_field :username %>
|
9
|
+
</div>
|
10
|
+
|
11
|
+
<div class="field">
|
12
|
+
<%= f.label :email %>
|
13
|
+
<%= f.text_field :email %>
|
14
|
+
</div>
|
15
|
+
|
16
|
+
<div class="field">
|
17
|
+
<%= f.label :password %>
|
18
|
+
<%= f.password_field :password %>
|
19
|
+
<i>leave blank if you don't want to change it</i>
|
20
|
+
</div>
|
21
|
+
|
22
|
+
<div class="field">
|
23
|
+
<%= f.label :password_confirmation %>
|
24
|
+
<%= f.password_field :password_confirmation %>
|
25
|
+
</div>
|
26
|
+
|
27
|
+
<div class="field">
|
28
|
+
<%= f.label :current_password %>
|
29
|
+
<%= f.password_field :current_password %>
|
30
|
+
<i>we need your current password to confirm your changes</i>
|
31
|
+
</div>
|
32
|
+
|
33
|
+
<div class="actions">
|
34
|
+
<button type="submit"><%= t('.submit_button') %></button>
|
35
|
+
</div>
|
36
|
+
<% end %>
|
37
|
+
|
38
|
+
<h2><%= t('.cancel_account') %></h2>
|
39
|
+
|
40
|
+
<div class="box">
|
41
|
+
<p>Unhappy? <%= link_to "Cancel my account", registration_path(resource_name), :confirm => "Are you sure?", :method => :delete %>.</p>
|
42
|
+
</div>
|
@@ -0,0 +1,21 @@
|
|
1
|
+
<h2>Sign up</h2>
|
2
|
+
|
3
|
+
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f| %>
|
4
|
+
<%= devise_error_messages! %>
|
5
|
+
|
6
|
+
<p><%= f.label :username %><br />
|
7
|
+
<%= f.text_field :username %></p>
|
8
|
+
|
9
|
+
<p><%= f.label :email %><br />
|
10
|
+
<%= f.text_field :email %></p>
|
11
|
+
|
12
|
+
<p><%= f.label :password %><br />
|
13
|
+
<%= f.password_field :password %></p>
|
14
|
+
|
15
|
+
<p><%= f.label :password_confirmation %><br />
|
16
|
+
<%= f.password_field :password_confirmation %></p>
|
17
|
+
|
18
|
+
<p><%= f.submit "Sign up" %></p>
|
19
|
+
<% end %>
|
20
|
+
|
21
|
+
<%= render :partial => "devise/shared/links" %>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
<h2>/engine_room</h2>
|
2
|
+
|
3
|
+
<%- flash.each do |name, msg| -%>
|
4
|
+
<%= content_tag :div, msg, :id => "flash_#{name}" %>
|
5
|
+
<%- end -%>
|
6
|
+
|
7
|
+
<%= form_for(resource, :as => resource_name, :url => session_path(resource_name)) do |f| %>
|
8
|
+
|
9
|
+
<p><%= f.label :username %><br />
|
10
|
+
<%= f.text_field :username %></p>
|
11
|
+
|
12
|
+
<p><%= f.label :password %><br />
|
13
|
+
<%= f.password_field :password %></p>
|
14
|
+
|
15
|
+
<% if devise_mapping.rememberable? -%>
|
16
|
+
<p class="remember-me"><%= f.check_box :remember_me %> <%= f.label :remember_me %></p>
|
17
|
+
<% end -%>
|
18
|
+
|
19
|
+
<p><button type="submit">Sign in</button></p>
|
20
|
+
|
21
|
+
<% end %>
|
22
|
+
|
23
|
+
<%= render :partial => "devise/shared/links" %>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<%- if controller_name != 'sessions' %>
|
2
|
+
<%= link_to "Sign in", new_session_path(resource_name) %><br />
|
3
|
+
<% end -%>
|
4
|
+
|
5
|
+
<%- if devise_mapping.registerable? && controller_name != 'registrations' %>
|
6
|
+
<%= link_to "Sign up", new_registration_path(resource_name) %><br />
|
7
|
+
<% end -%>
|
8
|
+
|
9
|
+
<%- if devise_mapping.recoverable? && controller_name != 'passwords' %>
|
10
|
+
<%= link_to "Forgot your password?", new_password_path(resource_name) %><br />
|
11
|
+
<% end -%>
|
12
|
+
|
13
|
+
<%- if devise_mapping.confirmable? && controller_name != 'confirmations' %>
|
14
|
+
<%= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) %><br />
|
15
|
+
<% end -%>
|
16
|
+
|
17
|
+
<%- if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' %>
|
18
|
+
<%= link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) %><br />
|
19
|
+
<% end -%>
|
@@ -0,0 +1,103 @@
|
|
1
|
+
<!doctype html>
|
2
|
+
<html lang="en" class="no-js">
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
|
6
|
+
<!-- www.phpied.com/conditional-comments-block-downloads/ -->
|
7
|
+
<!--[if IE]><![endif]-->
|
8
|
+
|
9
|
+
<!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame
|
10
|
+
Remove this if you use the .htaccess -->
|
11
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
12
|
+
|
13
|
+
<title>engine_room</title>
|
14
|
+
<meta name="description" content="">
|
15
|
+
<meta name="author" content="Boris Searels">
|
16
|
+
|
17
|
+
<!-- Mobile Viewport Fix
|
18
|
+
j.mp/mobileviewport & davidbcalhoun.com/2010/viewport-metatag
|
19
|
+
device-width : Occupy full width of the screen in its current orientation
|
20
|
+
initial-scale = 1.0 retains dimensions instead of zooming out if page height > device height
|
21
|
+
maximum-scale = 1.0 retains dimensions instead of zooming in if page width < device width
|
22
|
+
-->
|
23
|
+
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0;">
|
24
|
+
|
25
|
+
|
26
|
+
<!-- Place favicon.ico and apple-touch-icon.png in the root of your domain and delete these references -->
|
27
|
+
<link rel="shortcut icon" href="/favicon.ico">
|
28
|
+
<link rel="apple-touch-icon" href="/apple-touch-icon.png">
|
29
|
+
|
30
|
+
<link id="bespin_base" href="/javascripts/bespin">
|
31
|
+
|
32
|
+
<!-- CSS : implied media="all" -->
|
33
|
+
<%= stylesheet_link_tag("boilerplate") %>
|
34
|
+
|
35
|
+
<link rel="stylesheet" href="/javascripts/er/fancybox/jquery.fancybox-1.3.4.css" type="text/css" media="screen" charset="utf-8">
|
36
|
+
<link rel="stylesheet" href="/stylesheets/smoothness/jquery-ui-1.8.6.custom.css" type="text/css" media="screen" charset="utf-8">
|
37
|
+
|
38
|
+
<!-- For the less-enabled mobile browsers like Opera Mini -->
|
39
|
+
<%= stylesheet_link_tag("handheld") %>
|
40
|
+
<%= stylesheet_link_tag("admin") %>
|
41
|
+
|
42
|
+
<!-- All JavaScript at the bottom, except for Modernizr which enables HTML5 elements & feature detects -->
|
43
|
+
<script src="/javascripts/er/modernizr-1.5.min.js"></script>
|
44
|
+
|
45
|
+
<%= csrf_meta_tag %>
|
46
|
+
</head>
|
47
|
+
|
48
|
+
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
|
49
|
+
|
50
|
+
<!--[if lt IE 7 ]> <body class="ie6"> <![endif]-->
|
51
|
+
<!--[if IE 7 ]> <body class="ie7"> <![endif]-->
|
52
|
+
<!--[if IE 8 ]> <body class="ie8"> <![endif]-->
|
53
|
+
<!--[if IE 9 ]> <body class="ie9"> <![endif]-->
|
54
|
+
<!--[if (gt IE 9)|!(IE)]><!--> <body> <!--<![endif]-->
|
55
|
+
|
56
|
+
<div id="wrapper">
|
57
|
+
|
58
|
+
<header id="header">
|
59
|
+
<div class="logo">/engine_room</div>
|
60
|
+
<div class="user-logout"><%= link_to current_er_devise_user.username, engine_room_current_user_path %> | <%= link_to t(:log_out), destroy_er_devise_user_session_path %></div>
|
61
|
+
<div class="preview"><a href="/" target="_blank"><%= t(:preview) %></a></div>
|
62
|
+
</header>
|
63
|
+
|
64
|
+
<nav id="nav">
|
65
|
+
<div>
|
66
|
+
<ul>
|
67
|
+
<li><%= link_to t('nav.dashboard'), engine_room_root_path %></li>
|
68
|
+
<li><%= link_to t('nav.content'), engine_room_content_path %></li>
|
69
|
+
<% if authorized? %><li><%= link_to t('nav.sections'), engine_room_sections_path %></li><% end %>
|
70
|
+
<% if authorized? %><li><%= link_to t('nav.models'), engine_room_models_path %></li><% end %>
|
71
|
+
<% if authorized? %><li><%= link_to t('nav.user'), engine_room_users_path %></li><% end %>
|
72
|
+
</ul>
|
73
|
+
</div>
|
74
|
+
</nav>
|
75
|
+
|
76
|
+
<%= render :partial => "shared/content_layout_selector" %>
|
77
|
+
|
78
|
+
<footer>
|
79
|
+
<hr />
|
80
|
+
<p class="quiet bottom">© 2010 <a href="http://github.com/bozz/engine_room" target="parent">engine_room</a>.</p>
|
81
|
+
</footer>
|
82
|
+
|
83
|
+
</div><!-- #wrapper -->
|
84
|
+
<%= debug(params) if !Rails.env.development? %>
|
85
|
+
|
86
|
+
<!-- Javascript at the bottom for fast page loading -->
|
87
|
+
|
88
|
+
<!-- Grab Google CDN's jQuery. fall back to local if necessary -->
|
89
|
+
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script>
|
90
|
+
<script>!window.jQuery && document.write('<script src="/javascripts/er/jquery-1.4.4.min.js"><\/script>')</script>
|
91
|
+
|
92
|
+
<script src="/javascripts/er/jquery-ui-1.8.6.custom.min.js?v=1"></script>
|
93
|
+
<script src="/javascripts/er/fancybox/jquery.fancybox-1.3.4.pack.js?v=1"></script>
|
94
|
+
<script src="/javascripts/er/rails.js?v=1"></script>
|
95
|
+
<script src="/javascripts/er/plugins.js?v=1"></script>
|
96
|
+
<script src="/javascripts/er/script.js?v=1"></script>
|
97
|
+
|
98
|
+
<!--[if lt IE 7 ]>
|
99
|
+
<script src="/javascripts/er/dd_belatedpng.js?v=1"></script>
|
100
|
+
<![endif]-->
|
101
|
+
|
102
|
+
</body>
|
103
|
+
</html>
|
@@ -0,0 +1,71 @@
|
|
1
|
+
<!doctype html>
|
2
|
+
<html lang="en" class="no-js">
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
|
6
|
+
<!-- www.phpied.com/conditional-comments-block-downloads/ -->
|
7
|
+
<!--[if IE]><![endif]-->
|
8
|
+
|
9
|
+
<!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame
|
10
|
+
Remove this if you use the .htaccess -->
|
11
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
12
|
+
|
13
|
+
<title>engine_room</title>
|
14
|
+
<meta name="description" content="">
|
15
|
+
<meta name="author" content="Boris Searels">
|
16
|
+
|
17
|
+
<!-- Mobile Viewport Fix
|
18
|
+
j.mp/mobileviewport & davidbcalhoun.com/2010/viewport-metatag
|
19
|
+
device-width : Occupy full width of the screen in its current orientation
|
20
|
+
initial-scale = 1.0 retains dimensions instead of zooming out if page height > device height
|
21
|
+
maximum-scale = 1.0 retains dimensions instead of zooming in if page width < device width
|
22
|
+
-->
|
23
|
+
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0;">
|
24
|
+
|
25
|
+
|
26
|
+
<!-- Place favicon.ico and apple-touch-icon.png in the root of your domain and delete these references -->
|
27
|
+
<link rel="shortcut icon" href="/favicon.ico">
|
28
|
+
<link rel="apple-touch-icon" href="/apple-touch-icon.png">
|
29
|
+
|
30
|
+
<!-- CSS : implied media="all" -->
|
31
|
+
<%= stylesheet_link_tag("boilerplate") %>
|
32
|
+
|
33
|
+
<!-- For the less-enabled mobile browsers like Opera Mini -->
|
34
|
+
<%= stylesheet_link_tag("handheld") %>
|
35
|
+
<%= stylesheet_link_tag("login") %>
|
36
|
+
|
37
|
+
<!-- All JavaScript at the bottom, except for Modernizr which enables HTML5 elements & feature detects -->
|
38
|
+
<script src="/javascripts/modernizr-1.5.min.js"></script>
|
39
|
+
|
40
|
+
<%= csrf_meta_tag %>
|
41
|
+
</head>
|
42
|
+
|
43
|
+
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
|
44
|
+
|
45
|
+
<!--[if lt IE 7 ]> <body class="ie6"> <![endif]-->
|
46
|
+
<!--[if IE 7 ]> <body class="ie7"> <![endif]-->
|
47
|
+
<!--[if IE 8 ]> <body class="ie8"> <![endif]-->
|
48
|
+
<!--[if IE 9 ]> <body class="ie9"> <![endif]-->
|
49
|
+
<!--[if (gt IE 9)|!(IE)]><!--> <body> <!--<![endif]-->
|
50
|
+
|
51
|
+
<div id="wrapper">
|
52
|
+
<div id="content">
|
53
|
+
|
54
|
+
<%= yield %>
|
55
|
+
|
56
|
+
</div><!-- #content -->
|
57
|
+
</div><!-- #wrapper -->
|
58
|
+
|
59
|
+
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
|
60
|
+
<script>!window.jQuery && document.write('<script src="/javascripts/jquery-1.4.2.min.js"><\/script>')</script>
|
61
|
+
|
62
|
+
<script>
|
63
|
+
|
64
|
+
$(function() {
|
65
|
+
$('#er_devise_user_username').focus();
|
66
|
+
});
|
67
|
+
|
68
|
+
</script>
|
69
|
+
|
70
|
+
</body>
|
71
|
+
</html>
|