private void populateRecordBrwoser(SocialHistoryLiteVoCollection socialHistorycoll) { if(socialHistorycoll == null) return; form.recbrSocialHistory().clear(); for (int i = 0; i < socialHistorycoll.size(); i++) { SocialHistoryLiteVo vo = socialHistorycoll.get(i); form.recbrSocialHistory().newRow(socialHistorycoll.get(i), getAuthoring(vo)); } if (form.getLocalContext().getvoSocialHistoryIsNotNull()) form.recbrSocialHistory().setValue(form.getLocalContext().getvoSocialHistory()); else if(socialHistorycoll.size()>0) form.recbrSocialHistory().setValue(socialHistorycoll.get(0)); }
private String getAuthoring(SocialHistoryLiteVo vo) { StringBuffer sb = new StringBuffer(); if(vo != null) { if(vo.getAuthoringInformationIsNotNull()) { if (vo.getAuthoringInformation().getAuthoringHcpIsNotNull()) { sb.append(vo.getAuthoringInformation().getAuthoringHcp().toString()); } if (vo.getAuthoringInformation().getAuthoringDateTimeIsNotNull()) { sb.append(" " + vo.getAuthoringInformation().getAuthoringDateTime().toString()); } } } return sb.toString(); }