Fix compilation problem
This commit is contained in:
parent
db38a70675
commit
54e6e5d787
view/src/main/java/se/su/dsv/scipro/finalseminar
@ -228,7 +228,7 @@ public class SeminarOppositionPanel extends Panel {
|
|||||||
|
|
||||||
private class FinalSeminarOppositionForm extends Form<FinalSeminarOpposition> {
|
private class FinalSeminarOppositionForm extends Form<FinalSeminarOpposition> {
|
||||||
|
|
||||||
private IModel<OppositionCriteria> pointsModel = new StatelessModel<>();
|
private IModel<OppositionCriteria.Point> pointsModel = new StatelessModel<>();
|
||||||
private IModel<String> feedbackModel = new Model<>();
|
private IModel<String> feedbackModel = new Model<>();
|
||||||
|
|
||||||
public FinalSeminarOppositionForm(String id, final IModel<FinalSeminarOpposition> finalSeminarOpposition) {
|
public FinalSeminarOppositionForm(String id, final IModel<FinalSeminarOpposition> finalSeminarOpposition) {
|
||||||
@ -237,7 +237,7 @@ public class SeminarOppositionPanel extends Panel {
|
|||||||
finalSeminarOppositionService.getCriteriaForOpposition(finalSeminarOpposition.getObject())
|
finalSeminarOppositionService.getCriteriaForOpposition(finalSeminarOpposition.getObject())
|
||||||
);
|
);
|
||||||
|
|
||||||
FormComponent<OppositionCriteria> pointsField = new DropDownChoice<>(
|
FormComponent<OppositionCriteria.Point> pointsField = new DropDownChoice<>(
|
||||||
POINTS,
|
POINTS,
|
||||||
pointsModel,
|
pointsModel,
|
||||||
criteriaModel.map(OppositionCriteria::pointsAvailable),
|
criteriaModel.map(OppositionCriteria::pointsAvailable),
|
||||||
@ -255,14 +255,19 @@ public class SeminarOppositionPanel extends Panel {
|
|||||||
new AjaxSubmitLink(SUBMIT) {
|
new AjaxSubmitLink(SUBMIT) {
|
||||||
@Override
|
@Override
|
||||||
protected void onSubmit(AjaxRequestTarget target) {
|
protected void onSubmit(AjaxRequestTarget target) {
|
||||||
finalSeminarOppositionService.gradeOpponent(
|
try {
|
||||||
finalSeminarOpposition.getObject(),
|
finalSeminarOppositionService.gradeOpponent(
|
||||||
pointsModel.getObject().points(),
|
finalSeminarOpposition.getObject(),
|
||||||
feedbackModel.getObject()
|
pointsModel.getObject().value(),
|
||||||
);
|
feedbackModel.getObject()
|
||||||
success(getString("feedback.opponent.updated", finalSeminarOpposition));
|
);
|
||||||
target.add(feedbackPanel);
|
success(getString("feedback.opponent.updated", finalSeminarOpposition));
|
||||||
target.add(oppositionContainer);
|
target.add(feedbackPanel);
|
||||||
|
target.add(oppositionContainer);
|
||||||
|
} catch (PointNotValidException e) {
|
||||||
|
error(getString("point.not.valid"));
|
||||||
|
target.add(feedbackPanel);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -8,6 +8,7 @@ gradingFeedback.Required = You need to write a motivation
|
|||||||
points.Required = Points are required
|
points.Required = Points are required
|
||||||
opponents.form.points.RangeValidator.range= Points assigned must be between ${minimum} and ${maximum}
|
opponents.form.points.RangeValidator.range= Points assigned must be between ${minimum} and ${maximum}
|
||||||
feedback.opponent.updated= Opponent ${user.fullName} feedback updated.
|
feedback.opponent.updated= Opponent ${user.fullName} feedback updated.
|
||||||
|
point.not.valid=You need to assign points from the available selection.
|
||||||
feedback.opponent.not.updated= Opponent ${user.fullName} feedback updated. Point and motivation could not be transferred to the students final grading report since the opponents supervisor already filled it in.
|
feedback.opponent.not.updated= Opponent ${user.fullName} feedback updated. Point and motivation could not be transferred to the students final grading report since the opponents supervisor already filled it in.
|
||||||
criteria= As the supervisor on this final seminar you are also required to grade the opponents opposition report.\
|
criteria= As the supervisor on this final seminar you are also required to grade the opponents opposition report.\
|
||||||
<\br><\br>Requirement for 1 point: <\br>That the opposition report provides a short summary of the evaluated thesis, that it deliberates about the scientific basis, originality, \
|
<\br><\br>Requirement for 1 point: <\br>That the opposition report provides a short summary of the evaluated thesis, that it deliberates about the scientific basis, originality, \
|
||||||
|
Loading…
x
Reference in New Issue
Block a user