-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshow.html.erb
More file actions
53 lines (43 loc) · 1.24 KB
/
show.html.erb
File metadata and controls
53 lines (43 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
<h2><%= @profile.name %>'s Profile!</h2>
<div>
<%= link_to "Edit Profile", edit_profile_path(@profile) %>
</div>
<div>
<%= image_tag @profile.avatar.url, width: "400" %>
</div>
<div>
<strong>About <%= @profile.name %>: </strong><%= @profile.about %>
</div>
<div>
<strong>Birthday: </strong> <%= time_tag(@profile.birthday) %>
</div>
<div>
<strong>Start Date: </strong> <%= time_tag(@profile.start_date) %>
</div>
<div>
<strong>Office Branch: </strong> <%= @office_branch.location %>
</div>
<div>
<strong>Department: </strong> <%= @department.name %>
</div>
<div>
<strong>Job Title: </strong> <%= @user.current_job.name %>
</div>
<div>
<%= link_to "Delete Profile", @profile, method: :delete %>
</div>
<div>
<% if @user.has_any_contact_information? %>
<%= link_to "Show Contact Information", user_contact_information_path(@user) %>
<% else %>
<%= link_to "Create Contact Information", edit_user_contact_information_path(@user) %>
<% end %>
</div>
<div>
<% if @user.salaries.present? %>
Current Salary: <%= number_to_currency(@user.current_salary) %>
<p> <%= link_to "Show Past Salaries", user_salaries_path(@user) %> </p>
<% else %>
<%= link_to "Create Salary", new_user_salary_path(@user) %>
<% end %>
</div>