}
// check if there exists a scheduled employee that has not a task with a sale activity code linked...
DetailCallOutRequestVO vo = (DetailCallOutRequestVO)frame.getCalloutPanel().getVOModel().getValueObject();
VOListTableModel model = frame.getResourcesPanel().getTasksGrid().getVOListTableModel();
ScheduledEmployeeVO empVO = null;
ArrayList tasks = null;
TaskVO taskVO = null;
Response res = null;
HashMap map = new HashMap();
map.put(ApplicationConsts.COMPANY_CODE_SYS01,vo.getCompanyCodeSys01SCH03());
for(int i=0;i<model.getRowCount();i++) {
empVO = (ScheduledEmployeeVO)model.getObjectForRow(i);
res = ClientUtils.getData("validateTaskCode",new LookupValidationParams(empVO.getTaskCodeREG07(),map));
if (res.isError()) {
JOptionPane.showMessageDialog(
ClientUtils.getParentFrame(frame),
ClientSettings.getInstance().getResources().getResource(res.getErrorMessage()),
ClientSettings.getInstance().getResources().getResource("Error"),
JOptionPane.ERROR_MESSAGE
);
return;
}
tasks = new ArrayList(((VOListResponse)res).getRows());
if (tasks.size()!=1) {
JOptionPane.showMessageDialog(
ClientUtils.getParentFrame(frame),
ClientSettings.getInstance().getResources().getResource("no task defined for the scheduled employee")+" "+empVO.getEmployeeCodeSCH01(),
ClientSettings.getInstance().getResources().getResource("Error"),
JOptionPane.ERROR_MESSAGE
);
return;
}