Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

add lock icon

  • Loading branch information...
commit f33cd0317f168d8b4cface970848bf471d7a0285 1 parent 128cec8
Jonathan Weiss jweiss authored
4 app/helpers/application_helper.rb
@@ -9,6 +9,10 @@ def error_flash(text)
9 9 render(:partial => 'layouts/flash_error', :locals => {:text => text})
10 10 end
11 11
  12 + def locking_flash(text)
  13 + render(:partial => 'layouts/flash_locking', :locals => {:text => text})
  14 + end
  15 +
12 16 def flashed_errors(object_name)
13 17 obj = instance_variable_get("@#{object_name}")
14 18 return nil if obj.errors.blank?
2  app/views/deployments/new.html.erb
... ... @@ -1,6 +1,6 @@
1 1 <% if current_stage.locked? %>
2 2 <% content_for(:flash_content) do %>
3   - <%= error_flash( render :partial => 'lock_info', :locals => {:stage => current_stage, :deployment => @deployment}) %>
  3 + <%= locking_flash( render :partial => 'lock_info', :locals => {:stage => current_stage, :deployment => @deployment}) %>
4 4 <% end %>
5 5 <% end %>
6 6
7 app/views/layouts/_flash_locking.html.erb
... ... @@ -0,0 +1,7 @@
  1 +<div class="flash_box">
  2 + <div class="flash_box_top"></div>
  3 + <div id="flash" class="flash_box_middle">
  4 + <div class="flash_text_locking"><%= text %></div>
  5 + </div>
  6 + <div class="flash_box_bottom"></div>
  7 +</div>
7 app/views/stylesheets/application.html.erb
@@ -441,6 +441,13 @@ div.small_box_bottom {
441 441 background-position: 20px 0px;
442 442 }
443 443
  444 +.flash_text_locking {
  445 + color: #A40008;
  446 + padding: 15px 5px 12px 70px;
  447 + background: url(<%= image_path('peritor_theme/locked.gif')%>) left center no-repeat;
  448 + background-position: 20px 0px;
  449 +}
  450 +
444 451 div.flash_box{
445 452 clear: both;
446 453 margin-top: 0px;
BIN  public/images/peritor_theme/locked.gif

0 comments on commit f33cd03

Please sign in to comment.
Something went wrong with that request. Please try again.