2015-01-06 20:33:11 +01:00
|
|
|
<%= render partial: 'flash' %>
|
2014-11-09 22:53:39 +01:00
|
|
|
<div class="row">
|
2015-01-09 19:15:48 +01:00
|
|
|
<div class="user_info">
|
2015-02-12 16:14:11 +01:00
|
|
|
<h2><%= @user.nickname %> (<%= @user.full_name %>)</h2>
|
2015-02-12 16:19:41 +01:00
|
|
|
<h5><%= link_to "[Edit profile]" , edit_user_registration_path if current_user == @user%></h5>
|
2015-01-09 19:15:48 +01:00
|
|
|
<h4>Balance: <%= euro(@user.balance) %></h4>
|
|
|
|
</div>
|
2014-11-23 21:12:31 +01:00
|
|
|
|
2015-01-09 19:15:48 +01:00
|
|
|
<% if @user.orders.any? %>
|
2015-01-13 13:06:42 +01:00
|
|
|
<div class="col-md-6">
|
|
|
|
<h3>Orders (<%= @user.orders_count %>)</h3>
|
2015-02-09 13:23:38 +01:00
|
|
|
<%= render @orders %>
|
|
|
|
<%= will_paginate @orders %>
|
2015-01-09 19:15:48 +01:00
|
|
|
</div>
|
|
|
|
<% end %>
|
2015-01-13 13:06:42 +01:00
|
|
|
|
|
|
|
<div class="col-md-6">
|
|
|
|
<h3>Products</h3>
|
|
|
|
<%= render partial: "products/product_row", collection: @products, as: :product %>
|
|
|
|
<h4>Categories</h4>
|
|
|
|
<%= render partial: "products/category", collection: @categories %>
|
|
|
|
</div>
|
2014-11-23 21:12:31 +01:00
|
|
|
</div>
|