mirror of
https://github.com/internetee/registry.git
synced 2025-07-23 03:06:14 +02:00
commit
e37647477c
5 changed files with 66 additions and 82 deletions
|
@ -1,24 +1,8 @@
|
|||
<% if flash[:notice] %>
|
||||
<div class="alert alert-success alert-dismissible">
|
||||
<button class="close" data-dismiss="alert" type=button><span>×</span></button>
|
||||
<% if flash[:notice].respond_to?(:join) %>
|
||||
<p><%= flash[:notice].join('<br>').html_safe %></p>
|
||||
<% else %>
|
||||
<p><%= flash[:notice] %></p>
|
||||
<% end %>
|
||||
<% display = (flash[:notice] || flash[:alert] || flash[:warning]) ? 'block' : 'none' %>
|
||||
<div id="flash" style="display: <%= display %>;">
|
||||
<% type = (flash[:notice]) ? 'bg-success' : 'bg-danger' %>
|
||||
<% type = 'bg-warning' if flash[:warning] %>
|
||||
<div class="<%= type %> alert">
|
||||
<%= flash[:notice] || flash[:alert] || flash[:warning] %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% if flash[:alert] %>
|
||||
<div class="alert alert-danger alert-dismissible">
|
||||
<button class="close" data-dismiss="alert" type=button><span>×</span></button>
|
||||
<p><%= flash[:alert] %></p>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% if flash[:info] %>
|
||||
<div class="alert alert-info alert-dismissible">
|
||||
<button class="close" data-dismiss="alert" type=button><span>×</span></button>
|
||||
<p><%= flash[:info] %></p>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
|
@ -65,7 +65,7 @@
|
|||
</div>
|
||||
</nav>
|
||||
<div class="container">
|
||||
<%= render 'shared/flash' %>
|
||||
<%= render 'flash_messages' %>
|
||||
<%= yield %>
|
||||
</div>
|
||||
<footer class="footer">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue