강석 최 2023-01-06 18:22:22 +09:00
commit 98ee5f5630
19 changed files with 174 additions and 70 deletions

View File

@ -120,8 +120,12 @@ public class CounterIntelligenceController {
@GetMapping("/ciaSaftyDemandList") @GetMapping("/ciaSaftyDemandList")
public ModelAndView ciaSaftyDemandList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){ public ModelAndView ciaSaftyDemandList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){
ModelAndView mav = new ModelAndView("counterIntelligence/ciaSaftyDemandList"); ModelAndView mav = new ModelAndView("counterIntelligence/ciaSaftyDemandList");
String accessAuth = authMgtService.selectAccessConfigList
(loginUser.getUserSeq(), "/counterIntelligence/ciaSaftyDemandList").get(0).getAccessAuth();
mav.addObject("accessAuth", accessAuth);
cia.setDownOrganCdList(loginUser.getDownOrganCdList()); cia.setDownOrganCdList(loginUser.getDownOrganCdList());
cia.setWrtUserSeq(loginUser.getUserSeq());
cia.setQueryInfo(); cia.setQueryInfo();
mav.addObject("sdiList", ciService.selectCiaSaftyDemandList(cia)); mav.addObject("sdiList", ciService.selectCiaSaftyDemandList(cia));
cia.setContentCnt(ciService.selectCiaSaftyDemandListCnt(cia)); cia.setContentCnt(ciService.selectCiaSaftyDemandListCnt(cia));
@ -187,7 +191,11 @@ public class CounterIntelligenceController {
@GetMapping("/ciaManageCompanyList") @GetMapping("/ciaManageCompanyList")
public ModelAndView ciaManageCompanyList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){ public ModelAndView ciaManageCompanyList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){
ModelAndView mav = new ModelAndView("counterIntelligence/ciaManageCompanyList"); ModelAndView mav = new ModelAndView("counterIntelligence/ciaManageCompanyList");
String accessAuth = authMgtService.selectAccessConfigList
(loginUser.getUserSeq(), "/counterIntelligence/ciaManageCompanyList").get(0).getAccessAuth();
mav.addObject("accessAuth", accessAuth);
cia.setWrtUserSeq(loginUser.getUserSeq());
cia.setDownOrganCdList(loginUser.getDownOrganCdList()); cia.setDownOrganCdList(loginUser.getDownOrganCdList());
cia.setQueryInfo(); cia.setQueryInfo();
mav.addObject("mciList", ciService.selectCiaManageCompanyList(cia)); mav.addObject("mciList", ciService.selectCiaManageCompanyList(cia));
@ -223,7 +231,11 @@ public class CounterIntelligenceController {
@GetMapping("/ciaForeignerList") @GetMapping("/ciaForeignerList")
public ModelAndView ciaForeignerList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){ public ModelAndView ciaForeignerList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){
ModelAndView mav = new ModelAndView("counterIntelligence/ciaForeignerList"); ModelAndView mav = new ModelAndView("counterIntelligence/ciaForeignerList");
String accessAuth = authMgtService.selectAccessConfigList
(loginUser.getUserSeq(), "/counterIntelligence/ciaForeignerList").get(0).getAccessAuth();
mav.addObject("accessAuth", accessAuth);
cia.setWrtUserSeq(loginUser.getUserSeq());
cia.setDownOrganCdList(loginUser.getDownOrganCdList()); cia.setDownOrganCdList(loginUser.getDownOrganCdList());
cia.setQueryInfo(); cia.setQueryInfo();
mav.addObject("fiList", ciService.selectCiaForeignerList(cia)); mav.addObject("fiList", ciService.selectCiaForeignerList(cia));
@ -259,7 +271,11 @@ public class CounterIntelligenceController {
@GetMapping("/ciaEduList") @GetMapping("/ciaEduList")
public ModelAndView ciaEduList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){ public ModelAndView ciaEduList(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceActivity cia){
ModelAndView mav = new ModelAndView("counterIntelligence/ciaEduList"); ModelAndView mav = new ModelAndView("counterIntelligence/ciaEduList");
String accessAuth = authMgtService.selectAccessConfigList
(loginUser.getUserSeq(), "/counterIntelligence/ciaEduList").get(0).getAccessAuth();
mav.addObject("accessAuth", accessAuth);
cia.setWrtUserSeq(loginUser.getUserSeq());
cia.setDownOrganCdList(loginUser.getDownOrganCdList()); cia.setDownOrganCdList(loginUser.getDownOrganCdList());
cia.setQueryInfo(); cia.setQueryInfo();
mav.addObject("eiList", ciService.selectCiaEduList(cia)); mav.addObject("eiList", ciService.selectCiaEduList(cia));
@ -294,6 +310,7 @@ public class CounterIntelligenceController {
@PostMapping("/deleteCounterIntelligenceActivity") @PostMapping("/deleteCounterIntelligenceActivity")
public void deleteCounterIntelligenceActivity(@AuthenticationPrincipal UserInfo loginUser,@RequestBody CounterIntelligenceActivity cia){ public void deleteCounterIntelligenceActivity(@AuthenticationPrincipal UserInfo loginUser,@RequestBody CounterIntelligenceActivity cia){
cia.setContentStatus("DST008");
ciService.deleteCounterIntelligenceActivity(cia); ciService.deleteCounterIntelligenceActivity(cia);
} }

View File

@ -3,6 +3,8 @@ package com.dbnt.faisp.main.ivsgtMgt.majorStatus;
import com.dbnt.faisp.main.authMgt.service.AuthMgtService; import com.dbnt.faisp.main.authMgt.service.AuthMgtService;
import com.dbnt.faisp.main.codeMgt.model.CodeMgt;
import com.dbnt.faisp.main.codeMgt.service.CodeMgtService;
import com.dbnt.faisp.main.equip.model.Equip; import com.dbnt.faisp.main.equip.model.Equip;
import com.dbnt.faisp.main.ivsgtMgt.majorStatus.model.MajorStatus; import com.dbnt.faisp.main.ivsgtMgt.majorStatus.model.MajorStatus;
import com.dbnt.faisp.main.ivsgtMgt.majorStatus.repository.MajorStatusRepository; import com.dbnt.faisp.main.ivsgtMgt.majorStatus.repository.MajorStatusRepository;
@ -26,12 +28,15 @@ public class MajorStatusController {
private final AuthMgtService authMgtService; private final AuthMgtService authMgtService;
private final MajorStatusService majorStatusService; private final MajorStatusService majorStatusService;
private final CodeMgtService codeMgtService;
@GetMapping("/majorStatusPage") @GetMapping("/majorStatusPage")
public ModelAndView majorStatus(@AuthenticationPrincipal UserInfo loginUser, MajorStatus majorStatus){ public ModelAndView majorStatus(@AuthenticationPrincipal UserInfo loginUser, MajorStatus majorStatus){
ModelAndView mav = new ModelAndView("ivsgt/majorStatus/majorStatusPage"); ModelAndView mav = new ModelAndView("ivsgt/majorStatus/majorStatusPage");
mav.addObject("mstList", codeMgtService.selectCodeMgtList("MST"));
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList()); mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
mav.addObject("searchParams", majorStatus); mav.addObject("searchParams", majorStatus);
@ -61,6 +66,7 @@ public class MajorStatusController {
} }
//mav.addObject("mstList", codeMgtService.selectCodeMgtList("MST"));
mav.addObject("majorStatus", majorStatus); mav.addObject("majorStatus", majorStatus);
mav.addObject("userSeq", loginUser.getUserSeq()); mav.addObject("userSeq", loginUser.getUserSeq());
return mav; return mav;

View File

@ -87,17 +87,10 @@ public class MajorStatusService extends BaseService {
} }
} }
@Transactional
public void deleteContent(MajorStatus majorStatus){ public void deleteContent(MajorStatus majorStatus){
majorStatus = majorStatusRepository.findById(majorStatus.getMajorKey()).orElse(null);
//파일삭제 majorStatus.setContentStatus("DST008");
List<MajorFile> MajorFileList = majorFileRepository.findByMajorKey(majorStatus.getMajorKey());
if(MajorFileList != null) {
for(MajorFile file: MajorFileList){
deleteStoredFile(new File(file.getSavePath(), file.getConvNm()));
}
}
majorFileRepository.deleteByMajorKey(majorStatus.getMajorKey());
majorStatusRepository.deleteById(majorStatus.getMajorKey());
} }
private void deleteMajorFile(Integer majorKey, List<Integer> deleteFileSeq) { private void deleteMajorFile(Integer majorKey, List<Integer> deleteFileSeq) {

View File

@ -135,7 +135,7 @@
<select id="selectCiaSaftyDemandList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity"> <select id="selectCiaSaftyDemandList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity">
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
cia.ci_type, cia.ci_type,
(select item_value from code_mgt where item_cd = cia.wrt_organ) as wrt_organ, (select item_value from code_mgt where item_cd = cia.wrt_organ) as wrt_organ,
sdi.local_info, sdi.local_info,
@ -148,6 +148,7 @@
safty_demand_info sdi safty_demand_info sdi
where cia.ci_key = sdi.ci_key where cia.ci_key = sdi.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='wrtOrgan != null and wrtOrgan != ""'> <if test='wrtOrgan != null and wrtOrgan != ""'>
and cia.wrt_organ = #{wrtOrgan} and cia.wrt_organ = #{wrtOrgan}
</if> </if>
@ -172,7 +173,7 @@
select count(*) select count(*)
from( from(
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
cia.ci_type, cia.ci_type,
(select item_value from code_mgt where item_cd = cia.wrt_organ) as wrt_organ, (select item_value from code_mgt where item_cd = cia.wrt_organ) as wrt_organ,
sdi.local_info, sdi.local_info,
@ -185,6 +186,7 @@
safty_demand_info sdi safty_demand_info sdi
where cia.ci_key = sdi.ci_key where cia.ci_key = sdi.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='wrtOrgan != null and wrtOrgan != ""'> <if test='wrtOrgan != null and wrtOrgan != ""'>
and cia.wrt_organ = #{wrtOrgan} and cia.wrt_organ = #{wrtOrgan}
</if> </if>
@ -207,7 +209,7 @@
<select id="selectCiaManageCompanyList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity"> <select id="selectCiaManageCompanyList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity">
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
cia.ci_type, cia.ci_type,
(select item_value from code_mgt where item_cd = mci.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = mci.mgt_organ) as mgt_organ,
mci.company_nm, mci.company_nm,
@ -225,6 +227,7 @@
manage_company_info mci manage_company_info mci
where cia.ci_key = mci.ci_key where cia.ci_key = mci.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='wrtOrgan != null and wrtOrgan != ""'> <if test='wrtOrgan != null and wrtOrgan != ""'>
and cia.wrt_organ = #{wrtOrgan} and cia.wrt_organ = #{wrtOrgan}
</if> </if>
@ -252,7 +255,7 @@
select count(*) select count(*)
from( from(
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
cia.ci_type, cia.ci_type,
(select item_value from code_mgt where item_cd = mci.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = mci.mgt_organ) as mgt_organ,
mci.company_nm, mci.company_nm,
@ -270,6 +273,7 @@
manage_company_info mci manage_company_info mci
where cia.ci_key = mci.ci_key where cia.ci_key = mci.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='wrtOrgan != null and wrtOrgan != ""'> <if test='wrtOrgan != null and wrtOrgan != ""'>
and cia.wrt_organ = #{wrtOrgan} and cia.wrt_organ = #{wrtOrgan}
</if> </if>
@ -295,7 +299,7 @@
<select id="selectCiaForeignerList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity"> <select id="selectCiaForeignerList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity">
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
(select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ,
fi.manager, fi.manager,
fi.commu_location, fi.commu_location,
@ -312,6 +316,7 @@
foreigner_info fi foreigner_info fi
where cia.ci_key = fi.ci_key where cia.ci_key = fi.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='manager != null and manager != ""'> <if test='manager != null and manager != ""'>
and fi.manager like '%'||#{manager}||'%' and fi.manager like '%'||#{manager}||'%'
</if> </if>
@ -349,7 +354,7 @@
select count(*) select count(*)
from( from(
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
(select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = fi.mgt_organ) as mgt_organ,
fi.manager, fi.manager,
fi.commu_location, fi.commu_location,
@ -366,6 +371,7 @@
foreigner_info fi foreigner_info fi
where cia.ci_key = fi.ci_key where cia.ci_key = fi.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='manager != null and manager != ""'> <if test='manager != null and manager != ""'>
and fi.manager like '%'||#{manager}||'%' and fi.manager like '%'||#{manager}||'%'
</if> </if>
@ -401,7 +407,7 @@
<select id="selectCiaEduList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity"> <select id="selectCiaEduList" parameterType="CounterIntelligenceActivity" resultType="CounterIntelligenceActivity">
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
(select item_value from code_mgt where item_cd = ei.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = ei.mgt_organ) as mgt_organ,
ei.edu_date, ei.edu_date,
ei.edu_type, ei.edu_type,
@ -415,6 +421,7 @@
edu_info ei edu_info ei
where cia.ci_key = ei.ci_key where cia.ci_key = ei.ci_key
and cia.content_status != 'DST008' and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='mgtOrgan != null and mgtOrgan != ""'> <if test='mgtOrgan != null and mgtOrgan != ""'>
and ei.mgt_organ = #{mgtOrgan} and ei.mgt_organ = #{mgtOrgan}
</if> </if>
@ -449,7 +456,7 @@
select count(*) select count(*)
from( from(
select cia.ci_key, select cia.ci_key,
cia.content_status, (select item_value from code_mgt where item_cd = cia.content_status) as content_status,
(select item_value from code_mgt where item_cd = ei.mgt_organ) as mgt_organ, (select item_value from code_mgt where item_cd = ei.mgt_organ) as mgt_organ,
ei.edu_date, ei.edu_date,
ei.edu_type, ei.edu_type,
@ -462,6 +469,8 @@
from counter_intelligence_activity cia, from counter_intelligence_activity cia,
edu_info ei edu_info ei
where cia.ci_key = ei.ci_key where cia.ci_key = ei.ci_key
and cia.content_status != 'DST008'
and ((cia.wrt_user_seq = #{wrtUserSeq} and cia.content_status = 'DST001') or cia.content_status = 'DST007')
<if test='mgtOrgan != null and mgtOrgan != ""'> <if test='mgtOrgan != null and mgtOrgan != ""'>
and ei.mgt_organ = #{mgtOrgan} and ei.mgt_organ = #{mgtOrgan}
</if> </if>

View File

@ -7,6 +7,7 @@
<sql id="selectMajorListWhere"> <sql id="selectMajorListWhere">
<where> <where>
a.content_status &lt;> 'DST008'
<if test='majorType != null and majorType != ""'> <if test='majorType != null and majorType != ""'>
and a.major_type = #{majorType} and a.major_type = #{majorType}
</if> </if>

View File

@ -101,3 +101,25 @@ $(document).on('click', '#excelDown', function (){
exportExcel("방첩교육 실시 현황","ciaEduTb"); exportExcel("방첩교육 실시 현황","ciaEduTb");
}) })
$(document).on('click', '#deleteBtn', function (){
const ciKey = $(this).attr("data-cikey");
if(confirm("삭제 하시겠습니까?")){
$.ajax({
type : 'POST',
url : "/counterIntelligence/deleteCounterIntelligenceActivity",
data : JSON.stringify({ciKey:ciKey}),
contentType: 'application/json',
beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
},
success : function() {
alert("삭제처리 되었습니다.");
location.reload();
},
error : function(xhr, status) {
alert("삭제처리에 실패하였습니다");
}
})
}
})

View File

@ -106,3 +106,25 @@ $(document).on('click', '#excelDown', function (){
exportExcel("외국인 커뮤니티 모니터링 현황","ciaForeignerTb"); exportExcel("외국인 커뮤니티 모니터링 현황","ciaForeignerTb");
}) })
$(document).on('click', '#deleteBtn', function (){
const ciKey = $(this).attr("data-cikey");
if(confirm("삭제 하시겠습니까?")){
$.ajax({
type : 'POST',
url : "/counterIntelligence/deleteCounterIntelligenceActivity",
data : JSON.stringify({ciKey:ciKey}),
contentType: 'application/json',
beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
},
success : function() {
alert("삭제처리 되었습니다.");
location.reload();
},
error : function(xhr, status) {
alert("삭제처리에 실패하였습니다");
}
})
}
})

View File

@ -95,3 +95,25 @@ $(document).on('click', '#editBtn', function (){
$(document).on('click', '#excelDown', function (){ $(document).on('click', '#excelDown', function (){
exportExcel("해양산업보호 관리업체 현황","mciTb"); exportExcel("해양산업보호 관리업체 현황","mciTb");
}) })
$(document).on('click', '#deleteBtn', function (){
const ciKey = $(this).attr("data-cikey");
if(confirm("삭제 하시겠습니까?")){
$.ajax({
type : 'POST',
url : "/counterIntelligence/deleteCounterIntelligenceActivity",
data : JSON.stringify({ciKey:ciKey}),
contentType: 'application/json',
beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
},
success : function() {
alert("삭제처리 되었습니다.");
location.reload();
},
error : function(xhr, status) {
alert("삭제처리에 실패하였습니다");
}
})
}
})

View File

@ -73,7 +73,7 @@ $(document).on('click', '#deleteBtn', function (){
$.ajax({ $.ajax({
type : 'POST', type : 'POST',
url : "/counterIntelligence/deleteCounterIntelligenceActivity", url : "/counterIntelligence/deleteCounterIntelligenceActivity",
data : {ciKey:ciKey,contentStatus:'DST008'}, data : JSON.stringify({ciKey:ciKey}),
contentType: 'application/json', contentType: 'application/json',
beforeSend: function (xhr){ beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val()); xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());

View File

@ -1,5 +1,10 @@
$("#jqueryBtn").click(function(){
$(".quiz-text").text("Javascript");
$(".quiz-text").css('color', 'blue');
});
$(document).on('click', '#addMajorBtn', function (){ $(document).on('click', '#addMajorBtn', function (){
getEditModal(null) getEditModal(null)
@ -20,7 +25,7 @@ $(document).on('click', '.tr', function (){
// }); // });
$(document).on('click', '#saveBtn', function (){ $(document).on('click', '#saveBtn', function (){
saveContent("boardEditForm") saveContent("MajorEditForm")
}) })
$(document).on('click', '#editBtn', function (){ $(document).on('click', '#editBtn', function (){
@ -45,7 +50,7 @@ $(document).on('click', '#deleteMajorBtn', function (){
const majorKey = $('input[name=majorKey]').val(); const majorKey = $('input[name=majorKey]').val();
console.log(majorKey); console.log(majorKey);
if(confirm("삭제하시겠습니까?")){ if(confirm("삭제하시겠습니까?")){
contentFade("in"); //contentFade("in");
$.ajax({ $.ajax({
type : 'POST', type : 'POST',
url : "/ivsgt/deleteContent", url : "/ivsgt/deleteContent",
@ -56,10 +61,12 @@ $(document).on('click', '#deleteMajorBtn', function (){
}, },
success : function(data) { success : function(data) {
alert("삭제 처리되었습니다."); alert("삭제 처리되었습니다.");
//contentFade("out");
location.reload(); location.reload();
}, },
error : function(xhr, status) { error : function(xhr, status) {
alert("삭제 처리에 실패하였습니다"); alert("삭제 처리에 실패하였습니다");
//contentFade("out");
} }
}) })
} }
@ -132,12 +139,17 @@ function getViewModal(majorKey){
}); });
} }
function saveContent(formId, majorType){ function saveContent(contentStatus){
if(contentCheck(formId)){
if(confirm("저장하시겠습니까?")){ if(confirm("저장하시겠습니까?")){
let flag = true;
if(contentStatus === "DST007"){
flag = contentCheck();
}
if(flag){
contentFade("in"); contentFade("in");
$("#content").val(""); const MajorEditForm = $("#MajorEditForm");
const formData = new FormData($("#"+formId)[0]); MajorEditForm.find("contentStatus").val(contentStatus);
const formData = new FormData(MajorEditForm[0]);
for(const file of files) { for(const file of files) {
if(!file.isDelete) if(!file.isDelete)
formData.append('uploadFiles', file, file.name); formData.append('uploadFiles', file, file.name);

View File

@ -72,6 +72,7 @@
<table class="table table-sm table-bordered table-hover" id="ciaEduTb"> <table class="table table-sm table-bordered table-hover" id="ciaEduTb">
<thead> <thead>
<tr class="table-secondary"> <tr class="table-secondary">
<th>상태</th>
<th>시행일자</th> <th>시행일자</th>
<th>시행관서</th> <th>시행관서</th>
<th>교육방식</th> <th>교육방식</th>
@ -83,6 +84,7 @@
</thead> </thead>
<tbody class="table-group-divider"> <tbody class="table-group-divider">
<tr class="eiTr" th:each="list:${eiList}"> <tr class="eiTr" th:each="list:${eiList}">
<td th:text="${list.contentStatus}"></td>
<td th:text="${list.eduDate}"></td> <td th:text="${list.eduDate}"></td>
<td th:text="${list.mgtOrgan}"></td> <td th:text="${list.mgtOrgan}"></td>
<td th:text="${list.eduType}"></td> <td th:text="${list.eduType}"></td>

View File

@ -75,6 +75,7 @@
<table class="table table-sm table-bordered table-hover" id="ciaForeignerTb"> <table class="table table-sm table-bordered table-hover" id="ciaForeignerTb">
<thead> <thead>
<tr class="table-secondary"> <tr class="table-secondary">
<th rowspan="2">상태</th>
<th rowspan="2">관리관서</th> <th rowspan="2">관리관서</th>
<th rowspan="2">담당관</th> <th rowspan="2">담당관</th>
<th colspan="3">대상커뮤니티</th> <th colspan="3">대상커뮤니티</th>
@ -92,6 +93,7 @@
</thead> </thead>
<tbody class="table-group-divider"> <tbody class="table-group-divider">
<tr class="fiTr" th:each="list:${fiList}"> <tr class="fiTr" th:each="list:${fiList}">
<td th:text="${list.contentStatus}"></td>
<td th:text="${list.mgtOrgan}"></td> <td th:text="${list.mgtOrgan}"></td>
<td th:text="${list.manager}"></td> <td th:text="${list.manager}"></td>
<td th:text="${list.commuLocation}"></td> <td th:text="${list.commuLocation}"></td>

View File

@ -104,7 +104,7 @@
<div class="col-auto"> <div class="col-auto">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button> <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
<th:block th:if="${accessAuth eq 'ACC003'} or ${viewUserSeq eq cia.wrtUserSeq}"> <th:block th:if="${accessAuth eq 'ACC003'} or ${viewUserSeq eq cia.wrtUserSeq}">
<button type="button" class="btn btn-danger" id="deleteCiWorkBtn" th:data-cikey="${cia.ciKey}">삭제</button> <button type="button" class="btn btn-danger" id="deleteBtn" th:data-cikey="${cia.ciKey}">삭제</button>
</th:block> </th:block>
</div> </div>
<div class="col-auto"> <div class="col-auto">

View File

@ -72,7 +72,7 @@
<table class="table table-sm table-bordered table-hover" id="mciTb"> <table class="table table-sm table-bordered table-hover" id="mciTb">
<thead> <thead>
<tr class="table-secondary"> <tr class="table-secondary">
<th>문서번호</th> <th>상태</th>
<th>관리관서</th> <th>관리관서</th>
<th>업체명</th> <th>업체명</th>
<th>소재지</th> <th>소재지</th>
@ -85,7 +85,7 @@
</thead> </thead>
<tbody class="table-group-divider"> <tbody class="table-group-divider">
<tr class="mciTr" th:each="list:${mciList}"> <tr class="mciTr" th:each="list:${mciList}">
<td th:text="${list.ciKey}"></td> <td th:text="${list.contentStatus}"></td>
<td th:text="${list.mgtOrgan}"></td> <td th:text="${list.mgtOrgan}"></td>
<td th:text="${list.companyNm}"></td> <td th:text="${list.companyNm}"></td>
<td th:text="${list.companyLocation}"></td> <td th:text="${list.companyLocation}"></td>

View File

@ -96,7 +96,7 @@
<div class="col-auto"> <div class="col-auto">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button> <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
<th:block th:if="${accessAuth eq 'ACC003'} or ${viewUserSeq eq cia.wrtUserSeq}"> <th:block th:if="${accessAuth eq 'ACC003'} or ${viewUserSeq eq cia.wrtUserSeq}">
<button type="button" class="btn btn-danger" id="deleteCiWorkBtn" th:data-cikey="${cia.ciKey}">삭제</button> <button type="button" class="btn btn-danger" id="deleteBtn" th:data-cikey="${cia.ciKey}">삭제</button>
</th:block> </th:block>
</div> </div>
<div class="col-auto"> <div class="col-auto">

View File

@ -69,7 +69,7 @@
<table class="table table-sm table-bordered table-hover" id="sdiTb"> <table class="table table-sm table-bordered table-hover" id="sdiTb">
<thead> <thead>
<tr class="table-secondary"> <tr class="table-secondary">
<th>문서번호</th> <th>상태</th>
<th>관서</th> <th>관서</th>
<th>지역특성</th> <th>지역특성</th>
<th>예상문제점</th> <th>예상문제점</th>
@ -79,8 +79,7 @@
</thead> </thead>
<tbody class="table-group-divider"> <tbody class="table-group-divider">
<tr class="sdiTr" th:each="list:${sdiList}"> <tr class="sdiTr" th:each="list:${sdiList}">
<th:block th:if="${list.contentStatus eq 'DST001'} and ${list.wrtUserSeq eq loginUserSeq}"> <td th:text="${list.contentStatus}"></td>
<td th:text="|[임시저장]${list.ciKey}|"></td>
<td th:text="${list.wrtOrgan}"></td> <td th:text="${list.wrtOrgan}"></td>
<td> <td>
<th:block th:if="${#strings.length(list.localInfo)>35}" th:utext="|${#strings.substring(list.localInfo, 0, 35)}...|"></th:block> <th:block th:if="${#strings.length(list.localInfo)>35}" th:utext="|${#strings.substring(list.localInfo, 0, 35)}...|"></th:block>
@ -92,21 +91,6 @@
</td> </td>
<td th:text="|${list.wrtUserGrd} ${list.wrtUserNm}|"></td> <td th:text="|${list.wrtUserGrd} ${list.wrtUserNm}|"></td>
<td th:text="${#temporals.format(list.wrtDt, 'yyyy-MM-dd HH:mm')}"></td> <td th:text="${#temporals.format(list.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
</th:block>
<th:block th:unless="${list.contentStatus eq 'DST001'} and ${list.wrtUserSeq eq loginUserSeq}">
<td th:text="${list.ciKey}"></td>
<td th:text="${list.wrtOrgan}"></td>
<td>
<th:block th:if="${#strings.length(list.localInfo)>35}" th:utext="|${#strings.substring(list.localInfo, 0, 35)}...|"></th:block>
<th:block th:unless="${#strings.length(list.localInfo)>35}" th:utext="${list.localInfo}"></th:block>
</td>
<td>
<th:block th:if="${#strings.length(list.outlookProblem)>35}" th:utext="|${#strings.substring(list.outlookProblem, 0, 35)}...|"></th:block>
<th:block th:unless="${#strings.length(list.outlookProblem)>35}" th:utext="${list.outlookProblem}"></th:block>
</td>
<td th:text="|${list.wrtUserGrd} ${list.wrtUserNm}|"></td>
<td th:text="${#temporals.format(list.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
</th:block>
<th:block> <th:block>
<input type="hidden" class="ciKey" th:value="${list.ciKey}"> <input type="hidden" class="ciKey" th:value="${list.ciKey}">
</th:block> </th:block>

View File

@ -4,6 +4,8 @@
<h5 class="modal-title text-white" id="ciaSaftyDemandViewModalLabel">치안수요 열람</h5> <h5 class="modal-title text-white" id="ciaSaftyDemandViewModalLabel">치안수요 열람</h5>
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div> </div>
<input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/>
<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>
<div class="modal-body" id="ciaSaftyDemandViewBody"> <div class="modal-body" id="ciaSaftyDemandViewBody">
<ul class="nav nav-tabs" id="userTab" role="tablist"> <ul class="nav nav-tabs" id="userTab" role="tablist">
<li class="nav-item" role="presentation"> <li class="nav-item" role="presentation">

View File

@ -5,28 +5,37 @@
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div> </div>
<div class="modal-body" id="MajorEditBody"> <div class="modal-body" id="MajorEditBody">
<form action="#" method="post" id="boardEditForm"> <form action="#" method="post" id="MajorEditForm">
<input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/> <input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/>
<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/> <input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>
<input type="hidden" name="majorKey" th:value="${majorStatus.majorKey}"> <input type="hidden" name="majorKey" th:value="${majorStatus.majorKey}">
<input type="hidden" name="majorType" th:value="${majorStatus.majorType}">
<input type="hidden" name="wrtOrgan" th:value="${majorStatus.wrtOrgan}"> <input type="hidden" name="wrtOrgan" th:value="${majorStatus.wrtOrgan}">
<input type="hidden" name="wrtPart" th:value="${majorStatus.wrtPart}"> <input type="hidden" name="wrtPart" th:value="${majorStatus.wrtPart}">
<input type="hidden" name="wrtUserSeq" th:value="${majorStatus.wrtUserSeq}"> <input type="hidden" name="wrtUserSeq" th:value="${majorStatus.wrtUserSeq}">
<input type="hidden" name="wrtUserGrd" th:value="${majorStatus.wrtUserGrd}"> <input type="hidden" name="wrtUserGrd" th:value="${majorStatus.wrtUserGrd}">
<input type="hidden" name="wrtUserNm" th:value="${majorStatus.wrtUserNm}"> <input type="hidden" name="wrtUserNm" th:value="${majorStatus.wrtUserNm}">
<input type="hidden" name="contentStatus" id="contentStatus" th:value="${majorStatus.contentStatus}">
<div class="row mb-1"> <div class="row mb-1">
<label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-2 col-form-label col-form-label-sm text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<th:block th:each="commonCode:${session.commonCode.get('JT')}"> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq majorStatus.wrtUserGrd}"> <th:block th:if="${commonCode.itemCd eq majorStatus.wrtUserGrd}">
<input type="text" class="form-control" id="wrtUserNm" th:value="|${commonCode.itemValue} ${majorStatus.wrtUserNm}|" readonly> <input type="text" class="form-control form-control-sm" id="wrtUserNm" th:value="|${commonCode.itemValue} ${majorStatus.wrtUserNm}|" readonly>
</th:block> </th:block>
</th:block> </th:block>
</div> </div>
<label for="wrtDt" class="col-sm-2 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-2 col-form-label col-form-label-sm text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control" id="wrtDt" name="wrtDt" th:value="${#temporals.format(majorStatus.wrtDt, 'yyyy-MM-dd HH:mm')}" readonly> <input type="text" class="form-control form-control-sm" id="wrtDt" name="wrtDt" th:value="${#temporals.format(majorStatus.wrtDt, 'yyyy-MM-dd HH:mm')}" readonly>
</div>
<label for="majorType" class="col-sm-2 col-form-label col-form-label-sm text-center">종류</label>
<div class="col-sm-2">
<select class="form-select form-select-sm" id="majorType" name="majorType">
<option value="">선택해주세요.</option>
<th:block th:each="commonCode:${session.commonCode.get('MST')}">
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}" th:selected="${commonCode.itemCd eq majorStatus.majorType}"></option>
</th:block>
</select>
</div> </div>
<!-- <div class="col-sm-auto my-auto">--> <!-- <div class="col-sm-auto my-auto">-->
<!-- <input type="checkbox" id="organChk" name="organChk" value="T" th:checked="${majorStatus.organChk eq 'T'}">--> <!-- <input type="checkbox" id="organChk" name="organChk" value="T" th:checked="${majorStatus.organChk eq 'T'}">-->
@ -34,20 +43,20 @@
<!-- <label for="organChk" class="col-sm-3 col-form-label text-left">소속관서에만 노출</label>--> <!-- <label for="organChk" class="col-sm-3 col-form-label text-left">소속관서에만 노출</label>-->
</div> </div>
<div class="row mb-1"> <div class="row mb-1">
<label for="contentTitle" class="col-sm-2 col-form-label text-center">제목</label> <label for="contentTitle" class="col-sm-2 col-form-label col-form-label-sm text-center">제목</label>
<div class="col-sm-10"> <div class="col-sm-10">
<input type="text" class="form-control" id="contentTitle" name="contentTitle" th:value="${majorStatus.contentTitle}" autocomplete="off"> <input type="text" class="form-control form-control-sm" id="contentTitle" name="contentTitle" th:value="${majorStatus.contentTitle}" autocomplete="off">
</div> </div>
</div> </div>
<div class="row mb-1 justify-content-center"> <div class="row mb-1 justify-content-center">
<label for="editor" class="col-sm-2 col-form-label text-center">내용</label> <label for="editor" class="col-sm-2 col-form-label col-form-label-sm text-center">내용</label>
<div class="col-sm-10"> <div class="col-sm-10">
<div id="editor"></div> <div id="editor"></div>
<textarea id="content" class="d-none" th:utext="${majorStatus.contentInfo}"></textarea> <textarea id="content" class="d-none" th:utext="${majorStatus.contentInfo}"></textarea>
</div> </div>
</div> </div>
<div class="row mb-3"> <div class="row mb-3">
<label for="fileInputer" class="col-sm-2 col-form-label text-center">첨부파일</label> <label for="fileInputer" class="col-sm-2 col-form-label col-form-label-sm text-center">첨부파일</label>
<div class="col-sm-10" style="min-height: 70px;"> <div class="col-sm-10" style="min-height: 70px;">
<div class="w-100 h-100 border border-info rounded text-center" id="uploadDiv"> <div class="w-100 h-100 border border-info rounded text-center" id="uploadDiv">
<th:block th:if="${#arrays.isEmpty(majorStatus.fileList)}"> <th:block th:if="${#arrays.isEmpty(majorStatus.fileList)}">
@ -66,6 +75,7 @@
</form> </form>
</div> </div>
<div class="modal-footer bg-light"> <div class="modal-footer bg-light">
<button type="button" class="btn btn-warning" id="saveTempBtn" data-ContentStatus="DST001">임시저장</button>
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button> <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
<button type="button" class="btn btn-primary" id="saveBtn">저장</button> <button type="button" class="btn btn-primary" id="saveBtn">저장</button>
</div> </div>

View File

@ -64,7 +64,7 @@
<table class="table table-sm table-hover table-bordered"> <table class="table table-sm table-hover table-bordered">
<thead> <thead>
<tr class="table-secondary"> <tr class="table-secondary">
<th></th> <!-- <th></th>-->
<th>종류</th> <th>종류</th>
<th>제목</th> <th>제목</th>
<th>관서</th> <th>관서</th>
@ -78,9 +78,9 @@
<tbody class="table-group-divider"> <tbody class="table-group-divider">
<tr class="tr" th:each="major:${majorList}"> <tr class="tr" th:each="major:${majorList}">
<input type="hidden" class="majorKey" th:value="${major.majorKey}"> <input type="hidden" class="majorKey" th:value="${major.majorKey}">
<td><input type="checkbox" class="trChkBox"></td> <!-- <td><input type="checkbox" class="trChkBox"></td>-->
<td th:test="${major.majorType}"></td> <td th:text="${major.majorType}"></td>
<td th:text="${major.contentTitle}"></td> <td th:text="|${major.contentStatus eq 'DST001'?'[임시]':''}${major.contentTitle}|"></td>
<th:block th:each="commonCode:${session.commonCode.get('OG')}"> <th:block th:each="commonCode:${session.commonCode.get('OG')}">
<td th:if="${major.wrtOrgan eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td> <td th:if="${major.wrtOrgan eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block> </th:block>