lock_explanation.mustache 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. <%
  2. # Copyright (C) 2014 - present Instructure, Inc.
  3. #
  4. # This file is part of Canvas.
  5. #
  6. # Canvas is free software: you can redistribute it and/or modify it under
  7. # the terms of the GNU Affero General Public License as published by the Free
  8. # Software Foundation, version 3 of the License.
  9. #
  10. # Canvas is distributed in the hope that it will be useful, but WITHOUT ANY
  11. # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
  12. # A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
  13. # details.
  14. #
  15. # You should have received a copy of the GNU Affero General Public License along
  16. # with this program. If not, see <http://www.gnu.org/licenses/>.
  17. %>
  18. <% content_for :head, include_common_stylesheets %>
  19. {{> views/layouts/head}}
  20. <body>
  21. <div id="content" class="file_preview_container">
  22. <h2><%= @file.display_name %></h2>
  23. <div>
  24. <% if @file.folder && @file.folder.locked? %>
  25. <%= t 'messages.folder_locked', "The folder \"%{folder},\" which includes this file, has been locked.", :folder => @file.folder.name %>
  26. <% else %>
  27. <%= @lock_info.is_a?(Hash) ? lock_explanation(@lock_info, 'file', @context) : t('messages.file_locked', "This file has not been unlocked yet.") %>
  28. <% end %>
  29. </div>
  30. </div>
  31. {{> views/layouts/foot}}
  32. </body>