Index: ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/ljsrmyy/HerpPathManagerImpl.java =================================================================== diff -u -r17646 -r17729 --- ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/ljsrmyy/HerpPathManagerImpl.java (.../HerpPathManagerImpl.java) (revision 17646) +++ ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/ljsrmyy/HerpPathManagerImpl.java (.../HerpPathManagerImpl.java) (revision 17729) @@ -23,7 +23,9 @@ import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jdbc.core.ResultSetExtractor; +import com.forgon.databaseadapter.service.DateQueryAdapter; import com.forgon.directory.model.OrgUnit; +import com.forgon.disinfectsystem.common.CssdUtils; import com.forgon.disinfectsystem.datasynchronization.model.PatientInfoVO; import com.forgon.disinfectsystem.entity.basedatamanager.toussedefinition.TousseInstance; import com.forgon.disinfectsystem.entity.useRecord.UseRecord; @@ -336,7 +338,7 @@ patientInfo.setWashHandNurse(patientArray[15]); patientInfo.setCircuitNurse(patientArray[16]); patientInfo.setSpecialInfection(patientArray[17]); - patientInfo.setType(patientNumber.equals(patientInfo.getHospitalNumber()) ? PatientInfoVO.TYPE_HOSPITAL : PatientInfoVO.TYPE_CLINIC); + patientInfo.setType(StringUtils.isBlank(patientNumber) || StringUtils.equals(patientInfo.getHospitalNumber() , patientNumber) ? PatientInfoVO.TYPE_HOSPITAL : PatientInfoVO.TYPE_CLINIC); departCoding = orgUnit.getOrgUnitCoding(); if(!departCodingSet.contains(departCoding)){ @@ -346,6 +348,7 @@ useRecord.setDepart(depart); useRecord.setDoctorName(patientArray[8]); useRecord.setEnteringDate(now); + useRecord.setOperator(applicant); //录入日期取中间表的日期 try{ @@ -359,7 +362,8 @@ useRecord.setPatientName(patientInfo.getPatientName()); useRecord.setHospitalNum(patientInfo.getHospitalNumber()); useRecord.setTreatmentNum(patientInfo.getClinicNumber()); - useRecord.setStatus(UseRecord.STATUS_APPLIED); + useRecord.setOperationRoom(patientInfo.getOpRoomId()); + useRecord.setStatus(UseRecord.STATUS_UNAUDITED); //病人年龄 if(StringUtils.isNotBlank(patientInfo.getPatientAge())){ @@ -424,10 +428,13 @@ } } - //原有老的方式调用 if(success){ - useRecordManager.createRecyclingApplicationByUseRecords(StringUtils.join(idList.toArray(), ";"), applicant, depart, departCoding); + //原有老的方式调用(基于V4.0) + //useRecordManager.createRecyclingApplicationByUseRecords(StringUtils.join(idList.toArray(), ";"), applicant, depart, departCoding); + //新的v4.1处理方式 + useRecordManager.createRecyclingApplicationByUseRecords(idList, applicant, depart, departCoding, + new Date(), CssdUtils.getSystemSetConfigByName("applicationFormType")); //如果调用成功则将对应的医嘱信息表的记录的状态置为1 updateRecordStatus(true , succUserecordIdList); }else{ @@ -449,8 +456,8 @@ try { //更新消毒供应追溯系统的手麻使用记录处理状态 updateCSSDUserRecordStatus(success , userecordIdList); - //更新手麻系统的使用记录处理状态 - updateHerpPathUserRecordStatus(success , userecordIdList); + //更新手麻系统的使用记录处理状态(等对方加了status字段后再调用) + //updateHerpPathUserRecordStatus(success , userecordIdList); } catch (Exception e) { e.printStackTrace(); logger.error(e); @@ -463,7 +470,7 @@ * @param userecordIdList herp接口使用记录id集合 */ private void updateCSSDUserRecordStatus(boolean success , List userecordIdList){ - String userecordUpdateSql = "update LyUseRecordMainResult set lastUpdateTime=sysdate , status = " + + String userecordUpdateSql = "update LyUseRecordMainResult set lastUpdateTime="+ dateQueryAdapter.getTodayAdapter() +" , status = " + (success ? LyUseRecordMainResult.STATUS_SUCC : LyUseRecordMainResult.STATUS_FAIL) + " where 1=2"; if(CollectionUtils.isNotEmpty(userecordIdList)){ String userecordIds = ""; Index: ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/CommonHerpPathManagerImpl.java =================================================================== diff -u -r17646 -r17729 --- ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/CommonHerpPathManagerImpl.java (.../CommonHerpPathManagerImpl.java) (revision 17646) +++ ssts-userecord/src/main/java/com/forgon/disinfectsystem/useRecord/hrepPath/CommonHerpPathManagerImpl.java (.../CommonHerpPathManagerImpl.java) (revision 17729) @@ -20,6 +20,7 @@ import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jdbc.core.ResultSetExtractor; +import com.forgon.databaseadapter.service.DateQueryAdapter; import com.forgon.directory.model.OrgUnit; import com.forgon.disinfectsystem.datasynchronization.model.PatientInfoVO; import com.forgon.disinfectsystem.entity.basedatamanager.toussedefinition.TousseInstance; @@ -52,6 +53,12 @@ protected UseRecordManager getUseRecordManager() { return null; } + + protected DateQueryAdapter dateQueryAdapter; + + public void setDateQueryAdapter(DateQueryAdapter dateQueryAdapter){ + this.dateQueryAdapter = dateQueryAdapter; + } protected String submitUseRecordByPatientNumberAndApplicant(String patientNumber,String applicant) { logger.debug("更新该病历的器械包使用记录接口:住院号patientNumber=" + patientNumber+",申请人applicant="+applicant); Index: ssts-web/src/main/resources/spring/projects/ljsrmyy/applicationContext-path.xml =================================================================== diff -u --- ssts-web/src/main/resources/spring/projects/ljsrmyy/applicationContext-path.xml (revision 0) +++ ssts-web/src/main/resources/spring/projects/ljsrmyy/applicationContext-path.xml (revision 17729) @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + 5 + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file Index: ssts-web/src/main/resources/spring/projects/ljsrmyy/timer.xml =================================================================== diff -u --- ssts-web/src/main/resources/spring/projects/ljsrmyy/timer.xml (revision 0) +++ ssts-web/src/main/resources/spring/projects/ljsrmyy/timer.xml (revision 17729) @@ -0,0 +1,32 @@ + + + + + + + + + + + + + timingSubmitUseRecord + + + + + + 0 0/1 * * * ? + + + + + + + + + + + + + \ No newline at end of file