feat: 민원신청 답변 반영

main
minuk926 2 years ago
parent 50c850d5e7
commit 40d2402793

@ -49,6 +49,23 @@ public class FimsConst {
private final String desc; private final String desc;
} }
/**
* <pre>
* () - FIM017
* </pre>
*/
@Getter
@AllArgsConstructor
public enum CtznStmtStsCode {
UNPROCESSED("01", "미처리"),
ANS_AVAILABLE("02", "답변가능"),
ANS_COMPLETE("03", "답변완료")
;
private final String code;
private final String desc;
}
/** /**
* <pre> * <pre>
* () - FIM018 * () - FIM018
@ -56,7 +73,7 @@ public class FimsConst {
*/ */
@Getter @Getter
@AllArgsConstructor @AllArgsConstructor
public enum CtznSttemntStatusCode { public enum CtznStmtDtlStsCode {
UNPROCESSED("01", "미처리"), UNPROCESSED("01", "미처리"),
ACCEPTANCE("02", "수용"), ACCEPTANCE("02", "수용"),
NOT_ACCEPTABLE("03", "불수용") NOT_ACCEPTABLE("03", "불수용")

@ -38,6 +38,7 @@ public interface IEcCtznSttemntMapper {
CtznStmtDTO.CtznStmtAns selectEcCtznSttemntAnswer(final CtznStmtDTO.Request dto); CtznStmtDTO.CtznStmtAns selectEcCtznSttemntAnswer(final CtznStmtDTO.Request dto);
void updateStatusAndRegltIdOfEcCtznSttemntDetail(final CtznStmtDTO.Request dto); void updateStatusAndRegltIdOfEcCtznSttemntDetail(final CtznStmtDTO.Request dto);
<T> void updateStmtProcessStsOfEcCtznSttemnt(T t);
void saveEcCtznSttemntAnswer(final CtznStmtDTO.CtznStmtAns dto); void saveEcCtznSttemntAnswer(final CtznStmtDTO.CtznStmtAns dto);
@ -49,4 +50,6 @@ public interface IEcCtznSttemntMapper {
List<CmmFileDTO> dragAndDropIsExists(CmmFileDTO.FileDtl vo); List<CmmFileDTO> dragAndDropIsExists(CmmFileDTO.FileDtl vo);
} }

@ -206,6 +206,7 @@ public class CtznStmtDTO implements Serializable { //extends ExtlEsbDataType {
private String register; private String register;
private String updtDt; private String updtDt;
private String updusr; private String updusr;
private String ctznSttemntProcessSttus;
private Set<Integer> indexs = new HashSet<>(); private Set<Integer> indexs = new HashSet<>();
@ -289,6 +290,9 @@ public class CtznStmtDTO implements Serializable { //extends ExtlEsbDataType {
*/ */
private String register; private String register;
private String ctznSttemntStatusCode = FimsConst.CtznStmtStsCode.ANS_COMPLETE.getCode();
private String updusr;
public static NatlNewspaperSendXmlDTO getCtznStmtAnsDTO(CtznStmtDTO.CtznStmtAns dto) { public static NatlNewspaperSendXmlDTO getCtznStmtAnsDTO(CtznStmtDTO.CtznStmtAns dto) {
return NatlNewspaperSendXmlDTO.builder() return NatlNewspaperSendXmlDTO.builder()
.interfaceSeqN(dto.getInterfaceSeqN()) .interfaceSeqN(dto.getInterfaceSeqN())
@ -329,6 +333,7 @@ public class CtznStmtDTO implements Serializable { //extends ExtlEsbDataType {
private String regltProcessSttusCode; private String regltProcessSttusCode;
private String ctznSttemntStatusCode; private String ctznSttemntStatusCode;
private String ctznSttemntDetailProcessSttus;
// 단속ID // 단속ID
private String regltId; private String regltId;
private String erppId; private String erppId;

@ -233,7 +233,7 @@ public class EcCctvCrackdownService implements IEcCctvCrackdownService {
mapper.insertRtRegltFromEcExtrRegltCntc(dto); mapper.insertRtRegltFromEcExtrRegltCntc(dto);
dto.setUpdusr(getUserInfo().getUniqId()); dto.setUpdusr(getUserInfo().getUniqId());
dto.setExtrlRegltCntcProcessSttus(FimsConst.CtznSttemntStatusCode.ACCEPTANCE.getCode()); dto.setExtrlRegltCntcProcessSttus(FimsConst.CtznStmtDtlStsCode.ACCEPTANCE.getCode());
mapper.updateStatusAndRegltIdOfEcExtrRegltCntc(dto); mapper.updateStatusAndRegltIdOfEcExtrRegltCntc(dto);
} }
@ -253,7 +253,7 @@ public class EcCctvCrackdownService implements IEcCctvCrackdownService {
// 상태 변경 // 상태 변경
dto.setUpdusr(getUserInfo().getUniqId()); dto.setUpdusr(getUserInfo().getUniqId());
dto.setExtrlRegltCntcProcessSttus(FimsConst.CtznSttemntStatusCode.NOT_ACCEPTABLE.getCode()); dto.setExtrlRegltCntcProcessSttus(FimsConst.CtznStmtDtlStsCode.NOT_ACCEPTABLE.getCode());
mapper.updateStatusAndRegltIdOfEcExtrRegltCntc(dto); mapper.updateStatusAndRegltIdOfEcExtrRegltCntc(dto);
} }

@ -99,13 +99,19 @@ public class EcCtznSttemntService implements IEcCtznSttemntService {
@Override @Override
@Transactional @Transactional
public void saveRtReglt(final CtznStmtDTO.Request dto) { public void saveRtReglt(final CtznStmtDTO.Request dto) {
// 단속테이블
dto.setRegister(getUserInfo().getUniqId()); dto.setRegister(getUserInfo().getUniqId());
dto.setRegltProcessSttusCode(FimsConst.RegltProcessSttusCode.CRACKDOWN.getCode()); dto.setRegltProcessSttusCode(FimsConst.RegltProcessSttusCode.CRACKDOWN.getCode());
mapper.insertRtRegltFromCtznStmt(dto); mapper.insertRtRegltFromCtznStmt(dto);
// 시민신고 상세 상태 변경
dto.setUpdusr(getUserInfo().getUniqId()); dto.setUpdusr(getUserInfo().getUniqId());
dto.setCtznSttemntStatusCode(FimsConst.CtznSttemntStatusCode.ACCEPTANCE.getCode()); dto.setCtznSttemntDetailProcessSttus(FimsConst.CtznStmtDtlStsCode.ACCEPTANCE.getCode());
mapper.updateStatusAndRegltIdOfEcCtznSttemntDetail(dto); mapper.updateStatusAndRegltIdOfEcCtznSttemntDetail(dto);
// 시민신고 상태 답변가능으로 - 시민신고상세의 모든 상태가 수용 또는 미수용인 경우
dto.setCtznSttemntStatusCode(FimsConst.CtznStmtStsCode.ANS_AVAILABLE.getCode());
mapper.updateStmtProcessStsOfEcCtznSttemnt(dto);
} }
//----------------------------------------------------- //-----------------------------------------------------
@ -122,10 +128,14 @@ public class EcCtznSttemntService implements IEcCtznSttemntService {
// 서손테이블 // 서손테이블
mapper.insertRtErppFromCtznStmt(dto); mapper.insertRtErppFromCtznStmt(dto);
// 상태 변경 // 시민신고 상세 상태 변경
dto.setUpdusr(getUserInfo().getUniqId()); dto.setUpdusr(getUserInfo().getUniqId());
dto.setCtznSttemntStatusCode(FimsConst.CtznSttemntStatusCode.NOT_ACCEPTABLE.getCode()); dto.setCtznSttemntDetailProcessSttus(FimsConst.CtznStmtDtlStsCode.NOT_ACCEPTABLE.getCode());
mapper.updateStatusAndRegltIdOfEcCtznSttemntDetail(dto); mapper.updateStatusAndRegltIdOfEcCtznSttemntDetail(dto);
// 시민신고 상태 답변가능으로 - 시민신고상세의 모든 상태가 수용 또는 미수용인 경우
dto.setCtznSttemntStatusCode(FimsConst.CtznStmtStsCode.ANS_AVAILABLE.getCode());
mapper.updateStmtProcessStsOfEcCtznSttemnt(dto);
} }
//----------------------------------------------------- //-----------------------------------------------------
@ -172,6 +182,11 @@ public class EcCtznSttemntService implements IEcCtznSttemntService {
dto.setRegister(getUserInfo().getUniqId()); dto.setRegister(getUserInfo().getUniqId());
mapper.saveEcCtznSttemntAnswer(dto); mapper.saveEcCtznSttemntAnswer(dto);
// 시민신고 상태 - 답변완료 update
dto.setUpdusr(getUserInfo().getUniqId());
dto.setCtznSttemntStatusCode(FimsConst.CtznStmtStsCode.ANS_COMPLETE.getCode());
mapper.updateStmtProcessStsOfEcCtznSttemnt(dto);
return tgtPath + "/" + fileName; return tgtPath + "/" + fileName;
} }

@ -214,7 +214,7 @@ public class EcNatlNewspaperService implements IEcNatlNewspaperService {
dto.setCvplReqstDt(xmlDto.getPetiRegD()); dto.setCvplReqstDt(xmlDto.getPetiRegD());
dto.setCvplProcessPd(xmlDto.getPetiEndD()); dto.setCvplProcessPd(xmlDto.getPetiEndD());
dto.setCvplRegistDt(xmlDto.getRegD()); dto.setCvplRegistDt(xmlDto.getRegD());
dto.setCtznSttemntProcessSttus(FimsConst.CtznSttemntStatusCode.UNPROCESSED.getCode()); dto.setCtznSttemntProcessSttus(FimsConst.CtznStmtDtlStsCode.UNPROCESSED.getCode());
dto.setRegister(getUserInfo().getUniqId()); dto.setRegister(getUserInfo().getUniqId());
//--------------------------------- //---------------------------------
@ -250,7 +250,7 @@ public class EcNatlNewspaperService implements IEcNatlNewspaperService {
//공통 추가 항목 //공통 추가 항목
dtlDto.setInterfaceSeqN(xmlDto.getInterfaceSeqN()); dtlDto.setInterfaceSeqN(xmlDto.getInterfaceSeqN());
dtlDto.setCtznSttemntDetailProcessSttus(FimsConst.CtznSttemntStatusCode.UNPROCESSED.getCode()); dtlDto.setCtznSttemntDetailProcessSttus(FimsConst.CtznStmtDtlStsCode.UNPROCESSED.getCode());
dtlDto.setSysCode(getUserInfo().getOrgnztId()); dtlDto.setSysCode(getUserInfo().getOrgnztId());
dtlDto.setInsttCode(getUserInfo().getPstinstCode()); dtlDto.setInsttCode(getUserInfo().getPstinstCode());
dtlDto.setRegister(getUserInfo().getUniqId()); dtlDto.setRegister(getUserInfo().getUniqId());

@ -98,23 +98,26 @@
* tb_ec_ctzn_sttemnt_detail : 시민신고 상세 * tb_ec_ctzn_sttemnt_detail : 시민신고 상세
************************************************************************************************************** --> ************************************************************************************************************** -->
<sql id="sqlEcCtznStmtDtl"> <sql id="sqlEcCtznStmtDtl">
SELECT interface_seq_n SELECT tecsd.interface_seq_n
, ctzn_sttemnt_detail_sn , tecsd.ctzn_sttemnt_detail_sn
, vhcle_no , tecsd.vhcle_no
, reglt_id , tecsd.reglt_id
, instt_code , tecsd.instt_code
, sys_code , tecsd.sys_code
, reglt_de_time , tecsd.reglt_de_time
, reglt_place , tecsd.reglt_place
, violt_dtls_nm , tecsd.violt_dtls_nm
, gps_x , tecsd.gps_x
, gps_y , tecsd.gps_y
, ctzn_sttemnt_detail_process_sttus , tecsd.ctzn_sttemnt_detail_process_sttus
, regist_dt , tecsd.regist_dt
, register , tecsd.register
, updt_dt , tecsd.updt_dt
, updusr , tecsd.updusr
FROM tb_ec_ctzn_sttemnt_detail , (SELECT ctzn_sttemnt_process_sttus
FROM tb_ec_ctzn_sttemnt
WHERE interface_seq_n = tecsd.interface_seq_n) AS ctzn_sttemnt_process_sttus
FROM tb_ec_ctzn_sttemnt_detail tecsd
</sql> </sql>
<select id="selectEcCtznSttemntDetails" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtDtl"> <select id="selectEcCtznSttemntDetails" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtDtl">
@ -122,10 +125,10 @@
<include refid="sqlEcCtznStmtDtl"/> <include refid="sqlEcCtznStmtDtl"/>
<where> <where>
<if test='interfaceSeqN != null and interfaceSeqN != ""'> <if test='interfaceSeqN != null and interfaceSeqN != ""'>
AND interface_seq_n = #{interfaceSeqN} AND tecsd.interface_seq_n = #{interfaceSeqN}
</if> </if>
<if test='ctznSttemntDetailSn != null and ctznSttemntDetailSn != ""'> <if test='ctznSttemntDetailSn != null and ctznSttemntDetailSn != ""'>
AND ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn} AND tecsd.ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn}
</if> </if>
</where> </where>
</select> </select>
@ -133,8 +136,8 @@
<select id="selectEcCtznSttemntDetail" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtDtl"> <select id="selectEcCtznSttemntDetail" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtDtl">
/* ec-ctzn-sttemnt-mysql-mapper|selectEcCtznSttemntDetail-민원연계(국민신문고) 상세 조회|julim */ /* ec-ctzn-sttemnt-mysql-mapper|selectEcCtznSttemntDetail-민원연계(국민신문고) 상세 조회|julim */
<include refid="sqlEcCtznStmtDtl"/> <include refid="sqlEcCtznStmtDtl"/>
WHERE interface_seq_n = #{interfaceSeqN} WHERE tecsd.interface_seq_n = #{interfaceSeqN}
AND ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn} AND tecsd.ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn}
</select> </select>
<insert id="insertEcCtznSttemntDetail"> <insert id="insertEcCtznSttemntDetail">
@ -300,13 +303,28 @@
/* ec-ctzn-sttemnt-mysql-mapper|updateStatusAndRegltIdOfEcCtznSttemntDetail-시민신고 상세 단속ID set|julim */ /* ec-ctzn-sttemnt-mysql-mapper|updateStatusAndRegltIdOfEcCtznSttemntDetail-시민신고 상세 단속ID set|julim */
UPDATE tb_ec_ctzn_sttemnt_detail UPDATE tb_ec_ctzn_sttemnt_detail
SET reglt_id = #{regltId} SET reglt_id = #{regltId}
, ctzn_sttemnt_detail_process_sttus = #{ctznSttemntStatusCode} , ctzn_sttemnt_detail_process_sttus = #{ctznSttemntDetailProcessSttus}
, updt_dt = DATE_FORMAT(NOW(), '%Y%m%d%H%i%s') , updt_dt = DATE_FORMAT(NOW(), '%Y%m%d%H%i%s')
, updusr = #{updusr} , updusr = #{updusr}
WHERE interface_seq_n = #{interfaceSeqN} WHERE interface_seq_n = #{interfaceSeqN}
AND ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn} AND ctzn_sttemnt_detail_sn = #{ctznSttemntDetailSn}
</update> </update>
<update id="updateStmtProcessStsOfEcCtznSttemnt">
/* ec-ctzn-sttemnt-mysql-mapper|updateStmtProcessStsOfEcCtznSttemnt-시민신고 진행상태 update : 답변완료 or 답변가능|julim */
UPDATE tb_ec_ctzn_sttemnt
SET ctzn_sttemnt_process_sttus = IF(#{ctznSttemntStatusCode} = '03', #{ctznSttemntStatusCode}
, IF((SELECT COUNT(interface_seq_n)
FROM tb_ec_ctzn_sttemnt_detail
WHERE interface_seq_n = #{interfaceSeqN}
AND ctzn_sttemnt_detail_process_sttus = '01') > 0, ctzn_sttemnt_process_sttus,
#{ctznSttemntStatusCode})
)
, updt_dt = DATE_FORMAT(NOW(), '%Y%m%d%H%i%s')
, updusr = #{updusr}
WHERE interface_seq_n = #{interfaceSeqN}
</update>
<select id="selectEcCtznSttemntAnswer" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtAns"> <select id="selectEcCtznSttemntAnswer" resultType="kr.xit.fims.biz.ec.model.CtznStmtDTO$CtznStmtAns">
/* ec-ctzn-sttemnt-mysql-mapper|selectEcCtznSttemntAnswer-시민신고답변 생성 데이타 조회|cjm */ /* ec-ctzn-sttemnt-mysql-mapper|selectEcCtznSttemntAnswer-시민신고답변 생성 데이타 조회|cjm */
SELECT teei.interface_seq_n SELECT teei.interface_seq_n

@ -240,11 +240,19 @@
}, },
}, },
{ {
header: '단속ID', header: '민원처리상태',
name: 'regltId', name: 'ctznSttemntProcessSttus',
minWidth: 80, minWidth: 80,
sortable: false, sortable: false,
align: 'center' align: 'center',
formatter: 'listItemText',
disabled: true,
editor: {
type: "select",
options: {
listItems: ComboCodeData.ctznSttemntProcessSttus
}
},
}, },
{ {
header: '답변', header: '답변',
@ -256,7 +264,7 @@
type: CustomButtonRenderer, type: CustomButtonRenderer,
options: { options: {
formatter: (props)=>{ formatter: (props)=>{
if(props.grid.getRow(props.rowKey).ctznSttemntDetailProcessSttus === '01') { if(props.grid.getRow(props.rowKey).ctznSttemntProcessSttus !== '01') {
return { return {
formatter: '답변 생성' formatter: '답변 생성'
, element: "text" , element: "text"
@ -268,6 +276,13 @@
} }
} }
}, },
{
header: '단속ID',
name: 'regltId',
minWidth: 80,
sortable: false,
align: 'center'
},
{ {
header: 'GPS 위도', header: 'GPS 위도',
name: 'gpsX', name: 'gpsX',

Loading…
Cancel
Save