<% content_for :page_specific_css do %> <%= stylesheet_link_tag "lib/wrap-nav"%> <%= stylesheet_link_tag "lib/main-forms"%> <%= stylesheet_link_tag "lib/fileupload"%> <%= stylesheet_link_tag "lib/togglebox"%> <% end %> <%= form_for @master_password, :url => {:action => "update_master_password"}, :method => "patch", :html => {:class => "form-horizontal main-forms"} do |f| %>
<% if @master_password.password_digest.nil? %>
No Password has been set. Please set a new password immediately!!!
<% else %> <% days = @master_password.changed_days_ago %> <% if days > 15 %>
Its been <%= days %> days since the master password has been changed. Please set a new password immediately!!!
<% else %>
Its been <%= days %> day<%= days > 1 ? "s" : "" %> since the master password has been changed.
<% end %> <% end %>
<%= f.password_field :password, :class=>"input-large", :autocomplete=>"off" %>
<%= f.submit "Update", :class => "btn btn-primary" %>
<% end %>