diff --git a/app/views/application/maintenance.html.erb b/app/views/application/maintenance.html.erb index 034dc998e..8f9be4c91 100755 --- a/app/views/application/maintenance.html.erb +++ b/app/views/application/maintenance.html.erb @@ -1,22 +1,22 @@
- Autolab is currently down for regular maintenance. Nothing in - particular is wrong; we just need some time to make the site better - for you. -
-- We try to schedule maintenance for times when few people are using - the site, and we also try to be done with maintenance as quickly as - possible. If this is a major disruption for you, be sure to let your - instructor know. We're sorry for the inconveniences, but hopefully - when Autolab comes back on it'll be better than ever before! -
- -
-
- Thanks!
-
+ Autolab is currently down for regular maintenance. Nothing in + particular is wrong; we just need some time to make the site better + for you. +
++ We try to schedule maintenance for times when few people are using + the site, and we also try to be done with maintenance as quickly as + possible. If this is a major disruption for you, be sure to let your + instructor know. We're sorry for the inconveniences, but hopefully + when Autolab comes back on it'll be better than ever before! +
+ +
+
+ Thanks!
+
- <%= f.label(:grade_type, :value => AssessmentUserDatum::NORMAL) do %> + <%= f.label(:grade_type, value: AssessmentUserDatum::NORMAL) do %> <%= f.radio_button :grade_type, AssessmentUserDatum::NORMAL %> Normal <% end %>
- <%= f.label(:grade_type, :value => AssessmentUserDatum::ZEROED) do %> + <%= f.label(:grade_type, value: AssessmentUserDatum::ZEROED) do %> <%= f.radio_button :grade_type, AssessmentUserDatum::ZEROED %> Zero <% end %>
- <%= f.label(:grade_type, :value => AssessmentUserDatum::EXCUSED) do %> + <%= f.label(:grade_type, value: AssessmentUserDatum::EXCUSED) do %> <%= f.radio_button :grade_type, AssessmentUserDatum::EXCUSED %> Excused <% end %>
- <%= f.submit "Save" , {:class=>"btn primary"} %> + <%= f.submit "Save", { class: "btn primary" } %> <% end %><% if attachment.assessment.nil? %> - <%= link_to [@course, attachment] do %> + <%= link_to course_attachment_path(@course, attachment) do %> file_download <%= attachment.name %> <% unless attachment.released %> (Not Released) <% end %> <% end %> - <% else %> - <%= link_to [@course, attachment.assessment, attachment] do %> + <% else %> + <%= link_to course_assessment_attachment_path(@course, attachment.assessment, attachment) do %> file_download <%= attachment.name %> <% unless attachment.released %> @@ -26,11 +26,17 @@ <% if @cud.instructor? %> <% if attachment.assessment.nil? %> - <%= link_to 'mode_edit'.html_safe, [:edit, @course, attachment], {class:"small"} %> - <%= link_to 'delete'.html_safe, [@course, attachment], {method: :delete, class:"small"} %> + <%= link_to 'mode_edit'.html_safe, + edit_course_attachment_path(@course, attachment), { class: "small" } %> + <%= link_to 'delete'.html_safe, + course_attachment_path(@course, attachment), { method: :delete, class: "small" } %> <% else %> - <%= link_to 'mode_edit'.html_safe, [:edit, @course, attachment.assessment, attachment], {class:"small"} %> - <%= link_to 'delete'.html_safe, [@course, attachment.assessment, attachment], {method: :delete, class:"small"} %> + <%= link_to 'mode_edit'.html_safe, + edit_course_assessment_attachment_path(@course, attachment.assessment, attachment), + { class: "small" } %> + <%= link_to 'delete'.html_safe, + course_assessment_attachment_path(@course, attachment.assessment, attachment), + { method: :delete, class: "small", data: { confirm: "Are you sure you want to delete this attachment?" } } %> <% end %> <% end %> diff --git a/app/views/attachments/_form.html.erb b/app/views/attachments/_form.html.erb index e8246bd9c..2e1c8d5d1 100644 --- a/app/views/attachments/_form.html.erb +++ b/app/views/attachments/_form.html.erb @@ -1,32 +1,26 @@ <%= form_for @attachment, as: :attachment, url: path, builder: FormBuilderWithDateTimeInput do |f| %> <%= f.error_messages %> -