<%= form_for([:admin, @user]) do |f| %>

Prepare Nutritional Plan

Name Email Blood Type
<%= @user.name %> <%= @user.email %> <%= @blood_type?@blood_type:'unset' %> <%= link_to 'Edit', edit_admin_user_path(@user) %> | <%= link_to 'Destroy', [:admin, @user], :confirm => 'Are you sure?', :method => :delete %>

Meal Plans

[<%= link_to 'New', new_admin_meal_plan_path(:id => @user.id) %>]

<% @meal_plans.each do |m| %> <% end %>
Created Name # of Meals Program
<%=m.created_at.strftime("%B %d, %Y")%> <%=m.name.nil? ? 'No Name' : m.name %> <%=m.meal_specs.length%> <%=m.enrollment_id.nil? ? 'No Enrollment' : Enrollment.find(m.enrollment_id).program_name %> <%= link_to 'Edit', [:edit_admin, m] %> | <%= link_to 'Destroy', [:admin, m], :confirm => 'Are you sure?', :method => :delete %>
<% m.meal_specs.each do |s| %> <% end %>
Meal Protein Starchy Carb Fiberous Carb
<%= s.position %> <%= s.protein %> <%= s.starchy_carbs %> <%= s.fiberous_carbs %>

Supplement Plans

[<%= link_to 'New', new_admin_supplement_plan_path(:id => @user.id) %>]

<% @supplement_plans.each do |s| %> <%end%>
Created Meal Plan
<%=s.created_at.strftime("%B %d, %Y")%> <%=s.meal_plan_id %> <%= link_to 'Edit', [:edit_admin, s] %> | <%= link_to 'Destroy', [:admin, s], :confirm => 'Are you sure?', :method => :delete %>
<% s.user_supplements.each do |us| %> <% end %>
Supplement Amount Instruction
<%= us.supplement_name %> <%=us.amount%><%= MeasurementUnit.find(us.measurement_unit_id).name %> <%= InstructionTime.find(us.instruction_time_id).name %>