feat: 단속자료 현황관리 진행

main
minuk926 2 years ago
parent ab90b311f1
commit 32091747ea

@ -7,6 +7,7 @@ import org.apache.ibatis.session.RowBounds;
import egovframework.rte.psl.dataaccess.mapper.Mapper;
import kr.xit.fims.biz.rt.model.RtDTO;
import kr.xit.framework.biz.cmm.model.CmmFileDTO;
@Mapper
public interface IRtCrackdownMgtMapper {
@ -30,7 +31,10 @@ public interface IRtCrackdownMgtMapper {
void updateRtPayer(final RtDTO.Payer dto);
/*void modifyProcErpp(FimsTotalPopupVO vo);*/
List<CmmFileDTO.FileDtl> selectRtRegltAttchFiles(final RtDTO.Request dto);
}

@ -5,12 +5,14 @@ import java.io.Serializable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
public class RtDTO {
/**
* DTO
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class Reglt {
@ -172,14 +174,13 @@ public class RtDTO {
*
*/
private String lastOpetr;
}
/**
* DTO
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class Erpp implements Serializable {
@ -236,6 +237,7 @@ public class RtDTO {
* / DTO
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class Payer implements Serializable {
@ -382,6 +384,7 @@ public class RtDTO {
* DTO
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class ProcessSttusChangeHist implements Serializable {
@ -426,6 +429,7 @@ public class RtDTO {
* DTO
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class RegltMapng implements Serializable {
@ -455,12 +459,30 @@ public class RtDTO {
}
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public static class Request{
private String vhcleNo;
private String regltId;
private String vhcleNo;
/**
*
*/
private String regltDe;
/**
*
*/
private String registDt;
/**
*
*/
private String regltSeCode;
/**
*
*/
private String jobSeCode;
}
}

@ -6,6 +6,7 @@ import java.util.Map;
import org.apache.ibatis.session.RowBounds;
import kr.xit.fims.biz.rt.model.RtDTO;
import kr.xit.framework.biz.cmm.model.CmmFileDTO;
import kr.xit.framework.biz.cmm.model.XitLoginVO;
import kr.xit.framework.core.utils.XitCmmnUtil;
@ -15,7 +16,7 @@ public interface IRtCrackdownMgtService {
//-----------------------------------------------------
List<RtDTO.Reglt> findRtReglts(final Map<String,Object> paraMap, final RowBounds rowBounds);
RtDTO.Reglt findRtReglt(final RtDTO.Request dto);
<T> RtDTO.Reglt findRtReglt(final T t);
void addRtReglt(final RtDTO.Reglt dto);
void modifyRtReglt(final RtDTO.Reglt dto);
void removeRtReglt(final RtDTO.Reglt dto);
@ -28,7 +29,13 @@ public interface IRtCrackdownMgtService {
List<CmmFileDTO.FileDtl> findRtRegltAttchFiles(RtDTO.Request dto);
default XitLoginVO getUserInfo(){
return XitCmmnUtil.getUserInfo();
}
}

@ -9,6 +9,8 @@ import org.springframework.transaction.annotation.Transactional;
import kr.xit.fims.biz.rt.mapper.IRtCrackdownMgtMapper;
import kr.xit.fims.biz.rt.model.RtDTO;
import kr.xit.fims.biz.utils.FimsBizUtils;
import kr.xit.framework.biz.cmm.model.CmmFileDTO;
import lombok.RequiredArgsConstructor;
@RequiredArgsConstructor
@ -24,8 +26,8 @@ public class RtCrackdownMgtService implements IRtCrackdownMgtService {
@Override
@Transactional(readOnly = true)
public RtDTO.Reglt findRtReglt(final RtDTO.Request dto) {
return mapper.selectRtReglt(dto);
public <T> RtDTO.Reglt findRtReglt(final T t) {
return mapper.selectRtReglt(t);
}
@Override
@Transactional
@ -64,4 +66,9 @@ public class RtCrackdownMgtService implements IRtCrackdownMgtService {
}
@Override
public List<CmmFileDTO.FileDtl> findRtRegltAttchFiles(final RtDTO.Request dto) {
dto.setJobSeCode(FimsBizUtils.getFileJobSeCode(dto.getRegltSeCode()));
return mapper.selectRtRegltAttchFiles(dto);
}
}

@ -1,15 +1,21 @@
package kr.xit.fims.biz.rt.web;
import java.util.Map;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;
import kr.xit.fims.biz.FimsConst;
import kr.xit.fims.biz.rt.model.RtDTO;
import kr.xit.fims.biz.rt.service.IRtCrackdownMgtService;
import kr.xit.framework.core.constants.FrameworkConstants;
import kr.xit.framework.core.model.ResultResponse;
import kr.xit.framework.core.validation.XitBeanValidator;
import kr.xit.framework.support.mybatis.MybatisUtils;
import kr.xit.framework.support.util.AjaxMessageMapRenderer;
import kr.xit.framework.support.util.Checks;
import kr.xit.framework.support.util.constants.MessageKey;
@ -62,6 +68,16 @@ public class RtCrackdownMgtController {
return mav;
}
@GetMapping(value = "/findRtReglts")
public ModelAndView findRtReglts(@RequestParam final Map<String,Object> paraMap) {
//new RtDTO.Reglt();
return ResultResponse.of(service.findRtReglts(paraMap, MybatisUtils.getPagingInfo(paraMap)));
}
@GetMapping(value = "/findRtReglt")
public ModelAndView findRtReglt(final String regltId) {
return ResultResponse.of(service.findRtReglt(regltId));
}
@PostMapping(value="/addRtReglt")
public ModelAndView addRtReglt(RtDTO.Reglt dto){
@ -90,4 +106,8 @@ public class RtCrackdownMgtController {
return mav;
}
@RequestMapping("/findRtRegltAttchFiles")
public ModelAndView findRtRegltAttchFiles(final RtDTO.Request dto) {
return ResultResponse.of(service.findRtRegltAttchFiles(dto));
}
}

@ -25,22 +25,33 @@
, trr.regist_dt
, trr.spcmnt_matter
, trr.reglt_process_sttus_code
-- , tecsd.interface_seq_n
FROM tb_rt_reglt trr
-- JOIN tb_ec_ctzn_sttemnt_detail tecsd
-- ON trr.reglt_id = tecsd.reglt_id
LEFT OUTER JOIN tb_rt_erpp tre
ON trr.reglt_id = tre.reglt_id
</sql>
<!--
/* TODO : 차적조회를 안하고 바로 자료 전송 하여 payer를 알수 없음
JOIN tb_rt_payer trp
ON trr.payer_id = trp.payer_id
*/
LEFT OUTER JOIN tb_rt_erpp tre
ON trr.reglt_id = tre.reglt_id
</sql>
-->
<select id="selectRtReglts" resultType="kr.xit.fims.biz.rt.model.RtDTO$Reglt">
/* rt-reglt-and-erpp-mysql-mapper|selectRtReglts-단속 목록 조회|julim */
/** 단속자료 단건 조회 */
<include refid="sqlRtReglt"/>
<where>
<if test='sch_date_opt eq "regltDe"'>
AND trr.reglt_de BETWEEN #{sch_date_from} AND #{sch_date_to}
</if>
<if test='sch_date_opt eq "registDt"'>
AND trr.regist_dt BETWEEN #{sch_date_from} AND #{sch_date_to}
</if>
<if test='vhcleNo != null and vhcleNo != ""'>
AND INSTR(trr.vhcle_no, #{vhcleNo}) > 0
</if>
</where>
</select>
<select id="selectRtReglt" resultType="kr.xit.fims.biz.rt.model.RtDTO$Reglt">
@ -146,4 +157,36 @@
</update>
<!-- *************************************************************************************************************
* 단속자료 첨부파일 목록 조회
************************************************************************************************************** -->
<select id="selectRtRegltAttchFiles" resultType="kr.xit.framework.biz.cmm.model.CmmFileDTO$FileDtl">
/* rt-reglt-and-erpp-mysql-mapper|selectRtRegltAttchFiles-단속자료 첨부파일 목록 조회|julim */
SELECT tcfd.file_mastr_id
, tcfd.file_id
, tcfd.orginl_file_nm
, tcfd.file_cntnts_ty
, tcfd.file_extsn
, tcfd.file_cpcty
, tcfd.file_cours
, tcfd.regist_dt
, tcfd.register
FROM tb_cmm_file_mastr tcfm
JOIN tb_cmm_file_detail tcfd
ON tcfm.file_mastr_id = tcfd.file_mastr_id
WHERE tcfm.job_se_code = #{jobSeCode}
<if test='regltSeCode eq "01" or regltSeCode eq "02" or regltSeCode eq "07"'>
-- 외부연계 : CCTV-고정형, CCTV-이동형, CCTV-버스장착형(버스전용차로)
AND tcfm.file_job_id = (SELECT extrl_reglt_cntc_id
FROM tb_ec_extrl_reglt_cntc
WHERE reglt_id = #{regltId})
</if>
<if test='regltSeCode eq "09"'>
-- 시민신고(국민신문고)
AND tcfm.file_job_id = (SELECT CONCAT(interface_seq_n, ctzn_sttemnt_detail_sn)
FROM tb_ec_ctzn_sttemnt_detail
WHERE reglt_id = #{regltId})
</if>
</select>
</mapper>

@ -14,8 +14,8 @@
<li>
<span class="title"><label style="padding-right: 26px;">조회일자 :</label></span>
<select id="sch_date_opt" name="sch_date_opt" class="selectBox">
<option value="1">단속일자</option>
<option value="2">등록일자</option>
<option value="regltDe">단속일자</option>
<option value="registDt">등록일자</option>
</select>
<!-- tag lib sample -->
@ -27,13 +27,13 @@
<input id="sch_date_from" class="inputText cal" name="sch_date_from" type="text" title="시작 날짜 선택">
<button type="button" name="sch_date_from" class="calendar"><span class="ico far fa-calendar-alt">
<%-- <img style="width:18px;" src="${ctx }/resources/ens/content/images/common/main/calendar.png"/><em>달력</em></span> --%>
<img style="width:18px;" src="${ctx }/resources/biz/content/images/common/main/calendar.png"/><em>달력</em></span>
<img style="width:18px;" src="${ctx}/resources/biz/content/images/common/main/calendar.png"/><em>달력</em></span>
</button>
~
<input id="sch_date_to" class="inputText cal" name="sch_date_to" type="text" title="종료 날짜 선택" placeholder="날짜를 선택하세요">
<button type="button" name="sch_date_to" class="calendar"><span class="ico far fa-calendar-alt">
<%-- <img style="width:18px;" src="${ctx }/resources/ens/content/images/common/main/calendar.png"/><em>달력</em></span> --%>
<img style="width:18px;" src="${ctx }/resources/biz/content/images/common/main/calendar.png"/><em>달력</em></span>
<img style="width:18px;" src="${ctx}/resources/biz/content/images/common/main/calendar.png"/><em>달력</em></span>
</button>
</span>
</li>
@ -41,7 +41,7 @@
<li style="padding-bottom:10px; padding-left: 40px;">
<span class="title">상태 : </span>
<select id="sch_opt" name="sch_opt" class="selectBox">
<option value="1">차량번호</option>
<option value="vhcleNo">차량번호</option>
</select>
</li>
<input type="text" id="sch_word" name="sch_word" value="">
@ -212,11 +212,19 @@
};
const gridDatasource = {
initialRequest: false, // 화면 load시 조회 안함 - default
initialRequest: true, // 화면 load시 조회 안함 - default
api: {
readData: {
url: '<c:url value="/fims/biz/rt/findRt0200List.do"/>'
,serializer: (params) => fnAddPageInfo(document.frmSearch, params)
url: '<c:url value="/fims/biz/rt/findRtReglts.do"/>'
,serializer: (params) => {
const param = {
sch_date_opt: $('#sch_date_opt').val()
,sch_date_from: $('#sch_date_from').val()
,sch_date_to: $('#sch_date_to').val()
,[$('#sch_opt').val()]: $('#sch_word').val()
}
return getPageParam(param, params);
}
}
}
};

@ -148,8 +148,8 @@
downloadImg: () => {
cmmAjax({
showSuccessMsg: false
,url: '<c:url value="/fims/biz/ec/findNatlNewspaperAttchFiles.do"/>'
,data: {interfaceSeqN: '${dto.interfaceSeqN}'}
,url: '<c:url value="/fims/biz/rt/findRtRegltAttchFiles.do"/>'
,data: {regltId:'${dto.regltId}', regltSeCode: '${dto.regltSeCode}'}
,success: (res) => {
cmmImgDownload('#imgList', res.data?.contents, true);
}
Loading…
Cancel
Save