Grading Boundaries Wrong in Supervisor View #98
@ -2,7 +2,77 @@
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
|
||||
<body>
|
||||
<wicket:panel>
|
||||
<wicket:container wicket:id="from2017">
|
||||
<wicket:container wicket:id="from202411">
|
||||
<div wicket:id="bachelorContainer"><!-- todo ! -->
|
||||
<div class="card mb-3 bg-light">
|
||||
<div class="card-body p-2">
|
||||
<p>
|
||||
<strong>Omvandling från poäng till betyg för ett kandidatarbete görs enligt följande schema: (varför svenska här?)</strong>
|
||||
</p>
|
||||
|
||||
<p>[A] 31-29, at least 1 point on components U1-U12 and Ö1-Ö4, Ö6?</p>
|
||||
|
||||
<p>[B] 28-26, at least 1 point on components U1-U12 and Ö1-Ö3, Ö6?</p>
|
||||
|
||||
<p>[C] 25-22, at least 1 point on components U1-U12 and Ö1-Ö3, Ö6?</p>
|
||||
|
||||
<p>[D] 21-19, at least 1 point on components U1-U12 and Ö1-Ö3, Ö6?</p>
|
||||
|
||||
<p>[E] 18-16, at least 1 point on components U1-U12 and Ö1-Ö3, Ö6?</p>
|
||||
|
||||
<p>[Fx] ???at least 1 point on 8 of the components U1-U12 and at least 2 points altogether on components
|
||||
Ö1-Ö3???
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div wicket:id="master15Container"><!-- todo ! -->
|
||||
<div class="card mb-3 bg-light">
|
||||
<div class="card-body p-2">
|
||||
<p>
|
||||
<strong>Conversion from points to grades is done according to the following schema:</strong>
|
||||
</p>
|
||||
|
||||
<p>[A] 33-31, at least 1 point on components U1-U7, U10-U13 and Ö1-Ö4, Ö6, and at least 2 points on U8-U9?</p>
|
||||
|
||||
<p>[B] 30-28, at least 1 point on components U1-U7, U10-U13 and Ö1-Ö3, Ö6, and at least 2 points on U8-U9?</p>
|
||||
|
||||
<p>[C] 27-24, at least 1 point on components U1-U7, U10-U13 and Ö1-Ö3, Ö6, and at least 2 points on U8-U9?</p>
|
||||
|
||||
<p>[D] 23-21, at least 1 point on components U1-U7, U10-U13 and Ö1-Ö3, Ö6, and at least 2 points on U8-U9?</p>
|
||||
|
||||
<p>[E] 20-19, at least 1 point on components U1-U7, U10-U13 and Ö1-Ö3, Ö6, and at least 2 points on U8-U9?</p>
|
||||
|
||||
<p>[Fx] ???at least 1 point on 10 of the components U1-U13 and at least 2 points altogether on components Ö1-Ö3???</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div wicket:id="master30Container"><!-- todo ! -->
|
||||
<div class="card mb-3 bg-light">
|
||||
<div class="card-body p-2">
|
||||
<p>
|
||||
<strong>Conversion from points to grades is done according to the following schema:</strong>
|
||||
</p>
|
||||
|
||||
<p>[A] 37-35, at least 1 point on components U1-U4, U10-U12, Ö1-Ö4, Ö6, and at least 2 points on U5-U9, U13?</p>
|
||||
|
||||
<p>[B] 34-32, at least 1 point on components U1-U4, U10-U12, Ö1-Ö3, Ö6, and at least 2 points on U5-U9, U13?</p>
|
||||
|
||||
<p>[C] 31-28, at least 1 point on components U1-U4, U10-U12, Ö1-Ö3, Ö6, and at least 2 points on U5-U9, U13?</p>
|
||||
|
||||
<p>[D] 27-25, at least 1 point on components U1-U4, U10-U12, Ö1-Ö3, Ö6, and at least 2 points on U5-U9, U13?</p>
|
||||
|
||||
<p>[E] 25-23, at least 1 point on components U1-U4, U10-U12, Ö1-Ö3, Ö6, and at least 2 points on U5-U9, U13?</p>
|
||||
|
||||
<p>[Fx] ???at least 1 point on 12 of the components U1-U13 and at least 2 points altogether on components Ö1-Ö3???</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</wicket:container>
|
||||
|
||||
<wicket:container wicket:id="between2017_202410">
|
||||
<div wicket:id="bachelorContainer">
|
||||
<div class="card mb-3 bg-light">
|
||||
<div class="card-body p-2">
|
||||
|
@ -6,12 +6,32 @@ import org.apache.wicket.model.IModel;
|
||||
import se.su.dsv.scipro.project.Project;
|
||||
import se.su.dsv.scipro.system.DegreeType;
|
||||
|
||||
import java.time.LocalDate;
|
||||
|
||||
public class TemplatePanel extends Panel {
|
||||
|
||||
public static final String BACHELOR_CONTAINER = "bachelorContainer";
|
||||
public static final String MASTER_15_CONTAINER = "master15Container";
|
||||
public static final String MASTER_30_CONTAINER = "master30Container";
|
||||
|
||||
private enum GradingCategory {
|
||||
UP_TO_2016,
|
||||
BETWEEN_2017_202410,
|
||||
FROM_202411;
|
||||
|
||||
public static GradingCategory fromProjectStartDate(LocalDate projectStartDate) {
|
||||
int year = projectStartDate.getYear();
|
||||
int month = projectStartDate.getMonthValue();
|
||||
|
||||
if (year < 2017) {
|
||||
return UP_TO_2016;
|
||||
} else {
|
||||
return (year <= 2024 && month < 11) ? BETWEEN_2017_202410 : FROM_202411;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public TemplatePanel(String id, final IModel<Project> projectIModel) {
|
||||
super(id, projectIModel);
|
||||
final DegreeType degreeType = projectIModel.getObject().getProjectType().getDegreeType();
|
||||
@ -20,20 +40,34 @@ public class TemplatePanel extends Panel {
|
||||
@Override
|
||||
protected void onConfigure() {
|
||||
super.onConfigure();
|
||||
setVisibilityAllowed(getYear(projectIModel.getObject()) < 2017);
|
||||
setVisibilityAllowed(GradingCategory.fromProjectStartDate(projectIModel.getObject().getStartDate())
|
||||
== GradingCategory.UP_TO_2016);
|
||||
}
|
||||
};
|
||||
addTemplates(degreeType, upto16);
|
||||
add(upto16);
|
||||
final WebMarkupContainer from2017 = new WebMarkupContainer("from2017") {
|
||||
|
||||
final WebMarkupContainer between2017_202410 = new WebMarkupContainer("between2017_202410") {
|
||||
@Override
|
||||
protected void onConfigure() {
|
||||
super.onConfigure();
|
||||
setVisibilityAllowed(getYear(projectIModel.getObject()) >= 2017);
|
||||
setVisibilityAllowed(GradingCategory.fromProjectStartDate(projectIModel.getObject().getStartDate())
|
||||
== GradingCategory.BETWEEN_2017_202410);
|
||||
}
|
||||
};
|
||||
addTemplates(degreeType, from2017);
|
||||
add(from2017);
|
||||
addTemplates(degreeType, between2017_202410);
|
||||
add(between2017_202410);
|
||||
|
||||
final WebMarkupContainer from202411 = new WebMarkupContainer("from202411") {
|
||||
@Override
|
||||
protected void onConfigure() {
|
||||
super.onConfigure();
|
||||
setVisibilityAllowed(GradingCategory.fromProjectStartDate(projectIModel.getObject().getStartDate())
|
||||
== GradingCategory.FROM_202411);
|
||||
}
|
||||
};
|
||||
addTemplates(degreeType, from202411);
|
||||
add(from202411);
|
||||
}
|
||||
|
||||
private void addTemplates(final DegreeType degreeType, final WebMarkupContainer container) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user