Class InterventionOutcome
java.lang.Object
overit.geocall.platform.ui.UINode
overit.geocall.ui.Component
overit.geocall.ui.Control
overit.geocall.basic.ui.Container
overit.geocallapp.wfm.schedulazione.consuntivazione.activity.CActivityOutcome
overit.geocallapp.wfm.core.ux.schedule.intervention.outcome.InterventionOutcome
- All Implemented Interfaces:
Serializable,overit.geocall.marks.MethodExposer,overit.geocall.marks.NameExposer,Badgeable,Identified,Tool,overit.geocall.ux.configurability.UIConfigurable,overit.geocall.ux.edm.ModelConfigurable
public class InterventionOutcome
extends overit.geocallapp.wfm.schedulazione.consuntivazione.activity.CActivityOutcome
Main container for
Intervention outcome editing- Since:
- 9.2
- See Also:
- GCApi:
- controller
-
Nested Class Summary
Nested classes/interfaces inherited from class overit.geocall.ui.Component
Component.Configurable, Component.ConfigurableAttribute, Component.ConfigurableAttributes, Component.FilterCriteria, Component.Registry -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringprotected static final StringField in the interventions table that store the editing status for the related interventionprotected static final StringFiled of the interventions table to store the problems collected during the intervention editingprotected booleansay if the user have already saved the edited dataprotected TableViewtable view with the optional interventions data.protected static final Stringprotected booleanprotected static final LongValue for theINTERVENTION_STATUS_ICON_FIELDfield in the interventions table that say that something went wrong during the intervention editingprotected static final LongValue for theINTERVENTION_STATUS_ICON_FIELDfield in the interventions table that say that editing is OKFields inherited from class overit.geocallapp.wfm.schedulazione.consuntivazione.activity.CActivityOutcome
ATTACHMENTS_FLAG_FIELD, currentIntervention, currentOperation, END_OUTCOME_FIELD, INPUT_FIELD_MASTER_AGENDA, INPUT_FIELD_MASTER_SCHEDULING, INPUT_FIELD_READONLY, inputAgenda, inputScheduling, INTERVENTION_FIELD, INTERVENTION_KEY_FIELD, INTERVENTION_WORKED_TIME_FIELD, interventionGroup, interventions, interventionsTableView, isReadOnly, mainForm, mainOperationIntervention, MATERIALS_FLAG_FIELD, newInterventionGroup, OPERATION_FIELD, OPERATION_KEY_FIELD, OPERATION_WORKED_TIME_FIELD, optionalOperationTechnicalObject, outcomeComponents, outcomeSections, ssh, STORABLE_DATA_FIELD, WORK_ORDER_KEY_FIELD, workOrderFields inherited from class overit.geocall.basic.ui.Container
_rofields, _rules, DALINK_NO, DALINK_YES, DATE_MAX, DATE_MIN, TIME_MAX, TIME_MIN, TYPE_ACTION, TYPE_BOOLEAN, TYPE_DATE, TYPE_DOUBLE, TYPE_DTZ, TYPE_EURO, TYPE_FILE, TYPE_FILES, TYPE_INTEGER, TYPE_LONG, TYPE_LONGARRAY, TYPE_MAP, TYPE_MAXDATE, TYPE_MAXTIME, TYPE_MEASURE, TYPE_MINDATE, TYPE_MINTIME, TYPE_NEWACTION, TYPE_STRING, TYPE_STRINGARRAY, TYPE_SUBSET, TYPE_SUBSETRANGE, TYPE_SUPPORT, TYPE_TIMERANGEFields inherited from class overit.geocall.ui.Control
_blank, _cleaner, _dblink, _enabled, _ro, _title, altEventIconsList, altIcon, ariaDescription, ariaLabel, badge, badgeformat, FILTER_PREFIXES, LABEL_ATTRIBUTE, LABEL_IN_LINE_ATTRIBUTE, STATE_BLANK, STATE_NORMAL, STATE_RO, STATE_ROBLANKFields inherited from class overit.geocall.ui.Component
_basic, _childrenContainers, _currentId, _gridalign, _gridcols, _gridrows, _gridvalign, _iconElement, _id, _keylabel, _label, _layoutName, _name, _parentContainer, _registryName, _shortcut, _tabindex, _transformations, _valuesContainer, aliasField, BR, configHidden, configuredLabel, configuredLabelInLine, defaultHidden, ELEMENT_BR, ELEMENT_NULL, entityContainer, entityName, extendedField, fullHeight, important, labelInLine, layoutLabel, PIXEL_IMG, safeInlineService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidapplyInterventionChanges(Intervention intervention) Build theInterventionOutcomeSaveInputwith the current data inserted by the user for the activity outcome.protected voidBuild the Alert to ask to the user if he want really generate the selected optional operationprotected voidbuildPageXml(HashGetter openParams) protected voidExecute the some global check, and delegate to eachInterventionOutcomeSectionthe specific checks if needed.protected voidDo the new outcome selection assuming that the user have confirmed itprotected voidinit()protected voidinitForIntervention(Intervention intervention, InterventionOutcomeSaveInput storableData) Prepare the container for the given intervention.protected voidinitForWorkOrder(WorkOrder workOrder) Prepare the container for the given work order.protected booleanisConclusiveOutcomeReason(Intervention intervention, InterventionOutcomeSaveInput storableData) Define if the given intervention has a conclusive outcome.protected voidLoad the list of Intervention to editprotected WorkOrderLoad the work order related to the interventions to edit.protected voidEnable or disable the container's controls in order to allow or deny the intervention editing according to the target intervention stateprotected booleanmanageTechnicalObjectForOptionalOperation(HashGetter optionalOperation) Evaluate if the user must select a technical object for the requested optional operation If the sub technical object is required, the user will be automatically forwarder to the technical object selection page.booleanbooleanUI event handler to manage the new optional operation abort.booleanUI event handler to manage the page closingbooleanUI event handler to confirm the interventions bulk update.booleanUI event handler to manage the new optional operation confirm.booleanUI event handler to intercept the outcome reason selection confirmation.booleanUI event handler to reset all the user changesbooleanUI event handler for the intervention selection Apply the user changes to the current intervention before to select the new onevoidPrepares the container loading the required intervention with the interventions linked to it.booleanUI event handler to start the optional operation insert processbooleanUI event handler to intercept the outcome reason selection.voidMethod called when is executed theWindowManager.pop(java.lang.Object)of the aboveWindow.voidRestore handler from the Facility selection required to generate the selected optional operationbooleanUI event handler to start the outcome save processbooleanbooleanUI event handler to show a panel that allows the user to edit more than one intervention at a timebooleanUI event handler to show the intervention info panelbooleanUI event handler to start the outcome save processbooleanUI event handler to show the optional operations panel.booleanUI event handler to reset all the user changes to the intervention outcome Will show a confirmation panel before to do the operationprotected voidCalled when the outcome reason is changed.protected voidFill the interventions TableView starting from the loaded interventions.protected HashGetterprepareInterventionTableRow(Intervention intervention) Prepare a single row of the interventions table viewprotected voidreset()Clear the container to be ready to edit a new interventionprotected voidPrepare the intervention outcome data for theInterventionOutcomeSaveEventand launch it.protected voidselectIntervention(HashGetter interventionsTableRow) Do the actual intervention selection starting from the interventions table rowprotected voidTry to select the new outcome reason, but if the intervention group is changing, ask to the user if want really apply this change.protected voidupdateInterventionTable(boolean addOnlyNew) Synch the interventions table with the List of Interventions in memoryMethods inherited from class overit.geocallapp.wfm.schedulazione.consuntivazione.activity.CActivityOutcome
createOptionalOperation, getEndDate, getInterventionIds, getMainForm, getRowIntervention, getRowOperation, getRowStorableData, inferDatesFromLinkedAgenda, isTecnicalValidationDone, laodTotalOperationWorkedTime, loadDatiAggiuntivi, loadInterventionGroup, manageEWOBeCompilation, onCompileEWO, onExecutionPhasesMap, onGoToAgendaMessages, onGoToHistory, onPerformancesAccounting, onRestoreFromUserAccounting, onRetiredMaterialsAccounting, onSendInterventionsAccountingsToSap, onUploadFileMultimediale, onUsedMaterialsAccounting, onUserAccounting, onVehicleAccounting, sendInterventionsAccountingsToSap, showEwoAlert, updateDetailIcons, updateWorkedTimeSummaryMethods inherited from class overit.geocall.basic.ui.Container
alert, applyRule, getBASIC, getBLANK, getHtml, getRO, getROField, onClose, onOpenChildContainer, onRule, prepareName, rulesNewValues, setROField, setValues, setValuesMethods inherited from class overit.geocall.ui.Control
avoidNull, clean, getBadgeFormat, getBadgeValue, getCleaner, getConfigurableProperties, getDAValues, getDBLINK, getKEYLABEL, getLABEL, getState, getTITLE, getValues, getWM, isEnabled, isEnabledBasedOnFunction, isFunctionEnabled, isImportant, isRoBasedOnFunction, nameWithNoFilterPrefix, setALTEVENTICON, setALTICON, setARIADESCRIPTION, setARIALABEL, setBADGEFORMAT, setBADGEVALUE, setBLANK, setCLEANER, setConfiguredProperty, setDBLINK, setENABLED, setFUNCTION, setModelProperties, setRO, setTitle, setTITLEMethods inherited from class overit.geocall.ui.Component
adapt, ajaxQuery, appendAttribute, buildDisplayScript, buildSetupScript, calcKeyLabel, calcLabel, calcShortcut, canBeConfigured, changed, clearConfiguredProperties, componentIterator, componentSize, connect, containerIterator, createAjaxFrame, deprecate, fillSetupScript, generateFlexableFullHeightContainer, generateId, getBoolean, getBoolean, getChildrenComponents, getChildrenContainers, getDefaultLabel, getDefaultLayoutLabel, getEntityContainer, getEntityName, getFullHeight, getGridAlign, getGridCols, getGridRows, getGridVAlign, getHtmlLabel, getHtmlLabel, getIcon, getId, getIdentity, getint, getLayoutLabel, getLayoutName, getNAME, getParentComponent, getParentContainer, getPublishedChildrenList, getRegistryName, getSHORTCUT, getTabIndex, getTeacher, getValuesContainer, getWindow, initChilds, isActivable, isActive, isAliasField, isConfigHidden, isDefaultHidden, isExtendedField, isLabelInLine, onInit, setActivable, setActive, setAliasField, setBASIC, setConfigHidden, setDEFAULTHIDDEN, setEntityName, setExtendedField, setFULLHEIGHT, setGRIDALIGN, setGRIDCOLS, setGRIDROWS, setGRIDVALIGN, setICON, setIdentity, setIMPORTANT, setLabel, setLABEL, setLABELINLINE, setLAYOUTLABEL, setLAYOUTNAME, setNAME, setREGISTRYNAME, setTooltip, setup, setValuesContainer, stringForJs, tabIndexerMethods inherited from class overit.geocall.platform.ui.UINode
addChild, addChildText, getChildren, getNodeId, getParent, getRoot, getSchema, setNodeId, setParent, setSchemaMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface overit.geocall.ui.Badgeable
badgeFormat, makeBadgedIcon
-
Field Details
-
INPUT_FIELD_ONLY_CURRENT_INTERVENTION
- See Also:
-
INTERVENTION_STATUS_ICON_FIELD
Field in the interventions table that store the editing status for the related intervention- See Also:
-
STATUS_EDITING_OK
Value for theINTERVENTION_STATUS_ICON_FIELDfield in the interventions table that say that editing is OK -
STATUS_EDITING_KO
Value for theINTERVENTION_STATUS_ICON_FIELDfield in the interventions table that say that something went wrong during the intervention editing- See Also:
-
INTERVENTION_STATUS_PROBLEMS_FIELD
Filed of the interventions table to store the problems collected during the intervention editing- See Also:
-
RN_EDITING_PANEL
- See Also:
-
optionalInterventionsTableView
table view with the optional interventions data. Will be used to generate one of the optional interventions -
showOnlyCurrentIntervention
protected boolean showOnlyCurrentIntervention -
isAlreadySaved
protected boolean isAlreadySavedsay if the user have already saved the edited data
-
-
Constructor Details
-
InterventionOutcome
public InterventionOutcome()
-
-
Method Details
-
onOpen
Prepares the container loading the required intervention with the interventions linked to it. Then selects the input agenda's intervention.- Overrides:
onOpenin classoverit.geocallapp.wfm.schedulazione.consuntivazione.activity.CActivityOutcome- Parameters:
obj- Object received from the caller- Throws:
overit.geocall.asserts.AssertsException- if the input object is not anHashGetter, and if thatHashGetterdoesn't have at least one of these values-
CActivityOutcome.INPUT_FIELD_MASTER_AGENDA -
CActivityOutcome.INPUT_FIELD_MASTER_SCHEDULING
-
-
buildPageXml
-
onRestore
Description copied from class:ContainerMethod called when is executed theWindowManager.pop(java.lang.Object)of the aboveWindow. It calls the onRestore(o) method of all the Container's childrens -
initForIntervention
protected void initForIntervention(Intervention intervention, InterventionOutcomeSaveInput storableData) Prepare the container for the given intervention.- Parameters:
intervention- the intervention to editstorableData- the storable data eventually associated to the intervention
-
initForWorkOrder
Prepare the container for the given work order.- Parameters:
workOrder- the work order for which prepare the container
-
manageEditability
protected void manageEditability()Enable or disable the container's controls in order to allow or deny the intervention editing according to the target intervention state -
loadWorkOrder
Load the work order related to the interventions to edit.- Returns:
- the loaded work order
-
loadInterventions
protected void loadInterventions()Load the list of Intervention to edit -
updateInterventionTable
protected void updateInterventionTable(boolean addOnlyNew) Synch the interventions table with the List of Interventions in memory- Parameters:
addOnlyNew- if true the update is limited to the added operations, so the updated data to the already existing operations still remains
-
reset
protected void reset()Clear the container to be ready to edit a new intervention -
onSave
UI event handler to start the outcome save process- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain
- See Also:
-
saveOutcomes
protected void saveOutcomes()Prepare the intervention outcome data for theInterventionOutcomeSaveEventand launch it. Before, does a validation and abort the action if some check will not pass, showing an alert with informations about the problems.- See Also:
-
onUndoAllChanges
UI event handler to reset all the user changes to the intervention outcome Will show a confirmation panel before to do the operation- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain
-
onConfirmUndoAllChanges
UI event handler to reset all the user changes- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain
-
onOptionalOperationSelect
UI event handler to start the optional operation insert process- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain
-
manageTechnicalObjectForOptionalOperation
Evaluate if the user must select a technical object for the requested optional operation If the sub technical object is required, the user will be automatically forwarder to the technical object selection page.- Parameters:
optionalOperation- the raw data of the optional operation for which evaluate if a sub facility is required- Returns:
- true if the user must select a technical object for the requested optional operation, false otherwise.
- See Also:
-
onRestoreFromTechnicalObjectSelection
Restore handler from the Facility selection required to generate the selected optional operation- Parameters:
o- the restore input
-
askOptionalOperationConfirm
protected void askOptionalOperationConfirm()Build the Alert to ask to the user if he want really generate the selected optional operation- See Also:
-
onShowOperationsProbles
UI event handler to start the outcome save process- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onShowBulkUpdatePanel
UI event handler to show a panel that allows the user to edit more than one intervention at a time- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onConfirmBulkUpdate
UI event handler to confirm the interventions bulk update. So apply the edited data to the selected interventions- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
selectIntervention
Do the actual intervention selection starting from the interventions table row- Parameters:
interventionsTableRow- the HashGetter with the interventions table row in which find theInterventionto select
-
onInterventionSelection
UI event handler for the intervention selection Apply the user changes to the current intervention before to select the new one- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onShowOptionalOperations
UI event handler to show the optional operations panel. The user will select the operation to insert- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onConfirmNewOptionalOperations
UI event handler to manage the new optional operation confirm.- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onAbortNewOptionalOperations
UI event handler to manage the new optional operation abort.- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onShowInterventionInfo
UI event handler to show the intervention info panel- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
outcomeReasonChanged
protected void outcomeReasonChanged()Called when the outcome reason is changed. Evaluate if the new outcome is conclusive or not and notify the sections with this information- See Also:
-
isConclusiveOutcomeReason
protected boolean isConclusiveOutcomeReason(Intervention intervention, InterventionOutcomeSaveInput storableData) Define if the given intervention has a conclusive outcome.- Parameters:
intervention- the intervention for which look if exists a conclusive outcomestorableData- the user edited data of this intervention. Can be null if the user have not edited the intervention- Returns:
- true if the intervention has a conclusive outcome, false otherwise.
-
selectOutcomeReason
protected void selectOutcomeReason()Try to select the new outcome reason, but if the intervention group is changing, ask to the user if want really apply this change.- See Also:
-
confirmOutcomeReasonSelection
Do the new outcome selection assuming that the user have confirmed it- Throws:
DAValidateException- See Also:
-
onOutcomeReasonSelected
UI event handler to intercept the outcome reason selection. If the intervention group will change, the system will ask for confirmation before to actually do the change.- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
-
onConfirmOutcomeReasonSelection
UI event handler to intercept the outcome reason selection confirmation.- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise.
- See Also:
-
onClose
UI event handler to manage the page closing- Parameters:
uim- the UI event data such as the form content and control keys- Returns:
- true to break the responsibility chain, false otherwise. TODO after WOOperation replace FLAG_ROLOAD_ODL with a generic OUTCOME_SAVED for both scheduled and not interventions
-
applyInterventionChanges
Build theInterventionOutcomeSaveInputwith the current data inserted by the user for the activity outcome. Then do a first check to identify the errors, and update the main table view with the edited data e and the problem list- Parameters:
intervention- theInterventionfor which apply the current changes
-
prepareInterventionTable
Fill the interventions TableView starting from the loaded interventions.- Throws:
DAValidateException- if something went wrong
-
prepareInterventionTableRow
protected HashGetter prepareInterventionTableRow(Intervention intervention) throws DAValidateException Prepare a single row of the interventions table view- Parameters:
intervention- the interventions for which build the table view row- Returns:
- the intervention's data for the interventions table view
- Throws:
DAValidateException- if something went wrong
-
checkForSave
Execute the some global check, and delegate to eachInterventionOutcomeSectionthe specific checks if needed.- Throws:
DAValidateException- if at least one check is failed, to break the save action.- See Also:
-
init
protected void init() -
onSaveMeasureEdit
-
onAbortMeasureEdit
-