refactoring views
This commit is contained in:
@@ -1,18 +1,19 @@
|
||||
<div id="c-dmails">
|
||||
|
||||
<div id="a-index">
|
||||
<h1>Messages</h1>
|
||||
|
||||
<%= render "search" %>
|
||||
|
||||
<table>
|
||||
<tbody>
|
||||
<% @dmails.each do |dmail| %>
|
||||
<% if params[:folder] == "sent" %>
|
||||
<%= render "sent", :dmail => dmail %>
|
||||
<% else %>
|
||||
<%= render "received", :dmail => dmail %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<h1>Messages</h1>
|
||||
|
||||
<%= render "search" %>
|
||||
|
||||
<table>
|
||||
<tbody>
|
||||
<% @dmails.each do |dmail| %>
|
||||
<% if params[:folder] == "sent" %>
|
||||
<%= render :partial => "sent", :locals => {:dmail => dmail} %>
|
||||
<% else %>
|
||||
<%= render :partial => "received", :locals => {:dmail => dmail} %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
@@ -1,2 +1,7 @@
|
||||
<h1>New Message</h1>
|
||||
<%= render :partial => "form", :locals => {:dmail => @dmail} %>
|
||||
<div id="c-dmails">
|
||||
<div id="a-new">
|
||||
<h1>New Message</h1>
|
||||
<%= render "form", :dmail => @dmail %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
<div class="dmails">
|
||||
<div class="show">
|
||||
<div class="c-dmails">
|
||||
<div class="a-show">
|
||||
<div class="dmail">
|
||||
<h1><%= @dmail.title %></h1>
|
||||
<%= format_text(@dmail.body) %>
|
||||
|
||||
<p>
|
||||
<%= link_to "Respond", new_dmail_path(:respond_to_id => @dmail) %>
|
||||
| <%= link_to "Forward", new_dmail_path(:respond_to_id => @dmail, :forward => true) %>
|
||||
|
||||
Reference in New Issue
Block a user