improves styles for admin budgets show

This commit is contained in:
Alberto Garcia Cabeza
2017-01-04 17:02:27 +01:00
parent e1367d4463
commit 46d96e5a18
3 changed files with 104 additions and 114 deletions

View File

@@ -1,5 +1,4 @@
<div class="small-12 column">
<table>
<table>
<thead>
<tr>
<th colspan="3" class="with-button">
@@ -72,5 +71,4 @@
<% end %>
<!-- /. headings list -->
</tbody>
</table>
</div>
</table>

View File

@@ -1,17 +1,16 @@
<div class="small-12 column">
<h3 class="inline-block"><%= t('admin.budgets.show.groups') %></h3>
<% if groups.blank? %>
<h3 class="inline-block"><%= t('admin.budgets.show.groups') %></h3>
<% if groups.blank? %>
<div class="callout primary">
<%= t("admin.budgets.form.no_groups") %>
<strong><%= link_to t("admin.budgets.form.add_group"), "#",
class: "js-toggle-link",
data: { "toggle-selector" => "#new-group-form" } %></strong>
</div>
<% else %>
<% else %>
<%= link_to t("admin.budgets.form.add_group"), "#", class: "button float-right js-toggle-link", data: { "toggle-selector" => "#new-group-form" } %>
<% end %>
<% end %>
<%= form_for [:admin, @budget, Budget::Group.new], html: {id: "new-group-form", style: "display:none"}, remote: true do |f| %>
<%= form_for [:admin, @budget, Budget::Group.new], html: {id: "new-group-form", style: "display:none"}, remote: true do |f| %>
<div class="input-group">
<span class="input-group-label">
<label><%= f.label :name,t("admin.budgets.form.group") %></label>
@@ -24,11 +23,10 @@
<%= f.submit t("admin.budgets.form.create_group"), class: "button success" %>
</div>
</div>
<% end %>
<% end %>
<% groups.each do |group| %>
<div class="row" id="<%= dom_id(group) %>">
<% groups.each do |group| %>
<div id="<%= dom_id(group) %>">
<%= render "admin/budgets/group", group: group, headings: group.headings %>
</div>
<% end %>
</div>
<% end %>

View File

@@ -1,16 +1,10 @@
<div class="row">
<div class="small-12 medium-9 column">
<h2><%= @budget.name %> <small><%= link_to(t('shared.edit'), edit_admin_budget_path(@budget)) %></small></h2>
<%= link_to admin_budgets_path do %>
<span class="icon-angle-left"></span>
<%= t('shared.back') %>
<% end %>
<%= @budget.description %>
<h2><%= @budget.name %></h2>
<p>
<strong><%= t('admin.budgets.show.phase') %>:</strong> <%= t("budget.phase.#{@budget.phase}") %> |
<strong><%= t('admin.budgets.show.currency') %>:</strong> <%= @budget.currency_symbol %>
</p>
</div>
</div>
<div id="<%= dom_id @budget %>_groups" class="row">
<div id="<%= dom_id @budget %>_groups">
<%= render "groups", groups: @budget.groups %>
</div>