@SuppressWarnings({"rawtypes", "unchecked"})
 @Override
 protected void setProtocolExemptStudiesCheckListItemHook(
     ProtocolBase protocol, SpecialReview specialReview) {
   List<String> exemptionTypeCodes = new ArrayList<String>();
   for (ProtocolExemptStudiesCheckListItem checkListItem :
       ((Protocol) protocol).getProtocolSubmission().getExemptStudiesCheckList()) {
     exemptionTypeCodes.add(checkListItem.getExemptStudiesCheckListCode());
   }
   specialReview.setExemptionTypeCodes(exemptionTypeCodes);
 }
Exemplo n.º 2
0
  private void setSubmissionCheckListinfo(
      org.kuali.kra.irb.actions.submit.ProtocolSubmissionLite protocolSubmission,
      SubmissionDetails protocolSubmissionDetail) {
    SubmissionChecklistInfo submissionChecklistInfo =
        protocolSubmissionDetail.addNewSubmissionChecklistInfo();
    String formattedCode = new String();
    Collection<ProtocolExemptStudiesCheckListItem> protocolExemptCheckList =
        getBusinessObjectService()
            .findMatching(
                ProtocolExemptStudiesCheckListItem.class,
                Collections.singletonMap("submissionIdFk", protocolSubmission.getSubmissionId()));
    for (ProtocolExemptStudiesCheckListItem protocolExemptStudiesCheckListBean :
        protocolExemptCheckList) {
      Checklists checkListItem = submissionChecklistInfo.addNewChecklists();
      checkListItem.setChecklistCode(
          protocolExemptStudiesCheckListBean.getExemptStudiesCheckListCode());
      checkListItem.setChecklistDescription(
          protocolExemptStudiesCheckListBean.getExemptStudiesCheckListItem().getDescription());
      formattedCode =
          formattedCode
              + "("
              + protocolExemptStudiesCheckListBean.getExemptStudiesCheckListCode()
              + ") ";
    }
    if (formattedCode.length() > 0) {
      submissionChecklistInfo.setChecklistCodesFormatted(
          formattedCode); // this will have format (3) (7) like that...
    }
    Collection<ProtocolExpeditedReviewCheckListItem> vecExpeditedCheckList =
        getBusinessObjectService()
            .findMatching(
                ProtocolExpeditedReviewCheckListItem.class,
                Collections.singletonMap("submissionIdFk", protocolSubmission.getSubmissionId()));
    for (ProtocolExpeditedReviewCheckListItem protocolReviewTypeCheckListBean :
        vecExpeditedCheckList) {
      Checklists checkListItem = submissionChecklistInfo.addNewChecklists();
      checkListItem.setChecklistCode(
          protocolReviewTypeCheckListBean.getExpeditedReviewCheckListCode());
      checkListItem.setChecklistDescription(
          protocolReviewTypeCheckListBean.getExpeditedReviewCheckListItem().getDescription());
      formattedCode =
          formattedCode
              + "("
              + protocolReviewTypeCheckListBean.getExpeditedReviewCheckListCode()
              + ") ";
    }

    if (formattedCode.length() > 0) {
      submissionChecklistInfo.setChecklistCodesFormatted(
          formattedCode); // this will have format (3) (7) like that...
    }
  }