Commit 9bd3c1c8 by 焦荣

新增全省案件接口

parent 4aa47734
......@@ -139,4 +139,18 @@ public class DataSourceConfig {
public DataSource nineDataSource(){
return ninethDbProperties().initializeDataSourceBuilder().build();
}
@Bean(name="hnxzxtdbProperties")
@Qualifier("hnxzxtdb")
@ConfigurationProperties(prefix = "spring.datasource.hnxzxtdb")
public DataSourceProperties tenthDbProperties(){
return new DataSourceProperties();
}
@Bean(name="hnxzxtdb")
@Qualifier("hnxzxtdb")
@ConfigurationProperties(prefix = "spring.datasource.hnxzxtdb")
public DataSource tenthDataSource(){
return tenthDbProperties().initializeDataSourceBuilder().build();
}
}
package com.founder.config;
import org.apache.ibatis.session.SqlSessionFactory;
import org.mybatis.spring.SqlSessionFactoryBean;
import org.mybatis.spring.SqlSessionTemplate;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Primary;
import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
import javax.sql.DataSource;
@Configuration
@MapperScan(basePackages = {"com.founder.hnxzxtDao"}, sqlSessionFactoryRef = "hnxzxtSqlSessionFactory")
public class MybatisHnxzxtDbConfig {
static final String MAPPER_LOCATION = "classpath:mapper/*.xml";
@Autowired
@Qualifier("hnxzxtdb")
private DataSource hnxzxtdb;
@Bean(name="hnxzxtSqlSessionFactory")
@Primary
public SqlSessionFactory baseSqlSessionFactory() throws Exception {
SqlSessionFactoryBean factoryBean = new SqlSessionFactoryBean();
factoryBean.setDataSource(hnxzxtdb);
factoryBean.setMapperLocations(new PathMatchingResourcePatternResolver().getResources(MybatisHnxzxtDbConfig.MAPPER_LOCATION));
return factoryBean.getObject();
}
@Bean(name="hnxzxtSqlSessionTemplate")
@Primary
public SqlSessionTemplate baseSqlSessionTemplate() throws Exception {
return new SqlSessionTemplate(baseSqlSessionFactory());
}
}
......@@ -2,6 +2,7 @@ package com.founder.controller;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
import com.founder.hnxzasj.TbStasjService;
import com.founder.model.*;
import com.founder.model.amsis.Plainimg;
import com.founder.model.amsis.Rollimg;
......@@ -54,6 +55,8 @@ public class RyfkController {
private IYhkCjService yhkCjService;
@Autowired
private TbywztryService tbywztryService;
@Autowired
private TbStasjService tbStasjServiceImpl;
......@@ -90,12 +93,15 @@ public class RyfkController {
bzcs = 1;
}
List<TbStAsj> qsasjxxlist = tbStasjServiceImpl.getAsjByzjhm(zjhm);
// ryjbxx = rycjService.getRycjInfoByzjhm(zjhm);
// List qgajxxlist = this.getQgajxx2(zjhm);
//List ztryxxlist = new ArrayList();
model.addAttribute("ryjbxx",ryjbxx); //常口
model.addAttribute("qgajxxlist",qgajxxlist); //全国案件信息
model.addAttribute("qsasjxxlist",qsasjxxlist); //全国案件信息
model.addAttribute("ztryxxlist",ztryxxlist); //在逃人员信息
model.addAttribute("bzcs",bzcs); //比中次数
model.addAttribute("tbZwbzxx",tbZwbzxx); //比中信息
......
package com.founder.hnxzasj;
import com.founder.model.TbStAsj;
import com.founder.model.TbStZtryxx;
import java.util.List;
/**
* Created by libin on 2018/4/12.
*/
public interface TbStasjService {
TbStZtryxx getZtryByztbh(String zjhm);
List<TbStAsj> getAsjByzjhm(String zjhm);
}
package com.founder.hnxzasj.impl;
import com.founder.hnxzasj.TbStasjService;
import com.founder.hnxzxtDao.TbstAsjMapper;
import com.founder.model.TbStAsj;
import com.founder.model.TbStZtryxx;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.List;
@Service
public class TbStasjServiceImpl implements TbStasjService {
@Autowired
private TbstAsjMapper tbstAsjMapper;
@Override
public TbStZtryxx getZtryByztbh(String zjhm) {
return null;
}
@Override
public List<TbStAsj> getAsjByzjhm(String zjhm) {
List<TbStAsj> ztrylist= new ArrayList<TbStAsj>();
ztrylist = tbstAsjMapper.getAsjByzjhm(zjhm);
return ztrylist ;
}
}
package com.founder.hnxzxtDao;
import com.founder.model.TbStAsj;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;
import java.util.List;
@Component
@Mapper
public interface TbstAsjMapper {
TbStAsj getAsj(String ASJBH);
List<TbStAsj> getAsjByzjhm(@Param("zjhm") String zjhm);
}
\ No newline at end of file
......@@ -72,6 +72,13 @@ spring.datasource.ztrydb.password=XZXT
spring.datasource.ztrydb.driver-class-name=oracle.jdbc.driver.OracleDriver
spring.datasource.ztrydb.type: com.alibaba.druid.pool.DruidDataSource
#海南刑专数据源配置
spring.datasource.hnxzxtdb.url=jdbc:oracle:thin:@47.92.129.99:1600:ORCL
spring.datasource.hnxzxtdb.username=XZXT
spring.datasource.hnxzxtdb.password=XZXT
spring.datasource.hnxzxtdb.driver-class-name=oracle.jdbc.driver.OracleDriver
spring.datasource.hnxzxtdb.type: com.alibaba.druid.pool.DruidDataSource
mapper.mappers= com.founder.util.MyMapper
mapper.not-empty= false
mapper.identity= oracle
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.founder.hnxzxtDao.TbstAsjMapper">
<resultMap id="BaseResultMap" type="com.founder.model.TbStAsj">
<result column="ASJBH" jdbcType="VARCHAR" property="ASJBH" />
<result column="XCKYBH" jdbcType="INTEGER" property="XCKYBH" />
<result column="ZCJDDM" jdbcType="VARCHAR" property="ZCJDDM" />
<result column="AJLBDM" jdbcType="DATE" property="AJLBDM" />
<result column="AJMC" jdbcType="VARCHAR" property="AJMC" />
<result column="FXASJSJ" jdbcType="VARCHAR" property="FXASJSJ" />
<result column="FXASJDD_XZQHDM" jdbcType="VARCHAR" property="FXASJDD_XZQHDM" />
<result column="FXASJDD_DZMC" jdbcType="INTEGER" property="FXASJDD_DZMC" />
<result column="JYAQ" jdbcType="VARCHAR" property="JYAQ" />
<result column="FZXYRTZ_JYQK" jdbcType="DATE" property="FZXYRTZ_JYQK" />
<result column="ZAGJ_JYQK" jdbcType="VARCHAR" property="ZAGJ_JYQK" />
<result column="ZADJMS" jdbcType="VARCHAR" property="ZADJMS" />
<result column="ZAMDMS" jdbcType="VARCHAR" property="ZAMDMS" />
<result column="SLSJ" jdbcType="DATE" property="SLSJ" />
<result column="LARQ" jdbcType="VARCHAR" property="LARQ" />
<result column="LADW_GAJGMC" jdbcType="VARCHAR" property="LADW_GAJGMC" />
<result column="ZARY_RS" jdbcType="VARCHAR" property="ZARY_RS" />
<result column="ZCZJ_ZXSJ01" jdbcType="INTEGER" property="ZCZJ_ZXSJ01" />
<result column="ZCZJDW_GAJGMC" jdbcType="VARCHAR" property="ZCZJDW_GAJGMC" />
</resultMap>
<!-- 通过条件联合分页查询,返回数据集 -->
<select id="getAsjByzjhm" parameterType="String" resultMap="BaseResultMap">
select * from tb_st_asj where asjbh in (select asjbh from tb_gl_asj_ry gl where cyzj_zjhm = #{zjhm})
</select>
</mapper>
\ No newline at end of file
......@@ -40,7 +40,7 @@
<a href="#qgsaxx">全国涉案信息<span class="count"><p th:text="${qgajxxlist.size()}"></p></span></a>
</li>
<li>
<a href="#qssaxx">全省涉案信息<span class="count">0</span></a>
<a href="#qssaxx">全省涉案信息<span class="count"><p th:text="${qsasjxxlist.size()}"></p></span></a>
</li>
<li>
<a href="#ztryxx">在逃人员信息<span class="count"><p th:text="${ztryxxlist.size()}"></p></span></a>
......@@ -155,7 +155,46 @@
<div class="line1" id="qssaxx">
<div class="centerbox">
<h1><span class="boder-left" style="top:7px;"></span><p>全省涉案信息<i class="fa fa-angle-double-up iconsq" title="收起" onclick="toggleXx(this)"></i></p></h1>
<div class="bsh">
<div class="bsh" th:each="stasj,stasjStat:${qsasjxxlist}">
<table class="jbxxTableWrap" width="100%">
<tr class="empty">
<td width="5%"></td><td width="10%"></td><td width="23%"></td><td width="10%"></td><td width="23%"></td><td width="10%"></td><td width="23%"></td>
</tr>
<tr>
<td style="width:15%;" th:text="案件 + ${stasjStat.index+1}"></td>
<td class="ar">案件编号:</td>
<td style="width:15%;" th:text="${stasj.ASJBH}"></td>
<td class="ar">案件名称:</td>
<td style="width:15%;" th:text="${stasj.AJMC}"></td>
<td class="ar">现场勘验编号:</td>
<td style="width:15%;" th:text="${stasj.XCKYBH}"></td>
</tr>
<tr>
<td style="width:15%;" ></td>
<td class="ar">发案时间:</td>
<td style="width:15%;" th:text="${stasj.FXASJSJ}"></td>
<td class="ar">发案地点:</td>
<td style="width:15%;" th:text="${stasj.FXASJDD_DZMC}"></td>
<td class="ar">立案日期:</td>
<td style="width:15%;" th:text="${stasj.LARQ}"></td>
</tr>
<tr>
<td style="width:15%;" ></td>
<td class="ar">立案单位:</td>
<td style="width:15%;" th:text="${stasj.LADW_GAJGMC}"></td>
<td class="ar">侦查终结时间:</td>
<td style="width:15%;" th:text="${stasj.ZCZJ_ZXSJ01}"></td>
<td class="ar">侦查终结单位:</td>
<td style="width:15%;" th:text="${stasj.ZCZJDW_GAJGMC}"></td>
</tr>
<tr>
<td style="width:15%;" ></td>
<td class="ar">简要案情:</td>
<td style="width:15%;" colspan="5" th:text="${stasj.JYAQ}"></td>
</tr>
</table>
</div>
</div>
......@@ -219,7 +258,7 @@
<div class="line1" id="zwbzxx">
<div class="centerbox">
<h1><span class="boder-left" style="top:7px;"></span><p>指纹比中信息<i class="fa fa-angle-double-up iconsq" title="收起" onclick="toggleXx(this)"></i></p></h1>
<div class="bsh">
<div class="bsh" th:if="${tbZwbzxx.rwbh} ne null ">
<table class="jbxxTableWrap" width="100%">
<tr class="empty">
<td width="10%"></td><td width="23%"></td><td width="10%"></td><td width="23%"></td><td width="10%"></td><td width="23%"></td>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment