-
-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make evaluation creation a full stepper
Also change the edit page to lead back to a stepper.
- Loading branch information
Showing
23 changed files
with
368 additions
and
393 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
import { initDeadlinePicker } from "series.js"; | ||
import { interceptAddMultiUserClicks, initCheckboxes, initCheckbox } from "evaluation.ts"; | ||
import { initCheckbox, initEvaluationStepper } from "evaluation.ts"; | ||
import FeedbackActions from "feedback/actions"; | ||
|
||
window.dodona.initDeadlinePicker = initDeadlinePicker; | ||
window.dodona.initCheckboxes = initCheckboxes; | ||
window.dodona.initCheckbox = initCheckbox; | ||
window.dodona.interceptAddMultiUserClicks = interceptAddMultiUserClicks; | ||
window.dodona.FeedbackActions = FeedbackActions; | ||
window.dodona.initEvaluationStepper = initEvaluationStepper; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
<div class="stepper-part evaluation-user-select"> | ||
<div class="row"> | ||
<div class="col-lg-6 col-md-12 order-lg-1"> | ||
<div class="callout callout-info"> | ||
<h4><%= t('evaluations.add_users.explanation_title') %></h4> | ||
<p><%= t('evaluations.add_users.explanation_part1') %></p> | ||
<p><%= t('evaluations.add_users.explanation_part2') %></p> | ||
</div> | ||
</div> | ||
<div class="col-lg-6 col-md-12 order-lg-0"> | ||
<div class="card-subtitle"> | ||
<h4><%= t('evaluations.edit_users.mass_edit') %></h4> | ||
</div> | ||
<div class="row"> | ||
<div class="col-6"> | ||
<div class="user-select-option"> | ||
<%= link_to set_multi_user_evaluation_path(@evaluation, type: 'enrolled', format: :js) do %> | ||
<%= t('evaluations.add_users.users_in_course_html', count: @user_count_course) %> | ||
<div class="clearfix"></div> | ||
<i class="loader mdi mdi-spin mdi-loading hidden"></i> | ||
<div class="button btn-text"><%= t('.select_users') %></div> | ||
<% end %> | ||
</div> | ||
</div> | ||
<div class="col-6"> | ||
<div class="user-select-option"> | ||
<%= link_to set_multi_user_evaluation_path(@evaluation, type: 'submitted', format: :js) do %> | ||
<%= t('evaluations.add_users.users_submitted_html', count: @user_count_series) %> | ||
<div class="clearfix"></div> | ||
<i class="loader mdi mdi-spin mdi-loading hidden"></i> | ||
<div class="button btn-text"><%= t('.select_users') %></div> | ||
<% end %> | ||
</div> | ||
</div> | ||
</div> | ||
<p class="selected-users"> | ||
<span id="users-count-wrapper"> | ||
<%= t("evaluations.edit_users.users_selected_html", count: @evaluation.users.count) %> | ||
</span> | ||
<%= link_to t('evaluations.edit_users.clear'), set_multi_user_evaluation_path(@evaluation, type: 'none', format: :js), remote: true, method: :post %>. | ||
</p> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="stepper-part"> | ||
<div class="card-supporting-text"> | ||
<%= render partial: 'layouts/searchbar', locals: { | ||
baseUrl: edit_evaluation_url(@evaluation), | ||
eager: false, | ||
course_labels: @course_labels, | ||
institutions: Institution.of_course_by_members(@course), | ||
} %> | ||
<div id="users-table-wrapper"> | ||
<%= render partial: 'members_table', | ||
locals: { | ||
course_memberships: @course_memberships, | ||
pagination_opts: @pagination_opts, | ||
confirm: false | ||
} %> | ||
</div> | ||
</div> | ||
</div> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
<div class="panel-body"> | ||
<div class="stepper-part"> | ||
<div class="score-item-toolbar"> | ||
<div class="score-item-toolbar-tools"> | ||
<p class="description-text"> | ||
<%= t 'score_items.new.second_explanation' %><br> | ||
<span class="summary-text"> | ||
<%= t('score_items.new.summary_html', count: @evaluation.score_items.count, score: format_score(@evaluation.maximum_score)) %> | ||
</span> | ||
</p> | ||
<div class="btn-group actions"> | ||
<a class="btn btn-icon dropdown-toggle" data-bs-toggle="dropdown"> | ||
<i class="mdi mdi-dots-vertical"></i> | ||
</a> | ||
<ul class="dropdown-menu dropdown-menu-end"> | ||
<li> | ||
<%= link_to modify_grading_visibility_evaluation_path(@evaluation, visible: true), method: :post, class: "dropdown-item" do %> | ||
<i class="mdi mdi-eye mdi-18"></i> | ||
<%= t("score_items.new.show_all") %> | ||
<% end %> | ||
</li> | ||
<li> | ||
<%= link_to modify_grading_visibility_evaluation_path(@evaluation, visible: false), method: :post, class: "dropdown-item" do %> | ||
<i class="mdi mdi-eye-off mdi-18"></i> | ||
<%= t("score_items.new.hide_all") %> | ||
<% end %> | ||
</li> | ||
<li> | ||
<a href="#add-score-item-to-all" data-bs-toggle="modal" class="dropdown-item"> | ||
<i class="mdi mdi-table-row-plus-after mdi-18"></i> | ||
<%= t 'score_items.new.add_all' %> | ||
</a> | ||
</li> | ||
</ul> | ||
</div> | ||
</div> | ||
</div> | ||
<% @evaluation.evaluation_exercises.each do |evaluation_exercise| %> | ||
<div id="card-<%= evaluation_exercise.id %>"> | ||
<%= render 'score_items/exercise', evaluation_exercise: evaluation_exercise, new: nil %> | ||
</div> | ||
<% end %> | ||
</div> | ||
<div class="stepper-actions stepper-border"> | ||
<%= link_to t('score_items.new.to_evaluation'), evaluation_path(@evaluation), class: "btn btn-text btn-primary" %> | ||
</div> | ||
</div> | ||
<div class="modal fade" id="add-score-item-to-all" tabindex="-1" role="dialog"> | ||
<div class="modal-dialog" role="document"> | ||
<%= render 'score_items/form', | ||
score_item: ScoreItem.new, | ||
evaluation_exercise: nil, | ||
title: t("score_items.new.add_all"), | ||
form_options: { url: add_all_evaluation_score_items_path(@evaluation), remote: true } %> | ||
</div> | ||
</div> |
Oops, something went wrong.