IDEMPIERE-1110 NPE on Setup Wizard
This commit is contained in:
parent
69de4d3d87
commit
f36853a3d7
|
@ -85,6 +85,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
|
|||
//
|
||||
private Tree wfnodeTree;
|
||||
private Treeitem prevti = null;
|
||||
private Treeitem firstti = null;
|
||||
|
||||
private Label pretitleLabel = new Label(Msg.getMsg(Env.getCtx(), "SetupTask"));
|
||||
private Label titleLabel = new Label();
|
||||
|
@ -150,6 +151,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
|
|||
if (event.getName().equals(WindowContainer.ON_WINDOW_CONTAINER_SELECTION_CHANGED_EVENT))
|
||||
{
|
||||
Treeitem ti = wfnodeTree.getSelectedItem();
|
||||
if (ti != null) {
|
||||
if (ti.getAttribute("AD_Workflow_ID") != null) {
|
||||
// MWorkflow
|
||||
int wfid = (Integer) ti.getAttribute("AD_Workflow_ID");
|
||||
|
@ -160,6 +162,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
|
|||
SessionManager.getAppDesktop().updateHelpContext(X_AD_CtxHelp.CTXTYPE_Node, nodeid);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
super.onEvent(event);
|
||||
}
|
||||
|
@ -192,11 +195,12 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
|
|||
}
|
||||
|
||||
protected void addWfEntry(MWorkflow wfwizard) {
|
||||
/* TODO: Color of workflow according to wizard status */
|
||||
allFinished = true;
|
||||
Treechildren treeChildren = wfnodeTree.getTreechildren();
|
||||
Treeitem treeitemwf = new Treeitem();
|
||||
treeChildren.appendChild(treeitemwf);
|
||||
if (firstti == null)
|
||||
firstti = treeitemwf;
|
||||
|
||||
Label wizardLabel = new Label(wfwizard.getName(true));
|
||||
wizardLabel.setStyle(WIZARD_LABEL_STYLE);
|
||||
|
@ -432,10 +436,8 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
|
|||
|
||||
setNotesPanelVisible(false);
|
||||
|
||||
MWorkflow wf = MWorkflow.get(Env.getCtx(), getWfWizards().get(0).get_ID());
|
||||
showInRightPanel(wf.getAD_Workflow_ID(), 0);
|
||||
|
||||
|
||||
wfnodeTree.setSelectedItem(firstti);
|
||||
showItem(firstti);
|
||||
} // jbInit
|
||||
|
||||
private void refreshProgress() {
|
||||
|
|
Loading…
Reference in New Issue