Skip to content

Commit efc6e5b

Browse files
committed
add created and verified date to the admin profile page
1 parent 09f89ef commit efc6e5b

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

app/views/admin/users/_form.html.erb

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,32 @@
7979
</div>
8080
</div>
8181

82+
<div class="form-group">
83+
<%= f.label :created_at, "Account Created", class: "col-sm-2 control-label" %>
84+
<div class="col-sm-10">
85+
<p class="form-control-static">
86+
<%= @user.created_at.strftime('%B %d, %Y at %l:%M %p %Z') %>
87+
</p>
88+
</div>
89+
</div>
90+
91+
<% if @user.confirmed_faculty? %>
92+
<div class="form-group">
93+
<%= f.label :faculty_verified_at, "Faculty Verified", class: "col-sm-2 control-label" %>
94+
<div class="col-sm-10">
95+
<p class="form-control-static">
96+
<% verification_log = @user.security_logs.where(event_type: [:fv_success_by_sheerid, :faculty_verified, :faculty_verified_by_sheerid, :salesforce_updated_faculty_status]).last %>
97+
<% if verification_log %>
98+
<%= verification_log.created_at.strftime('%B %d, %Y at %l:%M %p %Z') %>
99+
(<%= verification_log.event_type.humanize %>)
100+
<% else %>
101+
Confirmed (date not available)
102+
<% end %>
103+
</p>
104+
</div>
105+
</div>
106+
<% end %>
107+
82108
<div class="form-group">
83109
<%= f.label :email_addresses, class: "col-sm-2 control-label" %>
84110
<ul class="col-sm-10 form-control-static">

0 commit comments

Comments
 (0)