164. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 12/13/2018 10:35:24 AM Eastern Standard Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

164.1 Files compared

# Location File Last Modified
1 v12.5_iter_7_build 51.zip\TRM_Upgrade\src\main\java\gov\va\med\ccht\service\qir\impl QIRServiceImpl.java Fri Dec 7 17:36:42 2018 UTC
2 v12.5_iter_7_build 51.zip\TRM_Upgrade\src\main\java\gov\va\med\ccht\service\qir\impl QIRServiceImpl.java Wed Dec 12 22:33:39 2018 UTC

164.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 2 948
Changed 1 2
Inserted 0 0
Removed 0 0

164.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

164.4 Active regular expressions

No regular expressions were active.

164.5 Comparison detail

  1   /**
  2    * 
  3    */
  4   package go v.va.med.c cht.servic e.qir.impl ;
  5  
  6   import jav a.util.Arr ayList;
  7   import jav a.util.Cal endar;
  8   import jav a.util.Dat e;
  9   import jav a.util.Has hMap;
  10   import jav a.util.Lis t;
  11   import jav a.util.Map ;
  12  
  13   import org .springfra mework.bea ns.factory .annotatio n.Autowire d;
  14   import org .springfra mework.bea ns.factory .annotatio n.Qualifie r;
  15   import org .springfra mework.mai l.SimpleMa ilMessage;
  16   import org .springfra mework.ste reotype.Se rvice;
  17  
  18   import gov .va.med.cc ht.model.C CHTPermiss ions;
  19   import gov .va.med.cc ht.model.C CHTRoles;
  20   import gov .va.med.cc ht.model.U ser;
  21   import gov .va.med.cc ht.model.c ommon.Simp leFacility ;
  22   import gov .va.med.cc ht.model.c ommon.Simp leVisn;
  23   import gov .va.med.cc ht.model.c ommon.Vend or;
  24   import gov .va.med.cc ht.model.q ir.QIR;
  25   import gov .va.med.cc ht.model.q ir.QIRAtta chment;
  26   import gov .va.med.cc ht.model.q ir.QIRSear chParamete rs;
  27   import gov .va.med.cc ht.model.q ir.QIRSear chResult;
  28   import gov .va.med.cc ht.model.q ir.QIRStat usType;
  29   import gov .va.med.cc ht.model.q ir.QIRStat usTypeEnum ;
  30   import gov .va.med.cc ht.model.t erminology .FederalHo liday;
  31   import gov .va.med.cc ht.persist ent.QIRDAO ;
  32   import gov .va.med.cc ht.service .common.Me rgeService ;
  33   import gov .va.med.cc ht.service .common.Se curityServ ice;
  34   import gov .va.med.cc ht.service .common.im pl.Abstrac tBusinessS ervice;
  35   import gov .va.med.cc ht.service .qir.QIRSe rvice;
  36   import gov .va.med.fw .model.lda p.SearchCr iteria;
  37   import gov .va.med.fw .security. UserPrinci pal;
  38   import gov .va.med.fw .service.S erviceExce ption;
  39   import gov .va.med.fw .ui.model. TermType;
  40   import gov .va.med.fw .util.Date Utils;
  41   import gov .va.med.fw .util.Stri ngUtils;
  42  
  43   /**
  44    * @author   DNS
  45    *
  46    */
  47   @Service
  48   public cla ss QIRServ iceImpl ex tends Abst ractBusine ssService  implements  QIRServic e {
  49  
  50           pu blic final  int SATUR DAY = 7;
  51           pu blic final  int SUNDA Y = 1;
  52  
  53           pr ivate Stri ng qirNoti ficationJM SPayLoadNa me;
  54           
  55           @A utowired
  56           @Q ualifier(" qirNotific ationMailM essage")
  57           pr ivate Simp leMailMess age qirNot ificationM essage;
  58           @A utowired
  59           @Q ualifier(" qirVendorR esponseDue MailMessag e")
  60           pr ivate Simp leMailMess age qirVen dorRespons eDueMailMe ssage;
  61           @A utowired
  62           pr ivate Secu rityServic e security Service;
  63           @A utowired
  64           pr ivate Merg eService m ergeServic e;
  65           @A utowired
  66           pr ivate QIRD AO qirDAO;
  67           
  68           pu blic Strin g getQirNo tification JMSPayLoad Name() {
  69                    retu rn qirNoti ficationJM SPayLoadNa me;
  70           }
  71  
  72           pu blic void  setQirNoti ficationJM SPayLoadNa me(String  qirNotific ationJMSPa yLoadName)  {
  73                    this .qirNotifi cationJMSP ayLoadName  = qirNoti ficationJM SPayLoadNa me;
  74           }
  75  
  76           @O verride
  77           pu blic QIR g etQIR(fina l long id)  throws Se rviceExcep tion {
  78                    retu rn qirDAO. findById(i d);
  79           }
  80  
  81           pu blic Date  getDueDate FromHistor y(String q irId) thro ws Service Exception  {
  82                    Date  vendorRes ponseDueDa te = null;
  83  
  84                    if ( qirId != n ull) {
  85                             vendor ResponseDu eDate = qi rDAO.getVe ndorRespon seDueDate( Long.parse Long(qirId ));
  86                    }
  87                    retu rn vendorR esponseDue Date;
  88           }
  89  
  90           @O verride
  91           pu blic QIRAt tachment g etQIRAttac hment(fina l long att achmentId)  throws Se rviceExcep tion {
  92                    retu rn qirDAO. findAttach mentById(a ttachmentI d);
  93           }
  94  
  95           @O verride
  96           pu blic List< QIRSearchR esult> sea rchQIR(QIR SearchPara meters qir SearchPara meters) th rows Servi ceExceptio n {
  97                    User  user = ge tCurrentUs er();
  98                    if ( user.isPer missionGra nted(CCHTP ermissions .VENDOR))  {
  99                             Vendor  vendor =  user.getVe ndor();
  100                             if (ve ndor != nu ll) {
  101                                      qirSearc hParameter s.setVendo r(new Term Type(vendo r.getName( ), vendor. getCode()) );
  102                                      qirSearc hParameter s.setIsVen dor(true);
  103                             } else  {
  104                                      qirSearc hParameter s.setVendo r(new Term Type("_INV ALID_MISSI NG_VENDOR" , "-1"));
  105                             }
  106                    }
  107                    else
  108                    {
  109                             qirSea rchParamet ers.setIsV endor(fals e);
  110                    }
  111                    retu rn qirDAO. searchQIR( qirSearchP arameters) ;
  112           }
  113  
  114           pu blic void  updateQIR( QIR qir) t hrows Serv iceExcepti on {
  115                    try  {
  116                             User u ser = getC urrentUser ();
  117  
  118                             QIRSta tusType ex istingStat us = new Q IRStatusTy pe();
  119                             existi ngStatus.s etCode(QIR StatusType .NEW);
  120                             if (qi r.getId()  != null) {
  121                                      QIR onFi le = qirDA O.findById (qir.getId ());
  122                                      existing Status = o nFile.getQ irStatusTy pe();
  123                             }
  124  
  125                             QIRSta tusType ne wStatus =  qir.getQir StatusType ();
  126  
  127                             boolea n updatedD ueDate = f alse;
  128                             if (ex istingStat us.isNew()  && qir.is Approved() ) {
  129                                      updatedD ueDate = t rue;
  130                             }
  131                             if (ex istingStat us.isAgree d() && new Status.isA greed()
  132                                               && user.is Permission Granted(CC HTPermissi ons.NATION AL_ADMIN))  {
  133                                      updatedD ueDate = t rue;
  134                             }
  135                             if (ex istingStat us.isRepli ed() && ne wStatus.is Replied()  // case NA  updates R eplied QIR
  136                                               && user.is Permission Granted(CC HTPermissi ons.NATION AL_ADMIN))  {
  137                                      updatedD ueDate = t rue;
  138                             }
  139                             if (ex istingStat us.isAppro ved() && n ewStatus.i sApproved( ) // case  NA updates  approved  QIR
  140                                               && user.is Permission Granted(CC HTPermissi ons.NATION AL_ADMIN))  {
  141                                      updatedD ueDate = t rue;
  142                             }
  143  
  144                             if (qi r.isSameVe ndor(user)
  145                                               && (existi ngStatus.i sApproved( ) || exist ingStatus. isAgreed()  || existi ngStatus.i sReplied() )
  146                                               && newStat us.isRepli ed()) {
  147                                      qir.setV endorRespo nseDueDate (null);
  148                                      qir.setE mailRemind erSentDate (null);
  149                             }
  150                             
  151                             if (up datedDueDa te) {
  152                                      /**
  153                                       * Start s a vendor  response  due date c lock on th e next day  email
  154                                       * remin d sent dat e to null
  155                                       */
  156                                      Date sta rt = DateU tils.getWe ekDate();
  157                                      
  158                                      qir.setV endorRespo nseDueDate (DateUtils .forwardBu sinessDays (start, 10 ));
  159                                      qir.setE mailRemind erSentDate (null);
  160                                      Date end  = qir.get VendorResp onseDueDat e();               
  161  
  162                                      Calendar  cld = Cal endar.getI nstance();
  163                                      
  164                                      int this Year = cld .get(Calen dar.YEAR);
  165                                      List<Fed eralHolida y> holiday s = this.s ecuritySer vice.getHo lidays(thi sYear);
  166                                      int curr entMonth =  cld.get(C alendar.MO NTH);
  167                                      
  168                                      // if QI R is creat ed end of  current ye ar and is  due in pre ceding yea r because  holiday ha
  169                                      // curre nt years y ear and wi ll not see  it.
  170                                      if(curre ntMonth ==  Calendar. DECEMBER)  { // works
  171                                               int nextYe ar = cld.g et(Calenda r.YEAR) +  1;
  172                                               List<Feder alHoliday>  nextYears Holidays =  this.secu rityServic e.getHolid ays(nextYe ar);
  173                                               holidays.a ddAll(next YearsHolid ays);
  174                                      }
  175                                      
  176                                      /**
  177                                       * If a  federal ho liday fall s between  a date whe n a vendor
  178                                       * respo nse due da te is set  and a day  when a ven dor respon se is
  179                                       * due,  forward a  vendor res ponse due  date by on e day. If  a
  180                                       * vendo r response  due date  falls on e ither Satu rday or Su nday,
  181                                       * forwa rd a vendo r response  due date  by one day .
  182                                       */
  183                                      
  184                                      for (Fed eralHolida y holiday  : holidays ) {
  185                                               Date fdate  = DateUti ls.truncat e(holiday. getDate(),  Calendar. DAY_OF_MON TH);
  186                                              
  187                                               if (DateUt ils.isDate BetweenIgn oreTime(fd ate, start , end)) {
  188                                                       
  189                                                       cl d.setTime( qir.getVen dorRespons eDueDate() );
  190                                                       Da teUtils.ad d(cld);
  191                                                       qi r.setVendo rResponseD ueDate(cld .getTime() );
  192                                               }
  193                                      }
  194  
  195                             }
  196                             if (qi r.getId()  != null) {
  197                                      QIR onFi le = (QIR)  qirDAO.fi ndById(qir .getId());
  198                                      mergeSer vice.merge QIR(qir, o nFile);
  199                                      QIR pers isted = th is.saveQIR (onFile);
  200                                      if (pers isted.getI d() != nul l && onFil e.getId()  == null) {
  201                                               onFile.set Id(persist ed.getId() );
  202                                      }
  203                                      sendQIRN otificatio nMail(onFi le);
  204                             } else  {
  205                                      // Fill  the audit  fields
  206                                      qir.setR ecordModif iedCount(( short) 1);
  207                                      qir.setR ecordCreat edBy(user. getUsernam e());
  208                                      qir.setR ecordModif iedBy(user .getUserna me());
  209                                      final Da te current Date = Dat eUtils.get CurrentDat eTime();
  210                                      qir.setR ecordCreat edDate(cur rentDate);
  211                                      qir.setR ecordModif iedDate(cu rrentDate) ;
  212                                      QIR pers isted = th is.saveQIR (qir);
  213                                      if (pers isted.getI d() != nul l && qir.g etId() ==  null) {
  214                                               qir.setId( persisted. getId());
  215                                      }
  216                                      sendQIRN otificatio nMail(qir) ;
  217                             }
  218                    } ca tch (Excep tion e) {
  219                             throw  new Servic eException (e.getMess age(), e);
  220                    }
  221           }
  222  
  223           pu blic QIR s aveQIR(QIR  qir) thro ws Service Exception  {
  224                    retu rn qirDAO. saveQIR(qi r);
  225           }
  226  
  227           pu blic void  updateQIRA ttachment( QIRAttachm ent qirAtt achment) t hrows Serv iceExcepti on {
  228                    qirD AO.updateA ttachment( qirAttachm ent);
  229           }
  230  
  231           pu blic void  deleteQIRA ttachment( long qirAt tachmentId ) throws S erviceExce ption {
  232                    
  233                    QIRA ttachment  onFile = q irDAO.find Attachment ById(qirAt tachmentId );
  234                    
  235                    fina l String u ser = getC urrentUser ().getName ();
  236                    fina l String u serCreated Attachemnt  = onFile. getRecordC reatedBy() ;
  237                    
  238                    if ( user.equal sIgnoreCas e(userCrea tedAttache mnt)) {
  239  
  240                             qirDAO .deleteAtt achment(qi rAttachmen tId);
  241  
  242                    } el se {
  243  
  244                             throw  new Servic eException ("The user  " + user
  245                                               + " is not  authorize d to delet e a record  created b y " + user CreatedAtt achemnt);
  246  
  247                    }
  248  
  249           }
  250  
  251           pu blic Integ er generat eVendorRes ponseDueNo tification s() throws  ServiceEx ception {
  252                    try  {
  253                             List<S tring> qir Ids = qirD AO.getVend orResponse DueQIRIds( );
  254                             
  255                             for (S tring id :  qirIds) {
  256                                      sendVend orResponse DueEMail(i d);
  257                             }
  258                             
  259                             return  qirIds.si ze();
  260                    } ca tch (Excep tion e) {
  261                             throw  new Servic eException (e.getMess age(), e);
  262                    }
  263           }
  264  
  265           pu blic void  sendVendor ResponseDu eEMail(Str ing qirId)  throws Se rviceExcep tion {
  266                    
  267                    try  {
  268                             QIR qi r = qirDAO .findById( Long.parse Long(qirId ));
  269                             sendVe ndorRespon seDueNotif ication(qi r);
  270                             qir.se tEmailRemi nderSentDa te(new Dat e());
  271                             qirDAO .saveQIR(q ir);
  272                    } ca tch (Excep tion e) {
  273                             throw  new Servic eException (e.getMess age(), e);
  274                    }
  275           }
  276           
  277           @O verride
  278           pu blic QIRSt atusType f indQIRStat usTypeByNa me(String  name) {
  279                    retu rn qirDAO. findQIRSta tusTypeByN ame(name);
  280           }
  281  
  282           pr ivate void  sendQIRNo tification Mail(QIR q ir) {
  283                    
  284                    
  285                    try  {
  286                             List<U ser> userL ist = new  ArrayList< User>();
  287                             String  qirStatus Code = qir .getQirSta tusType(). getCode();
  288  
  289                             List<U ser> natio nalAdmins  = getNatio nalAdmins( );
  290                             List<U ser> visnA dmins = ge tVisnAdmin s(qir.getV isn());
  291                             List<U ser> facil ityAdmins  = getFacil ityAdmins( qir.getFac ility());
  292                             List<U ser> submi tters = ge tSubmitter (qir.getSu bmittedBy( ));
  293  
  294                             if (na tionalAdmi ns != null )
  295                                      userList .addAll(na tionalAdmi ns);
  296                             if (vi snAdmins ! = null)
  297                                      userList .addAll(vi snAdmins);
  298                             if (fa cilityAdmi ns != null )
  299                                      userList .addAll(fa cilityAdmi ns);
  300                             if (su bmitters ! = null)
  301                                      userList .addAll(su bmitters);
  302  
  303                             if (QI RStatusTyp eEnum.New. toString() .equalsIgn oreCase(qi rStatusCod e) || 
  304                                               QIRStatusT ypeEnum.Wi thdrawn.to String().e qualsIgnor eCase(qirS tatusCode) ) {
  305                                      // defau lt list
  306                             } else  {
  307                                      List<Use r> vendors  = getVend ors(qir.ge tVendor()) ;
  308                                      List<Use r> nac = g etNAC();
  309                                      if (vend ors != nul l)
  310                                               userList.a ddAll(vend ors);
  311                                      if (nac  != null)
  312                                               userList.a ddAll(nac) ;
  313                             }
  314  
  315                             // Onl y active u sers will  receive e- mails
  316                             List<S tring> ema ilList = g etEmailLis t(userList );
  317                             if (em ailList.si ze() > 0)  {
  318                                      Map<Stri ng, Object > data = n ew HashMap <String, O bject>();
  319                                      data.put ("qir", qi r);
  320                                      data.put ("webAppUr l", getWeb AppUrl());
  321                                      if (subm itters !=  null && su bmitters.s ize() > 0)  {
  322                                               User submi tter = sub mitters.ge t(0);
  323                                               qir.setSub mittedByNa me(submitt er.getFull Name());
  324                                               qir.setEma ilSubmitte dByName(su bmitter.ge tFirstName () + " " +  submitter .getLastNa me());
  325                                      }
  326                                      UserPrin cipal curr entUser =  getCurrent User();
  327                                      if (curr entUser !=  null) {
  328                                               qir.setMod ifiedByNam e(getCurre ntUser().g etFullName ());
  329                                      }
  330                                      SimpleMa ilMessage  template =  processMa ilTemplate (data, qir Notificati onMessage) ;
  331                                      String[]  toAddress  = new Str ing[emailL ist.size() ];
  332                                      for (int  i = 0; i  < emailLis t.size();  i++) {
  333                                               toAddress[ i] = email List.get(i );
  334                                      }
  335                                      template .setTo(toA ddress);
  336                                      send(tem plate);
  337                             }
  338                    } ca tch (Servi ceExceptio n e) {
  339                             logger .error("QI R Service  : sendQIRN otificatio nMail Fail ed", e);
  340                    }
  341           }
  342  
  343           pr ivate void  sendVendo rResponseD ueNotifica tion(QIR q ir) {
  344                    
  345                    try  {
  346                             List<U ser> userL ist = new  ArrayList< User>();
  347                             List<U ser> natio nalAdmins  = getNatio nalAdmins( );
  348                             List<U ser> vendo rs = getVe ndors(qir. getVendor( ));
  349                             List<U ser> nac =  getNAC();
  350                             List<U ser> visnA dmins = ge tVisnAdmin s(qir.getV isn());
  351                             List<U ser> facil ityAdmins  = this.get FacilityAd mins(qir.g etFacility ());
  352                             List<U ser> submi tter = thi s.getSubmi tter(qir.g etSubmitte dBy());
  353  
  354                             if (na tionalAdmi ns != null )
  355                                      userList .addAll(na tionalAdmi ns);
  356                             if (ve ndors != n ull)
  357                                      userList .addAll(ve ndors);
  358                             if (na c != null)
  359                                      userList .addAll(na c);
  360                             if (vi snAdmins ! = null)
  361                                      userList .addAll(vi snAdmins);
  362                             if (fa cilityAdmi ns != null )
  363                                      userList .addAll(fa cilityAdmi ns);
  364                             if (su bmitter !=  null)
  365                                      userList .addAll(su bmitter);
  366  
  367                             // Onl y active u sers will  receive e- mails
  368                             List<S tring> ema ilList = g etEmailLis t(userList );
  369  
  370                             if (lo gger.isDeb ugEnabled( )) {
  371                                      logger.d ebug("Send ing e-mail  to the fo llowing: "  + emailLi st + " for  QIR " + q ir.getId() );
  372                             }
  373                             if (em ailList.si ze() > 0)  {
  374                                      Map<Stri ng, Object > data = n ew HashMap <String, O bject>();
  375                                      data.put ("qir", qi r);
  376                                      data.put ("webAppUr l", getWeb AppUrl());
  377                                      SimpleMa ilMessage  template =  processMa ilTemplate (data, qir VendorResp onseDueMai lMessage);
  378                                      String[]  toAddress  = new Str ing[emailL ist.size() ];
  379                                      for (int  i = 0; i  < emailLis t.size();  i++) {
  380                                               toAddress[ i] = email List.get(i );
  381                                      }
  382                                      template .setTo(toA ddress);
  383  
  384                                      // Send  a message  with no at tachment
  385                                      send(tem plate, nul l, Priorit y.HIGH);
  386                                      if (logg er.isDebug Enabled())  {
  387                                               logger.deb ug(
  388                                                                "E-m ail was se nt success fully to t he followi ng: " + em ailList +  " for QIR  " + qir.ge tId());
  389                                      }
  390                             }
  391                    } ca tch (Servi ceExceptio n e) {
  392                             logger .error("QI R Service  : sendVend orResponse DueNotific ation Fail ed", e);
  393                    }
  394           }
  395  
  396           pr ivate List <User> get NAC() thro ws Service Exception  {
  397                    Sear chCriteria  searchCri teria = ne w SearchCr iteria();
  398                    List <String> r oles = new  ArrayList <String>() ;
  399                    role s.add(CCHT Roles.NAC) ;
  400                    sear chCriteria .setRoles( roles);
  401                    retu rn securit yService.f indAppUser s(searchCr iteria);
  402           }
  403  
  404           pr ivate List <User> get NationalAd mins() thr ows Servic eException  {
  405                    Sear chCriteria  searchCri teria = ne w SearchCr iteria();
  406                    List <String> r oles = new  ArrayList <String>() ;
  407                    role s.add(CCHT Roles.NATI ONAL_ADMIN );
  408                    sear chCriteria .setRoles( roles);
  409                    retu rn securit yService.f indAppUser s(searchCr iteria);
  410           }
  411  
  412           pr ivate List <User> get VisnAdmins (SimpleVis n visn) th rows Servi ceExceptio n {
  413                    if ( visn != nu ll) {
  414                             Search Criteria s earchCrite ria = new  SearchCrit eria();
  415                             List<S tring> rol es = new A rrayList<S tring>();
  416                             roles. add(CCHTRo les.VISN_A DMIN);
  417                             search Criteria.s etRoles(ro les);
  418                             List<S tring> vis ns = new A rrayList<S tring>();
  419                             visns. add(visn.g etCode());
  420                             search Criteria.s etVisns(vi sns);
  421                             List<U ser> admin s = securi tyService. findAppUse rs(searchC riteria);
  422                             return  admins;
  423                    } el se {
  424                             return  new Array List<User> ();
  425                    }
  426           }
  427  
  428           pr ivate List <User> get FacilityAd mins(Simpl eFacility  facility)  throws Ser viceExcept ion {
  429                    if ( facility ! = null) {
  430                             Search Criteria s earchCrite ria = new  SearchCrit eria();
  431                             List<S tring> rol es = new A rrayList<S tring>();
  432                             roles. add(CCHTRo les.FACILI TY_ADMIN);
  433                             search Criteria.s etRoles(ro les);
  434                             List<S tring> fac ilities =  new ArrayL ist<String >();
  435                             facili ties.add(f acility.ge tCode());
  436                             search Criteria.s etStations (facilitie s);
  437                             List<U ser> admin s = securi tyService. findAppUse rs(searchC riteria);
  438                             return  admins;
  439                    } el se {
  440                             return  new Array List<User> ();
  441                    }
  442           }
  443  
  444           pr ivate List <User> get Vendors(Ve ndor vendo r) throws  ServiceExc eption {
  445                    if ( vendor !=  null) {
  446                             Search Criteria s earchCrite ria = new  SearchCrit eria();
  447                             List<S tring> rol es = new A rrayList<S tring>();
  448                             roles. add(CCHTRo les.VENDOR );
  449                             search Criteria.s etRoles(ro les);
  450                             List<S tring> ven dors = new  ArrayList <String>() ;
  451                             vendor s.add(vend or.getName ());
  452                             search Criteria.s etVendors( vendors);
  453                             List<U ser> vendo rpocs = se curityServ ice.findAp pUsers(sea rchCriteri a);
  454                             return  vendorpoc s;
  455                    } el se {
  456                             return  new Array List<User> ();
  457                    }
  458           }
  459  
  460           pr ivate List <User> get Submitter( String use rname) thr ows Servic eException  {
  461                    if ( StringUtil s.isNotEmp ty(usernam e)) {
  462                             Search Criteria s earchCrite ria = new  SearchCrit eria();
  463                             search Criteria.s etSAMAccou ntName(use rname);
  464                             return  securityS ervice.fin dAppUsers( searchCrit eria);
  465                    } el se {
  466                             return  new Array List<User> ();
  467                    }
  468           }
  469  
  470           @O verride
  471           pu blic List< QIRStatusT ype> getAl lQIRStatus Types() {
  472                    retu rn qirDAO. findAllQIR StatusType s();
  473           }
  474  
  475   }