public void returnedContentTypeDialog(ReturnEvent event) { if (event.getReturnValue() == null) { return; } MultiMediaMaterialType materialType = (MultiMediaMaterialType) event.getReturnParameters().get(Constants.KEY_RETURN_FROM_DIALOG); multiMediaBean.getContentManagement().setMaterialType(materialType); }
public void returnedWorkGroupDialog(ReturnEvent event) { if (event.getReturnValue() == null) { return; } AbstractWorkGroup workGroup = (AbstractWorkGroup) event.getReturnParameters().get(Constants.KEY_RETURN_FROM_DIALOG); multiMediaBean.getContentManagement().setWorkGroup(workGroup); }
public void returnedDownloadAccessModuleDialog(ReturnEvent event) { if (event.getReturnValue() == null) { return; } AccessModule accessModule = (AccessModule) event.getReturnParameters().get(Constants.KEY_RETURN_FROM_DIALOG); multiMediaBean.getContentManagement().setDownLoadAccessModule(accessModule); }
public void uploadAndReturn(ReturnEvent event) { if (event.getReturnValue() == null) return; String imageType = (String) event.getReturnValue(); byte[] picture = (byte[]) event.getReturnParameters().get("picture"); if (picture != null) { this.realPerson.setImage(picture); this.imageSource = JsfUtils.getVirtualImageUrl(picture, "realPic" + (counter++)); } }
public void returned(ReturnEvent event) { // ReturnListener Method if (event.getReturnParameters() != null) { if (event.getReturnParameters().size() > 0) { AuthorityRowData authorityRowData = (AuthorityRowData) event.getReturnParameters().get(Constants.KEY_RETURN_FROM_DIALOG); multiMediaBean.setRelatedAuthority((AuthorityRecord) authorityRowData.getEntity()); // .getEntity()) // relatedAuthority = (AuthorityRecord) authorityRowData // .getEntity(); System.out.println(((AuthorityRecord) authorityRowData.getEntity()).getAuthority()); } } // initInputObjects(event); methodInvoker(_CONST_RETURNED_METHOD_NAME, event); JsfUtils.removeFromPageFlow(_CONST_FILTER_KEY); }
public void returnFromSelectLibrary(ReturnEvent event) { JsfUtils.removeFromPageFlow(MEMBER_PROFILE_TYPE); AbstractWorkGroup selectedUnitLib = (AbstractWorkGroup) event.getReturnParameters().get(UserManagementConstants.SELECTED_UNIT_LIB_OBJECT_NAME); if (selectedUnitLib == null) return; this.selectedUnitOrLib = selectedUnitLib; }
public void returnFromDeleteDialog(ReturnEvent event) { Integer deleteConfirm = (Integer) event.getReturnValue(); if (deleteConfirm != null && deleteConfirm == 0) { if (JsfUtils.resolveVariable("row") != null) { UserFavoriteSubjectRowData rowData = (UserFavoriteSubjectRowData) JsfUtils.resolveVariable("row"); UserFavoriteSubject selectedSubject = (UserFavoriteSubject) rowData.getEntity(); NliSdiServiceProxy.getInstance().removeUserFavoriteSubject(selectedSubject); subjectModel.refresh(); } } }
public void returnFromDeleteNewItemDialog(ReturnEvent event) { Integer deleteConfirm = (Integer) event.getReturnValue(); if (deleteConfirm != null && deleteConfirm == 0) { NewsWebUtil.getInstance() .deleteDigitalFromNewItems( (BibliographicRecord) NliUnimarcStorageServiceProxy.getInstance() .findById( BibliographicRecord.class, (Long) JsfUtils.getFromPageFlow(Constants.RECORD_ID)), (VirtualContentManagement) contentManagementRowData.getEntity()); } }
public void returnDeleteHighVersionDialogValue(ReturnEvent event) { Integer deleteConfirm = (Integer) event.getReturnValue(); if (deleteConfirm == 0) { try { addMultiMediaBean.setLargeThumbFileName(""); multiMedia.setLargeThumbnail(null); multiMedia.setLargeThumbSystemic(true); } catch (Exception e) { e.printStackTrace(); ErrorReportingUtils.getInstance().reportError(e); } } }
public void returnDeleteFulltextArchiveDialogValue(ReturnEvent event) { Integer deleteConfirm = (Integer) event.getReturnValue(); if (deleteConfirm == 0) { try { addMultiMediaBean.setFulltextFileName(""); multiMedia.setFulltextFile(null); multiMedia.setFulltextFileSystemic(true); } catch (Exception e) { e.printStackTrace(); ErrorReportingUtils.getInstance().reportError(e); } } }
public void returnFullTextDialogValue(ReturnEvent event) { Integer confirm = (Integer) event.getReturnValue(); if (confirm == 0) { try { multiMediaBean.getContentManagement().setFullText(true); NliMultiMediaServiceProxy.getInstance() .updateVirtualContentManagement(multiMediaBean.getContentManagement(), null, false); contentManagementRowData.setFullText(true); } catch (Exception e) { e.printStackTrace(); ErrorReportingUtils.getInstance().reportError(e); } } }
@SuppressWarnings("unchecked") public void returnOptions(ReturnEvent event) { Object value = event.getReturnValue(); StringBuffer buffer = new StringBuffer(); int addedPrice = 0; if (value instanceof List) { for (CarOption option : (List<CarOption>) value) { addedPrice = addedPrice + option.getPrice(); if (buffer.length() != 0) buffer.append(", "); buffer.append(option.getName()); } } _options.setValue(buffer.toString()); Integer price = (Integer) _price.getValue(); _price.setValue(new Integer(price.intValue() + addedPrice)); }
public void returnDeleteDialogValue(ReturnEvent event) { Integer deleteConfirm = (Integer) event.getReturnValue(); if (deleteConfirm == 0) { try { MultiMedia multiMedia = CMSUtil.getMultiMedia(multiMediaBean.getContentManagement(), false, false, false); NliMultiMediaServiceProxy.getInstance() .removeContent( multiMediaBean.getContentManagement().getArchiveId(), multiMediaBean.getContentManagement().getId(), multiMedia.getId(), 1, multiMedia.getFileContent().getFileFormate()); } catch (Exception e) { e.printStackTrace(); ErrorReportingUtils.getInstance().reportError(e); } } }
/** Give subclasses a chance to override the ReturnEvent. */ protected void queueReturnEvent(FacesContext context, UIComponent component, ReturnEvent event) { event.queue(); }
public void returnFromLocation(ReturnEvent event) { Location location = (Location) event.getReturnParameters().get("location"); // this.address.setLocation(location); JsfUtils.storeOnPageFlow("selectedLocation", location); }