| | |
| | | detilsDto.setDcjl("1"); |
| | | detilsDto.setPj("60"); |
| | | detilsDto.setJj("60"); |
| | | detilsDto.setJldw(""); |
| | | detilsDto.setTjbm(""); |
| | | detilsDto.setPs(""); |
| | | detilsDto.setPsbm(""); |
| | | detilsDto.setYyts(""); |
| | | detilsDto.setXtph(""); |
| | | detilsDto.setScph(""); |
| | | detilsDto.setYpxq(""); |
| | | detilsDto.setCdbm(""); |
| | | detilsDto.setKfdw(""); |
| | | detilsDto.setYfdw(""); |
| | | detilsDto.setYysm(""); |
| | | detilsDto.setFzbl("1"); |
| | | detilsDto.setZh("0"); |
| | | outpinmedicapplyDetilsDtos.add(detilsDto); |
| | | } |
| | | } |
| | |
| | | dto1.setCzyksbm("0101"); |
| | | dto1.setCflxbm("A"); |
| | | dto1.setYfbm("1"); |
| | | dto1.setFyts("1"); |
| | | dto1.setMzzd(""); |
| | | dto1.setDetails(outpinmedicapplyDetilsDtos); |
| | | AjaxResult result = controller.Outpinmedicapply(dto1); |
| | | String result1 = getAjaxResult(result); |
| | |
| | | map.put ("yfbm", dao.getYfbm ()); |
| | | map.put ("fyts","1"); |
| | | map.put ("mzzd",""); |
| | | map.put ("details", dao.getDetails ()); |
| | | map.put ("details", dao.getDetails()); |
| | | String post = HttpClientUtils.sendPost (HIS_URL+"Outpinmedicapply", map); |
| | | return AjaxResult.success ().put ("data", post); |
| | | } |
| | |
| | | |
| | | |
| | | /*同步检查 his存储过程*/ |
| | | Map<String, Object> mapss = new HashMap<>(); |
| | | mapss.put("ksmc", "体检中心"); |
| | | mapss.put("str_in",order.getCardId()); |
| | | mapss.put("brid","''"); |
| | | mapss.put("pagecount", 100); |
| | | mapss.put("page", 1); |
| | | mapss.put("status","'1'"); |
| | | AjaxResult results = jcsqdService.getTjJcProByHisCall(mapss); |
| | | AjaxResult results = jcsqdService.getTjJcProByHisCall("体检中心",order.getCardId(),"''",100,1,"'1'"); |
| | | DynamicDataSourceContextHolder.clearDataSourceType(); |
| | | |
| | | |
| | | if (Integer.parseInt(results.get("code").toString()) == 200) { |
| | |
| | | #xiaochengxu 泾川县部署小程序环境使用 |
| | | spring: |
| | | profiles: |
| | | active: test |
| | | active: dev |
| | |
| | | properties.setProperty("druid.username",props.getProperty("hisusername")); |
| | | properties.setProperty("druid.password",props.getProperty("hispassword")); |
| | | dataSource.restart(properties); |
| | | log.info("数据库连接成功!!!"); |
| | | log.info("his数据库连接成功!!!"); |
| | | } catch (Exception e) { |
| | | log.info("数据库连接失败 请联系管理员!"); |
| | | e.printStackTrace(); |
| | |
| | | |
| | | |
| | | @DataSource(value = DataSourceType.SLAVE_HIS) |
| | | List<Map<String, Object>> getTjJcProByHisCall(Map<String, Object> map); |
| | | @Select(" exec usp_his_getexamreportinfo\n" + |
| | | " ${ksmc},\n" + |
| | | " ${brid},\n" + |
| | | " ${str_in},\n" + |
| | | " ${pagecount},\n" + |
| | | " ${page},\n" + |
| | | " ${status}") |
| | | List<Map<String, Object>> getTjJcProByHisCall(@Param("ksmc") String ksmc, |
| | | @Param("str_in")String strIn, |
| | | @Param("brid")String brid, |
| | | @Param("pagecount")int pagecount, |
| | | @Param("page")int page, |
| | | @Param("status")String status); |
| | | } |
| | |
| | | |
| | | void saveLtkjExamJcsqd(String tjh); |
| | | |
| | | AjaxResult getTjJcProByHisCall(Map<String, Object> map); |
| | | AjaxResult getTjJcProByHisCall(String ksmc,String strIn,String brid,int pagecount,int page,String status); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ltkj.common.core.domain.AjaxResult; |
| | | import com.ltkj.hosp.mapper.LtkjExamJcbgdMapper; |
| | | import com.ltkj.hosp.mapper.LtkjExamJcsqdMapper; |
| | | import com.ltkj.hosp.service.LtkjExamJcbgdService; |
| | | import com.ltkj.hosp.service.LtkjExamJcsqdService; |
| | | import com.ltkj.hosp.sqlDomain.LtkjExamJcbgd; |
| | | import com.ltkj.hosp.sqlDomain.LtkjExamJcsqd; |
| | | import com.ltkj.hosp.sqlDomain.LtkjHysqd; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Qualifier; |
| | | import org.springframework.jdbc.core.JdbcTemplate; |
| | | import org.springframework.jdbc.core.namedparam.MapSqlParameterSource; |
| | | import org.springframework.jdbc.core.namedparam.NamedParameterJdbcTemplate; |
| | | import org.springframework.jdbc.core.namedparam.SqlParameterSource; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.sql.DataSource; |
| | | import java.sql.*; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | |
| | | |
| | | @Resource |
| | | private LtkjExamJcsqdMapper mapper; |
| | | |
| | | @Qualifier(value = "slaveHisDataSource") |
| | | @Autowired |
| | | private DataSource dataSource; |
| | | |
| | | |
| | | @Override |
| | |
| | | mapper.saveLtkjExamJcsqd(tjh); |
| | | } |
| | | |
| | | // @Override |
| | | // public AjaxResult getTjJcProByHisCall(String ksmc,String strIn,String brid,int pagecount,int page,String status) { |
| | | // List<Map<String, Object>> tjJcProByHisCall = mapper.getTjJcProByHisCall(ksmc,strIn,brid,pagecount,page,status); |
| | | // return AjaxResult.success().put("data",tjJcProByHisCall); |
| | | // } |
| | | |
| | | |
| | | @Override |
| | | public AjaxResult getTjJcProByHisCall(Map<String, Object> map) { |
| | | List<Map<String, Object>> tjJcProByHisCall = mapper.getTjJcProByHisCall(map); |
| | | return AjaxResult.success().put("data",tjJcProByHisCall); |
| | | public AjaxResult getTjJcProByHisCall(String ksmc,String strIn,String brid,int pagecount,int page,String status) { |
| | | String sql="{exec usp_his_getexamreportinfo(?,?,?,?,?,?)}"; |
| | | Connection connection = null; |
| | | List<Map<String,Object>> list=new ArrayList<>(); |
| | | try { |
| | | connection = dataSource.getConnection(); |
| | | CallableStatement call = connection.prepareCall(sql); |
| | | call.setString(1,ksmc); |
| | | call.setString(2,strIn); |
| | | call.setString(3,brid); |
| | | call.setInt(4,pagecount); |
| | | call.setInt(5,page); |
| | | call.setString(6,status); |
| | | call.execute(); |
| | | ResultSet query = call.executeQuery(); |
| | | ResultSetMetaData data = query.getMetaData(); |
| | | int count = data.getColumnCount(); |
| | | while (query.next()) { |
| | | Map<String,Object>map=new HashMap<>(); |
| | | for (int i = 0; i < count; i++) { |
| | | String s = data.getColumnLabel(i); |
| | | Object object = query.getObject(i); |
| | | map.put(s,object); |
| | | } |
| | | list.add(map); |
| | | } |
| | | } catch (SQLException throwables) { |
| | | throwables.printStackTrace(); |
| | | } |
| | | return AjaxResult.success().put("data",list); |
| | | } |
| | | } |
| | |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ltkj.hosp.mapper.LtkjExamJcsqdMapper"> |
| | | |
| | | <select id="getTjJcProByHisCall" parameterType="java.util.Map" statementType="CALLABLE" resultType="java.util.Map"> |
| | | exec usp_his_getexamreportinfo |
| | | ${ksmc}, |
| | | ${brid}, |
| | | ${str_in}, |
| | | ${pagecount}, |
| | | ${page}, |
| | | ${status} |
| | | </select> |
| | | <!-- <select id="getTjJcProByHisCall" parameterType="java.util.Map" statementType="CALLABLE" resultType="java.util.Map">--> |
| | | <!-- exec usp_his_getexamreportinfo--> |
| | | <!-- #{ksmc},--> |
| | | <!-- #{brid},--> |
| | | <!-- #{str_in},--> |
| | | <!-- #{pagecount},--> |
| | | <!-- #{page},--> |
| | | <!-- #{status}--> |
| | | <!-- </select>--> |
| | | |
| | | |
| | | <!-- <select id="getTjJcProByHisCall" parameterType="java.util.Map" statementType="CALLABLE" resultType="java.util.Map">--> |