fix : 방첩활동 중간저장
parent
fb75171ad9
commit
b218a81ebb
|
|
@ -149,12 +149,15 @@ public class CounterIntelligenceController {
|
|||
}
|
||||
Integer ciKey = ciService.saveCiActivity(cia, deleteFileSeq);
|
||||
switch (cia.getCiType()) {
|
||||
case "SDI": // 공지사항
|
||||
case "SDI": // 치안수요분석
|
||||
ciService.saveSaftyDemand(cia);
|
||||
break;
|
||||
case "MCI": // 공용게시판
|
||||
case "MCI": // 해양산업보호관리업체
|
||||
ciService.saveManageCompany(cia);
|
||||
break;
|
||||
case "FI": // 외국인커뮤니티모니터링
|
||||
ciService.saveForeigner(cia);
|
||||
break;
|
||||
}
|
||||
|
||||
return ciKey;
|
||||
|
|
@ -209,8 +212,8 @@ public class CounterIntelligenceController {
|
|||
|
||||
cia.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
cia.setQueryInfo();
|
||||
mav.addObject("mciList", ciService.selectCiaManageCompanyList(cia));
|
||||
cia.setContentCnt(ciService.selectCiaManageCompanyListCnt(cia));
|
||||
mav.addObject("fiList", ciService.selectCiaForeignerList(cia));
|
||||
cia.setContentCnt(ciService.selectCiaForeignerListCnt(cia));
|
||||
cia.setPaginationInfo();
|
||||
mav.addObject("searchParams", cia);
|
||||
return mav;
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ package com.dbnt.faisp.main.counterIntelligence.mapper;
|
|||
import com.dbnt.faisp.main.counterIntelligence.model.CiWorkStatistics;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CounterIntelligenceActivity;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CounterIntelligenceWork;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.ForeignerInfo;
|
||||
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
|
@ -28,4 +30,8 @@ public interface CounterIntelligenceMapper {
|
|||
List<CounterIntelligenceActivity> selectCiaManageCompanyList(CounterIntelligenceActivity cia);
|
||||
|
||||
Integer selectCiaManageCompanyListCnt(CounterIntelligenceActivity cia);
|
||||
|
||||
List<ForeignerInfo> selectCiaForeignerList(CounterIntelligenceActivity cia);
|
||||
|
||||
Integer selectCiaForeignerListCnt(CounterIntelligenceActivity cia);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,8 @@ public class CounterIntelligenceActivity extends BaseModel {
|
|||
@Transient
|
||||
private ManageCompanyInfo manageCompanyInfo;
|
||||
@Transient
|
||||
private ForeignerInfo foreignerInfo;
|
||||
@Transient
|
||||
private String mgtOrgan;
|
||||
@Transient
|
||||
private String companyNm;
|
||||
|
|
@ -71,6 +73,21 @@ public class CounterIntelligenceActivity extends BaseModel {
|
|||
@Transient
|
||||
private String name;
|
||||
@Transient
|
||||
private String manager;
|
||||
@Transient
|
||||
private String commuLocation;
|
||||
@Transient
|
||||
private String commuNational;
|
||||
@Transient
|
||||
private String commuAddress;
|
||||
@Transient
|
||||
private String selectReason;
|
||||
@Transient
|
||||
private String monitoringInfo;
|
||||
@Transient
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate fixDate;
|
||||
@Transient
|
||||
private List<CiaFile> fileList;
|
||||
@Transient
|
||||
private List<MultipartFile> multipartFileList;
|
||||
|
|
|
|||
|
|
@ -23,6 +23,8 @@ public class ForeignerInfo {
|
|||
@Id
|
||||
@Column(name = "ci_key")
|
||||
private Integer ciKey;
|
||||
@Column(name = "mgt_organ")
|
||||
private String mgtOrgan;
|
||||
@Column(name = "manager")
|
||||
private String manager;
|
||||
@Column(name = "commu_location")
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ import com.dbnt.faisp.main.counterIntelligence.model.CiaFile;
|
|||
import com.dbnt.faisp.main.counterIntelligence.model.CiwFile;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CounterIntelligenceActivity;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CounterIntelligenceWork;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.ForeignerInfo;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.HashTagLinkCiw;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.ManageCompanyInfo;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.SaftyDemandInfo;
|
||||
|
|
@ -246,4 +247,27 @@ public class CounterIntelligenceService extends BaseService {
|
|||
return dbCia;
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void saveForeigner(CounterIntelligenceActivity cia) {
|
||||
ForeignerInfo fi = new ForeignerInfo();
|
||||
fi.setCiKey(cia.getCiKey());
|
||||
fi.setMgtOrgan(cia.getMgtOrgan());
|
||||
fi.setManager(cia.getManager());
|
||||
fi.setCommuLocation(cia.getCommuLocation());
|
||||
fi.setCommuNational(cia.getCommuNational());
|
||||
fi.setCommuAddress(cia.getCommuAddress());
|
||||
fi.setSelectReason(cia.getSelectReason());
|
||||
fi.setMonitoringInfo(cia.getMonitoringInfo());
|
||||
fi.setFixDate(cia.getFixDate());
|
||||
foreignerInfoRepository.save(fi);
|
||||
}
|
||||
|
||||
public List<ForeignerInfo> selectCiaForeignerList(CounterIntelligenceActivity cia) {
|
||||
return ciMapper.selectCiaForeignerList(cia);
|
||||
}
|
||||
|
||||
public Integer selectCiaForeignerListCnt(CounterIntelligenceActivity cia) {
|
||||
return ciMapper.selectCiaForeignerListCnt(cia);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -234,5 +234,51 @@
|
|||
ORDER BY cia.ci_key DESC
|
||||
)a
|
||||
</select>
|
||||
|
||||
<select id="selectCiaForeignerList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity">
|
||||
select cia.ci_key,
|
||||
(select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ,
|
||||
fi.manager,
|
||||
fi.commu_location,
|
||||
fi.commu_national,
|
||||
fi.commu_address,
|
||||
fi.select_reason,
|
||||
fi.monitoring_info,
|
||||
fi.fix_date,
|
||||
cia.wrt_dt
|
||||
from counter_intelligence_activity cia,
|
||||
foreigner_info fi
|
||||
where cia.ci_key = fi.ci_key
|
||||
and fi.mgt_organ in
|
||||
<foreach collection="downOrganCdList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
ORDER BY cia.ci_key DESC
|
||||
LIMIT #{rowCnt} OFFSET #{firstIndex}
|
||||
</select>
|
||||
|
||||
<select id="selectCiaForeignerListCnt" parameterType="CounterIntelligenceActivity" resultType="Integer">
|
||||
select count(*)
|
||||
from(
|
||||
select cia.ci_key,
|
||||
(select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ,
|
||||
fi.manager,
|
||||
fi.commu_location,
|
||||
fi.commu_national,
|
||||
fi.commu_address,
|
||||
fi.select_reason,
|
||||
fi.monitoring_info,
|
||||
fi.fix_date,
|
||||
cia.wrt_dt
|
||||
from counter_intelligence_activity cia,
|
||||
foreigner_info fi
|
||||
where cia.ci_key = fi.ci_key
|
||||
and fi.mgt_organ in
|
||||
<foreach collection="downOrganCdList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
ORDER BY cia.ci_key DESC
|
||||
)a
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -27,7 +27,7 @@ function getCiaForeignerEditModal(ciKey){
|
|||
|
||||
$(document).on('click', '#saveBtn', function (){
|
||||
if(confirm("저장하시겠습니까?")){
|
||||
const formData = new FormData($("#ciaManageCompanyEditForm")[0]);
|
||||
const formData = new FormData($("#ciaForeignerEditForm")[0]);
|
||||
for(const file of files) {
|
||||
if(!file.isDelete)
|
||||
formData.append('uploadFiles', file, file.name);
|
||||
|
|
@ -35,6 +35,7 @@ $(document).on('click', '#saveBtn', function (){
|
|||
$(".text-decoration-line-through").each(function (idx, el){
|
||||
formData.append('fileSeq', $(el).attr("data-fileseq"));
|
||||
})
|
||||
formData.append('monitoringInfo', CrossEditor.GetBodyValue());
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
|
|
|
|||
|
|
@ -5,10 +5,10 @@
|
|||
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body" id="ivsgtEditBody">
|
||||
<form action="#" method="post" id="ciaManageCompanyEditForm">
|
||||
<form action="#" method="post" id="ciaForeignerEditForm">
|
||||
<input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/>
|
||||
<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>
|
||||
<input type="hidden" name="ciType" value="MCI">
|
||||
<input type="hidden" name="ciType" value="FI">
|
||||
<!-- <input type="hidden" name="ciKey" th:value="${cia.ciKey}">
|
||||
<input type="hidden" name="wrtOrgan" th:value="${cia.wrtOrgan}">
|
||||
<input type="hidden" name="wrtPart" th:value="${cia.wrtPart}">
|
||||
|
|
@ -33,6 +33,10 @@
|
|||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" id="fixDate" name="fixDate" readonly>
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-1 col-form-label col-form-label-sm text-center">담당관</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" id="manager" name="manager">
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-1 col-form-label col-form-label-sm text-center">작성일</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" placeholder="작성일자동입력" readonly>
|
||||
|
|
@ -42,28 +46,28 @@
|
|||
<div class="row mb-1">
|
||||
<label for="wrtNm" class="col-sm-1 col-form-label col-form-label-sm text-center">소재지</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" id="cellPhone" name="cellPhone">
|
||||
<input type="text" class="form-control form-control-sm" id="commuLocation" name="commuLocation">
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-1 col-form-label col-form-label-sm text-center">국적</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" id="department" name="department">
|
||||
<input type="text" class="form-control form-control-sm" id="commuNational" name="commuNational">
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-1 col-form-label col-form-label-sm text-center">주소지</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control form-control-sm" id="name" name="name">
|
||||
<div class="col-sm-5">
|
||||
<input type="text" class="form-control form-control-sm" id="commuAddress" name="commuAddress">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label for="contentInfoDiv" class="col-sm-1 col-form-label col-form-label-sm text-center">선정사유</label>
|
||||
<div class="col-sm-11" id="contentInfoDiv">
|
||||
<textarea class="form-control form-control-sm" rows="5" cols="30" name="relatedField"></textarea>
|
||||
<textarea class="form-control form-control-sm" rows="5" cols="30" name="selectReason"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label for="content" class="col-sm-1 col-form-label col-form-label-sm text-center">모니터링 사항</label>
|
||||
<div class="col-sm-11">
|
||||
<div id="editor"></div>
|
||||
<textarea class="d-none" id="content"></textarea>
|
||||
<textarea class="d-none" id="monitoringInfo"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</th:block>
|
||||
|
|
|
|||
|
|
@ -108,11 +108,11 @@
|
|||
<thead>
|
||||
<tr class="table-secondary">
|
||||
<th rowspan="2">관리관서</th>
|
||||
<th rowspan="2">담당관</th>
|
||||
<th colspan="3">대상커뮤니티</th>
|
||||
<th rowspan="2">선정사유</th>
|
||||
<th rowspan="2">모니터링 사항</th>
|
||||
<th rowspan="2">선정일</th>
|
||||
<th rowspan="2">담당자</th>
|
||||
<th rowspan="2">작성자</th>
|
||||
<th rowspan="2">작성일</th>
|
||||
</tr>
|
||||
|
|
@ -123,11 +123,20 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider">
|
||||
<tr class="mciTr">
|
||||
<tr class="fiTr" th:each="list:${fiList}">
|
||||
<th:block>
|
||||
<input type="hidden" class="ciKey" >
|
||||
<input type="hidden" class="ciKey" th:value="${list.ciKey}">
|
||||
</th:block>
|
||||
|
||||
<td th:text="${list.mgtOrgan}"></td>
|
||||
<td th:text="${list.manager}"></td>
|
||||
<td th:text="${list.commuLocation}"></td>
|
||||
<td th:text="${list.commuNational}"></td>
|
||||
<td th:text="${list.commuAddress}"></td>
|
||||
<td th:text="${list.selectReason}"></td>
|
||||
<td th:utext="${list.monitoringInfo}"></td>
|
||||
<td th:text="${list.fixDate}"></td>
|
||||
<td th:text="${list.mgtOrgan}"></td>
|
||||
<td th:text="${#temporals.format(list.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
|||
Loading…
Reference in New Issue