Class InputEditActionServiceImpl
java.lang.Object
ch.tocco.nice2.optional.qualification.impl.action.InputEditActionServiceImpl
- All Implemented Interfaces:
InputEditActionService
-
Nested Class Summary
Nested classes/interfaces inherited from interface ch.tocco.nice2.optional.qualification.impl.action.InputEditActionService
InputEditActionService.ChoiceRatingValue, InputEditActionService.ExamEditorFormData, InputEditActionService.FinishedResponse, InputEditActionService.FormInfo, InputEditActionService.MasterData, InputEditActionService.ServerFeedback -
Constructor Summary
ConstructorsConstructorDescriptionInputEditActionServiceImpl(EntityExplorerActionSelectionService entityExplorerActionSelectionService, QualificationService qualificationService, Context context, DefaultDisplayService defaultDisplayService, PersistPermissionService permissionService, SecurityManager securityManager, BusinessUnitManager businessUnitManager, org.slf4j.Logger log, L10N l10N, EvaluationTaskProvider taskProvider, CommandExecutor executor, QueryBuilderFactory queryBuilderFactory, QualificationBeanFactory qualificationBeanFactory, InputEditValidationService inputEditValidationService, ExamService examService) -
Method Summary
Modifier and TypeMethodDescription@Nullable Stringchecks if a selection can be used together to input data, things compared are number of ratings active exams input nodesfinishInput(EntityExplorerActionSelection selectedInput) getActiveExams(EntityExplorerActionSelection selection) getExams(EntityExplorerActionSelection selection) Returns allExams related to the selectedInputeven if they are defined as inactive by theirExam.FIELD_NRexceeding theInput'snumRatingsvalue.getExamsWithLimit(EntityExplorerActionSelection selection, int limit) Returns allExams related to the selectedInputnot exceeding the given limit, even if they are defined as inactive by theirExam.FIELD_NRexceeding theInput'snumRatingsvalue.getFormInfo(EntityExplorerActionSelection selection) getInputData(EntityExplorerActionSelection inputSelection) getLocalizedFormInfo(EntityExplorerActionSelection selectedInput, Locale locale) getLocalizedInputData(Entity inputEntity, Locale locale) getMasterData(EntityExplorerActionSelection selection) getStatistics(EntityExplorerActionSelection selection) booleanisEvaluationAllowed(EntityExplorerActionSelection selection) checks if any evaluation going upwards has been published.voidtriggerEvaluation(EntityExplorerActionSelection selection) start the evaluation of an evaluation entity by runningEvaluationTaskon itvoidupdateExams(EntityExplorerActionSelection selection, AbstractInputType.ExamRecord[] examRecords) writeInboundRecord(EntityExplorerActionSelection selection, AbstractInputType.InboundInputDataRecord inboundInputDataRecord) writeInboundRecord(EntityExplorerActionSelection selection, AbstractInputType.InboundRatingRecord inboundRatingRecord)
-
Constructor Details
-
InputEditActionServiceImpl
public InputEditActionServiceImpl(EntityExplorerActionSelectionService entityExplorerActionSelectionService, QualificationService qualificationService, Context context, DefaultDisplayService defaultDisplayService, PersistPermissionService permissionService, SecurityManager securityManager, BusinessUnitManager businessUnitManager, org.slf4j.Logger log, L10N l10N, EvaluationTaskProvider taskProvider, CommandExecutor executor, QueryBuilderFactory queryBuilderFactory, QualificationBeanFactory qualificationBeanFactory, InputEditValidationService inputEditValidationService, ExamService examService)
-
-
Method Details
-
areInputsCompatibleForEdit
@Nullable public @Nullable String areInputsCompatibleForEdit(EntityExplorerActionSelection selection) Description copied from interface:InputEditActionServicechecks if a selection can be used together to input data, things compared are- number of ratings
- active exams
- input nodes
- Specified by:
areInputsCompatibleForEditin interfaceInputEditActionService- Parameters:
selection- the selection- Returns:
- String the validation message, or null if valid
-
getFormInfo
- Specified by:
getFormInfoin interfaceInputEditActionService
-
getLocalizedFormInfo
public InputEditActionService.FormInfo getLocalizedFormInfo(EntityExplorerActionSelection selectedInput, Locale locale) - Specified by:
getLocalizedFormInfoin interfaceInputEditActionService
-
getInputData
- Specified by:
getInputDatain interfaceInputEditActionService
-
getLocalizedInputData
- Specified by:
getLocalizedInputDatain interfaceInputEditActionService
-
writeInboundRecord
public InputEditActionService.ServerFeedback writeInboundRecord(EntityExplorerActionSelection selection, AbstractInputType.InboundInputDataRecord inboundInputDataRecord) - Specified by:
writeInboundRecordin interfaceInputEditActionService
-
writeInboundRecord
public InputEditActionService.ServerFeedback writeInboundRecord(EntityExplorerActionSelection selection, AbstractInputType.InboundRatingRecord inboundRatingRecord) - Specified by:
writeInboundRecordin interfaceInputEditActionService
-
getMasterData
- Specified by:
getMasterDatain interfaceInputEditActionService
-
getStatistics
- Specified by:
getStatisticsin interfaceInputEditActionService
-
getActiveExams
Description copied from interface:InputEditActionService- Specified by:
getActiveExamsin interfaceInputEditActionService- Parameters:
selection- the editedInput- Returns:
- a list of records containing the
Exam's information - See Also:
-
getExams
Description copied from interface:InputEditActionServiceReturns allExams related to the selectedInputeven if they are defined as inactive by theirExam.FIELD_NRexceeding theInput'snumRatingsvalue.- Specified by:
getExamsin interfaceInputEditActionService- Parameters:
selection- the selectedInput- Returns:
- a list of records containing the
Exam's information
-
getExamsWithLimit
public List<AbstractInputType.ExamRecord> getExamsWithLimit(EntityExplorerActionSelection selection, int limit) Description copied from interface:InputEditActionServiceReturns allExams related to the selectedInputnot exceeding the given limit, even if they are defined as inactive by theirExam.FIELD_NRexceeding theInput'snumRatingsvalue.- Specified by:
getExamsWithLimitin interfaceInputEditActionService- Parameters:
selection- the selectedInputlimit- the limit of exams to get for theInput- Returns:
- a list of records containing the
Exam's information - See Also:
-
updateExams
public void updateExams(EntityExplorerActionSelection selection, AbstractInputType.ExamRecord[] examRecords) Description copied from interface:InputEditActionService- Specified by:
updateExamsin interfaceInputEditActionService- Parameters:
selection- the editedInputexamRecords- the records holding theExam's information- See Also:
-
finishInput
public InputEditActionService.FinishedResponse finishInput(EntityExplorerActionSelection selectedInput) - Specified by:
finishInputin interfaceInputEditActionService
-
getExamsEditorFormData
public InputEditActionService.ExamEditorFormData getExamsEditorFormData(EntityExplorerActionSelection selection) - Specified by:
getExamsEditorFormDatain interfaceInputEditActionService
-
triggerEvaluation
Description copied from interface:InputEditActionServicestart the evaluation of an evaluation entity by runningEvaluationTaskon it- Specified by:
triggerEvaluationin interfaceInputEditActionService- Parameters:
selection- the selected entity
-
isEvaluationAllowed
Description copied from interface:InputEditActionServicechecks if any evaluation going upwards has been published. only published evaluations are allowed to be evaluated- Specified by:
isEvaluationAllowedin interfaceInputEditActionService- Parameters:
selection- the selected entity- Returns:
- true if the evaluation should be allowed, meaning the button will be shown, false otherwise
-