Beispiel #1
0
 /** {@inheritDoc} */
 public List<Type> createList() {
   StackFrame frame = FlowContextHolder.getContext().peek();
   Map<String, Object> params = new HashMap<String, Object>();
   params.put("dataElementCollection", frame.getAttribute("dataElementCollection"));
   return getMainService()
       .findByNamedQuery(
           "gov.nih.nci.calims2.domain.common.Type.findByDataElementCollection", params);
 }
Beispiel #2
0
 /**
  * Initialize the dataElementCollection attribute of the FlowCpntext based on the select box in
  * the manage page.
  *
  * @param dataElementCollection The value of the dataElementCollection parameter.
  */
 @InitBinder
 public void initFlowContext(
     @RequestParam(value = "dataElementCollection", required = false)
         String dataElementCollection) {
   if (dataElementCollection != null) {
     StackFrame frame = FlowContextHolder.getContext().peek();
     frame.addAttribute("dataElementCollection", dataElementCollection);
   }
 }
Beispiel #3
0
 /** {@inheritDoc} */
 public AccountNumber getSubmittedEntity() {
   AccountNumber accountNumber = getEntity();
   Long accountId = (Long) (FlowContextHolder.getContext().peek()).getAttribute("id");
   accountNumber.setAccount(EntityWithIdHelper.createEntity(Account.class, accountId));
   accountNumber.setNotesCollection(getNotesCollection());
   accountNumber.setType(EntityWithIdHelper.createEntity(Type.class, typeId));
   accountNumber.setStatus(I18nEnumerationHelper.getByName(AccountNumberStatus.class, status));
   return accountNumber;
 }
Beispiel #4
0
 /**
  * Calls a direct method.
  *
  * @return The next view to go to. It is a forward to the entry action of the subflow.
  */
 @RequestMapping("/directCall.do")
 public ModelAndView directCall() {
   logMethod("doCall");
   ModelAndView model = new ModelAndView();
   Stack<StackFrame> context = FlowContextHolder.getContext();
   StackFrame frame = new BaseStackFrame();
   context.push(frame);
   model.setView(
       new InternalResourceView(
           "/common/type/create.do?dataElementCollection="
               + TypeEnumeration.CONTAINER
               + "&currentView=/common/type/manage.do"));
   return model;
 }