외사활동 작업중.
parent
cb12ee46d0
commit
3a85ecf726
|
|
@ -46,6 +46,8 @@ public class BaseService {
|
|||
protected String ciaForeignerPath;
|
||||
@Value("${file.dir.cia.edu}")
|
||||
protected String ciaEduPath;
|
||||
@Value("${file.dir.activityCase}")
|
||||
protected String activityCasePath;
|
||||
|
||||
protected String calculationSize(double fileSize){
|
||||
String[] units = {"bytes", "KB", "MB", "GB", "TB", "PB"};
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ public class CounterIntelligenceController {
|
|||
|
||||
@GetMapping("/ciWorkList")
|
||||
public ModelAndView ciWorkListPage(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceWork ciWork){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWorkBoard");
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWork/ciWorkBoard");
|
||||
mav.addObject("searchUrl", "/counterIntelligence/ciWorkList");
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
(loginUser.getUserSeq(), "/counterIntelligence/ciWorkList").get(0).getAccessAuth();
|
||||
|
|
@ -47,7 +47,7 @@ public class CounterIntelligenceController {
|
|||
|
||||
@GetMapping("/ciWorkEditModal")
|
||||
public ModelAndView ciWorkEditModal(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceWork ciWork){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWorkEditModal");
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWork/ciWorkEditModal");
|
||||
|
||||
mav.addObject("ciwrCodeList", codeMgtService.selectCodeMgtList("CIWR"));
|
||||
if(ciWork.getCiwKey()==null){
|
||||
|
|
@ -71,7 +71,7 @@ public class CounterIntelligenceController {
|
|||
|
||||
@GetMapping("/ciWorkViewModal")
|
||||
public ModelAndView ciWorkViewModal(@AuthenticationPrincipal UserInfo loginUser, CounterIntelligenceWork ciWork){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWorkViewModal");
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/ciWork/ciWorkViewModal");
|
||||
mav.addObject("lineSeparator", '\n');
|
||||
mav.addObject("viewUserSeq", loginUser.getUserSeq());
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
|
|
@ -103,7 +103,7 @@ public class CounterIntelligenceController {
|
|||
if(ciWorkStatistics.getYear()==null){
|
||||
ciWorkStatistics.setYear(LocalDateTime.now().getYear());
|
||||
}
|
||||
ModelAndView mav = new ModelAndView("/counterIntelligence/ciWorkStatistics");
|
||||
ModelAndView mav = new ModelAndView("/counterIntelligence/ciWork/ciWorkStatistics");
|
||||
mav.addObject("yearList", ciService.selectCiWorkYearList());
|
||||
mav.addObject("ciWorkStatisticsList", ciService.selectCiWorkStatisticsList(ciWorkStatistics));
|
||||
mav.addObject("searchParams", ciWorkStatistics);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,99 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase;
|
||||
|
||||
import com.dbnt.faisp.main.authMgt.service.AuthMgtService;
|
||||
import com.dbnt.faisp.main.codeMgt.service.CodeMgtService;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCase;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.service.ActivityCaseService;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CounterIntelligenceWork;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.security.core.annotation.AuthenticationPrincipal;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@RequestMapping("/counterIntelligence")
|
||||
public class ActivityCaseController {
|
||||
|
||||
private final ActivityCaseService activityCaseService;
|
||||
private final AuthMgtService authMgtService;
|
||||
private final CodeMgtService codeMgtService;
|
||||
|
||||
@GetMapping("/activityCaseList")
|
||||
public ModelAndView activityCaseListPage(@AuthenticationPrincipal UserInfo loginUser, ActivityCase activityCase){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/activityCase/activityCaseBoard");
|
||||
mav.addObject("searchUrl", "/counterIntelligence/activityCaseList");
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
(loginUser.getUserSeq(), "/counterIntelligence/activityCaseList").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
if(accessAuth.equals("ACC003")){
|
||||
mav.addObject("downOrganCdList", loginUser.getDownOrganCdList());
|
||||
}else{
|
||||
activityCase.setWrtUserSeq(loginUser.getUserSeq());
|
||||
}
|
||||
|
||||
activityCase.setQueryInfo();
|
||||
mav.addObject("activityCaseList", activityCaseService.selectActivityCaseList(activityCase));
|
||||
activityCase.setContentCnt(activityCaseService.selectActivityCaseCnt(activityCase));
|
||||
activityCase.setPaginationInfo();
|
||||
mav.addObject("searchParams", activityCase);
|
||||
return mav;
|
||||
}
|
||||
|
||||
@GetMapping("/activityCaseEditModal")
|
||||
public ModelAndView activityCaseEditModal(@AuthenticationPrincipal UserInfo loginUser, ActivityCase activityCase){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/activityCase/activityCaseEditModal");
|
||||
|
||||
mav.addObject("ciwrCodeList", codeMgtService.selectCodeMgtList("CIWR"));
|
||||
if(activityCase.getCaseKey()==null){
|
||||
activityCase.setWrtOrgan(loginUser.getOgCd());
|
||||
activityCase.setWrtPart(loginUser.getOfcCd());
|
||||
activityCase.setWrtUserSeq(loginUser.getUserSeq());
|
||||
activityCase.setWrtUserGrd(loginUser.getTitleCd());
|
||||
activityCase.setWrtUserNm(loginUser.getUserNm());
|
||||
activityCase.setWrtDt(LocalDateTime.now());
|
||||
}else{
|
||||
activityCase = activityCaseService.selectActivityCase(activityCase.getCaseKey());
|
||||
}
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
(loginUser.getUserSeq(), "/counterIntelligence/activityCaseList").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
mav.addObject("activityCase", activityCase);
|
||||
return mav;
|
||||
}
|
||||
|
||||
@GetMapping("/activityCaseViewModal")
|
||||
public ModelAndView activityCaseViewModal(@AuthenticationPrincipal UserInfo loginUser, ActivityCase activityCase){
|
||||
ModelAndView mav = new ModelAndView("counterIntelligence/activityCase/activityCaseViewModal");
|
||||
mav.addObject("lineSeparator", '\n');
|
||||
mav.addObject("viewUserSeq", loginUser.getUserSeq());
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
(loginUser.getUserSeq(), "/counterIntelligence/activityCaseList").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
mav.addObject("activityCase", activityCaseService.selectActivityCase(activityCase.getCaseKey()));
|
||||
return mav;
|
||||
}
|
||||
@PostMapping("/saveActivityCase")
|
||||
public Integer saveActivityCase(ActivityCase activityCase,
|
||||
MultipartHttpServletRequest request,
|
||||
@RequestParam(value = "fileSeq", required = false) List<Integer> deleteFileSeq){
|
||||
activityCase.setMultipartFileList(request.getMultiFileMap().get("uploadFiles"));
|
||||
return activityCaseService.saveActivityCase(activityCase, deleteFileSeq);
|
||||
}
|
||||
|
||||
@PostMapping("/deleteActivityCase")
|
||||
public Integer deleteActivityCase(@AuthenticationPrincipal UserInfo loginUser, ActivityCase activityCase){
|
||||
String accessAuth = authMgtService.selectAccessConfigList
|
||||
(loginUser.getUserSeq(), "/counterIntelligence/activityCaseList").get(0).getAccessAuth();
|
||||
if(accessAuth.equals("ACC003")){
|
||||
return activityCaseService.deleteActivityCase(activityCase.getCaseKey());
|
||||
}else{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.mapper;
|
||||
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCase;
|
||||
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 org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Mapper
|
||||
public interface ActivityCaseMapper {
|
||||
|
||||
List<ActivityCase> selectActivityCaseList(ActivityCase activityCase);
|
||||
|
||||
Integer selectActivityCaseCnt(ActivityCase activityCase);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.model;
|
||||
|
||||
import com.dbnt.faisp.config.BaseModel;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CiwFile;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.HashTagLinkCiw;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.DynamicInsert;
|
||||
import org.hibernate.annotations.DynamicUpdate;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "activity_case")
|
||||
public class ActivityCase extends BaseModel {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@Column(name = "case_key")
|
||||
private Integer caseKey;
|
||||
@Column(name = "status")
|
||||
private String status;
|
||||
@Column(name = "division")
|
||||
private String division;
|
||||
@Column(name = "merging")
|
||||
private String merging;
|
||||
@Column(name = "receipt_num")
|
||||
private String receiptNum;
|
||||
@Column(name = "receipt_dt")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime receiptDt;
|
||||
@Column(name = "case_num")
|
||||
private String caseNum;
|
||||
@Column(name = "result_num")
|
||||
private String resultNum;
|
||||
@Column(name = "result_dt")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime resultDt;
|
||||
@Column(name = "receipt_clue")
|
||||
private String receiptClue;
|
||||
@Column(name = "crime")
|
||||
private String crime;
|
||||
@Column(name = "court")
|
||||
private String court;
|
||||
@Column(name = "memo")
|
||||
private String memo;
|
||||
@Column(name = "etc")
|
||||
private String etc;
|
||||
@Column(name = "wrt_organ")
|
||||
private String wrtOrgan;
|
||||
@Column(name = "wrt_part")
|
||||
private String wrtPart;
|
||||
@Column(name = "wrt_user_seq")
|
||||
private Integer wrtUserSeq;
|
||||
@Column(name = "wrt_user_grd")
|
||||
private String wrtUserGrd;
|
||||
@Column(name = "wrt_user_nm")
|
||||
private String wrtUserNm;
|
||||
@Column(name = "wrt_dt")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime wrtDt;
|
||||
|
||||
@Transient
|
||||
private Integer fileCnt;
|
||||
@Transient
|
||||
private List<ActivityCaseFile> fileList;
|
||||
@Transient
|
||||
private List<ActivityCaseOfficer> officerList;
|
||||
@Transient
|
||||
private List<ActivityCasePeople> peopleList;
|
||||
@Transient
|
||||
private List<MultipartFile> multipartFileList;
|
||||
}
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.model;
|
||||
|
||||
import com.dbnt.faisp.config.FileInfo;
|
||||
import lombok.*;
|
||||
import org.hibernate.annotations.DynamicInsert;
|
||||
import org.hibernate.annotations.DynamicUpdate;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "activity_case_file")
|
||||
@IdClass(ActivityCaseFile.ActivityCaseFileId.class)
|
||||
public class ActivityCaseFile extends FileInfo {
|
||||
@Id
|
||||
@Column(name = "case_key")
|
||||
private Integer caseKey;
|
||||
@Id
|
||||
@Column(name = "file_seq")
|
||||
private Integer fileSeq;
|
||||
@Column(name = "orig_nm")
|
||||
private String origNm;
|
||||
@Column(name = "conv_nm")
|
||||
private String convNm;
|
||||
@Column(name = "file_extn")
|
||||
private String fileExtn;
|
||||
@Column(name = "file_size")
|
||||
private String fileSize;
|
||||
@Column(name = "save_path")
|
||||
private String savePath;
|
||||
|
||||
|
||||
@Embeddable
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public static class ActivityCaseFileId implements Serializable {
|
||||
private Integer caseKey;
|
||||
private Integer fileSeq;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.model;
|
||||
|
||||
import com.dbnt.faisp.config.FileInfo;
|
||||
import lombok.*;
|
||||
import org.hibernate.annotations.DynamicInsert;
|
||||
import org.hibernate.annotations.DynamicUpdate;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "activity_case_file")
|
||||
@IdClass(ActivityCaseOfficer.ActivityCaseOfficerId.class)
|
||||
public class ActivityCaseOfficer {
|
||||
@Id
|
||||
@Column(name = "case_key")
|
||||
private Integer caseKey;
|
||||
@Id
|
||||
@Column(name = "officer_seq")
|
||||
private Integer officerSeq;
|
||||
@Column(name = "orig_nm")
|
||||
private String origNm;
|
||||
@Column(name = "conv_nm")
|
||||
private String convNm;
|
||||
@Column(name = "file_extn")
|
||||
private String fileExtn;
|
||||
@Column(name = "file_size")
|
||||
private String fileSize;
|
||||
@Column(name = "save_path")
|
||||
private String savePath;
|
||||
|
||||
|
||||
@Embeddable
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public static class ActivityCaseOfficerId implements Serializable {
|
||||
private Integer caseKey;
|
||||
private Integer officerSeq;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.model;
|
||||
|
||||
import lombok.*;
|
||||
import org.hibernate.annotations.DynamicInsert;
|
||||
import org.hibernate.annotations.DynamicUpdate;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "activity_case_file")
|
||||
@IdClass(ActivityCasePeople.ActivityCasePeopleId.class)
|
||||
public class ActivityCasePeople {
|
||||
@Id
|
||||
@Column(name = "case_key")
|
||||
private Integer caseKey;
|
||||
@Id
|
||||
@Column(name = "people_seq")
|
||||
private Integer peopleSeq;
|
||||
@Column(name = "orig_nm")
|
||||
private String origNm;
|
||||
@Column(name = "conv_nm")
|
||||
private String convNm;
|
||||
@Column(name = "file_extn")
|
||||
private String fileExtn;
|
||||
@Column(name = "file_size")
|
||||
private String fileSize;
|
||||
@Column(name = "save_path")
|
||||
private String savePath;
|
||||
|
||||
|
||||
@Embeddable
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public static class ActivityCasePeopleId implements Serializable {
|
||||
private Integer caseKey;
|
||||
private Integer peopleSeq;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.repository;
|
||||
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCaseFile;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.CiwFile;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
|
||||
public interface ActivityCaseFileRepository extends JpaRepository<ActivityCaseFile, ActivityCaseFile.ActivityCaseFileId> {
|
||||
List<ActivityCaseFile> findByCaseKey(Integer caseKey);
|
||||
Optional<ActivityCaseFile> findTopByCaseKeyOrderByFileSeqDesc(Integer caseKey);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.repository;
|
||||
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCaseOfficer;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
|
||||
public interface ActivityCaseOfficerRepository extends JpaRepository<ActivityCaseOfficer, ActivityCaseOfficer.ActivityCaseOfficerId> {
|
||||
void deleteByCaseKey(Integer caseKey);
|
||||
}
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.repository;
|
||||
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCasePeople;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
|
||||
public interface ActivityCasePeopleRepository extends JpaRepository<ActivityCasePeople, ActivityCasePeople.ActivityCasePeopleId> {
|
||||
|
||||
void deleteByCaseKey(Integer caseKey);
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.repository;
|
||||
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCase;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
|
||||
public interface ActivityCaseRepository extends JpaRepository<ActivityCase, Integer> {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,124 @@
|
|||
package com.dbnt.faisp.main.counterIntelligence.activityCase.service;
|
||||
|
||||
import com.dbnt.faisp.config.BaseService;
|
||||
import com.dbnt.faisp.config.FileInfo;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.mapper.ActivityCaseMapper;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCase;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCaseFile;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCaseOfficer;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.model.ActivityCasePeople;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.repository.ActivityCaseFileRepository;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.repository.ActivityCaseOfficerRepository;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.repository.ActivityCasePeopleRepository;
|
||||
import com.dbnt.faisp.main.counterIntelligence.activityCase.repository.ActivityCaseRepository;
|
||||
import com.dbnt.faisp.main.counterIntelligence.mapper.CounterIntelligenceMapper;
|
||||
import com.dbnt.faisp.main.counterIntelligence.model.*;
|
||||
import com.dbnt.faisp.main.counterIntelligence.repository.*;
|
||||
import com.dbnt.faisp.main.hashTag.service.HashTagService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class ActivityCaseService extends BaseService {
|
||||
private final ActivityCaseRepository activityCaseRepository;
|
||||
private final ActivityCaseFileRepository acfRepository;
|
||||
private final ActivityCasePeopleRepository acpRepository;
|
||||
private final ActivityCaseOfficerRepository acoRepository;
|
||||
private final ActivityCaseMapper activityCaseMapper;
|
||||
|
||||
public List<ActivityCase> selectActivityCaseList(ActivityCase activityCase){
|
||||
return activityCaseMapper.selectActivityCaseList(activityCase);
|
||||
}
|
||||
public Integer selectActivityCaseCnt(ActivityCase activityCase){
|
||||
return activityCaseMapper.selectActivityCaseCnt(activityCase);
|
||||
}
|
||||
public ActivityCase selectActivityCase(Integer caseKey) {
|
||||
ActivityCase activityCase = activityCaseRepository.findById(caseKey).orElse(null);
|
||||
if(activityCase!=null){
|
||||
activityCase.setFileList(acfRepository.findByCaseKey(caseKey));
|
||||
}
|
||||
return activityCase;
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public Integer saveActivityCase(ActivityCase activityCase, List<Integer> deleteFileSeq) {
|
||||
Integer caseKey = activityCaseRepository.save(activityCase).getCaseKey();
|
||||
saveActivityCasePeople(caseKey, activityCase.getPeopleList());
|
||||
saveActivityCaseOfficer(caseKey, activityCase.getOfficerList());
|
||||
if(deleteFileSeq != null && deleteFileSeq.size()>0){
|
||||
deleteActivityCaseFile(caseKey, deleteFileSeq);
|
||||
}
|
||||
if(activityCase.getMultipartFileList()!=null){
|
||||
saveUploadFiles(caseKey, activityCase.getMultipartFileList());
|
||||
}
|
||||
|
||||
return caseKey;
|
||||
}
|
||||
|
||||
private void saveActivityCasePeople(Integer caseKey, List<ActivityCasePeople> peopleList) {
|
||||
if(peopleList==null){
|
||||
acpRepository.deleteByCaseKey(caseKey);
|
||||
}else{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private void saveActivityCaseOfficer(Integer caseKey, List<ActivityCaseOfficer> officerList) {
|
||||
if(officerList==null){
|
||||
acoRepository.deleteByCaseKey(caseKey);
|
||||
}else{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private void deleteActivityCaseFile(Integer caseKey, List<Integer> deleteFileSeq) {
|
||||
List<ActivityCaseFile> activityCaseFileList = acfRepository.findByCaseKey(caseKey);
|
||||
for(ActivityCaseFile file: activityCaseFileList){
|
||||
if(deleteFileSeq.contains(file.getFileSeq())){
|
||||
deleteStoredFile(new File(file.getSavePath(), file.getConvNm()));
|
||||
acfRepository.delete(file);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void saveUploadFiles(Integer caseKey, List<MultipartFile> multipartFileList){
|
||||
ActivityCaseFile lastFileInfo = acfRepository.findTopByCaseKeyOrderByFileSeqDesc(caseKey).orElse(null);
|
||||
int fileSeq = lastFileInfo==null?1:(lastFileInfo.getFileSeq()+1);
|
||||
for(MultipartFile file : multipartFileList){
|
||||
String saveName = UUID.randomUUID().toString();
|
||||
String path = locationPath+activityCasePath;
|
||||
saveFile(file, new File(path+File.separator+saveName));
|
||||
|
||||
String originalFilename = file.getOriginalFilename();
|
||||
int extnIdx = originalFilename.lastIndexOf(".");
|
||||
ActivityCaseFile fileInfo = new ActivityCaseFile();
|
||||
fileInfo.setCaseKey(caseKey);
|
||||
fileInfo.setFileSeq(fileSeq++);
|
||||
fileInfo.setOrigNm(originalFilename.substring(0, extnIdx));
|
||||
fileInfo.setFileExtn(originalFilename.substring(extnIdx+1));
|
||||
fileInfo.setConvNm(saveName);
|
||||
fileInfo.setFileSize(calculationSize(file.getSize()));
|
||||
fileInfo.setSavePath(path);
|
||||
acfRepository.save(fileInfo);
|
||||
}
|
||||
}
|
||||
|
||||
public FileInfo selectActivityCaseFile(Integer caseKey, Integer fileSeq) {
|
||||
return acfRepository.findById(new ActivityCaseFile.ActivityCaseFileId(caseKey, fileSeq)).orElse(null);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public Integer deleteActivityCase(Integer caseKey) {
|
||||
ActivityCase activityCase = activityCaseRepository.findById(caseKey).orElse(null);
|
||||
activityCase.setStatus("DST008");
|
||||
return caseKey;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -25,6 +25,7 @@ file.dir.cia.safty=/cia/safty
|
|||
file.dir.cia.company=/cia/company
|
||||
file.dir.cia.foreigner=/cia/foreigner
|
||||
file.dir.cia.edu=/cia/edu
|
||||
file.dir.activityCase=/activityCase
|
||||
|
||||
editor.img.view=/file/editorFileDisplay?fileNm=
|
||||
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@ file.dir.cia.safty=/cia/safty
|
|||
file.dir.cia.company=/cia/company
|
||||
file.dir.cia.foreigner=/cia/foreigner
|
||||
file.dir.cia.edu=/cia/edu
|
||||
file.dir.activityCase=/activityCase
|
||||
|
||||
editor.img.view=/file/editorFileDisplay?fileNm=
|
||||
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ file.dir.cia.safty=/cia/safty
|
|||
file.dir.cia.company=/cia/company
|
||||
file.dir.cia.foreigner=/cia/foreigner
|
||||
file.dir.cia.edu=/cia/edu
|
||||
file.dir.activityCase=/activityCase
|
||||
|
||||
editor.img.view=/file/editorFileDisplay?fileNm=
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,74 @@
|
|||
<?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.dbnt.faisp.main.counterIntelligence.activityCase.mapper.ActivityCaseMapper">
|
||||
<sql id="selectActivityCaseListWhere">
|
||||
<where>
|
||||
<if test='wrtUserNm != null and wrtUserNm != ""'>
|
||||
and a.wrt_user_nm like '%'||#{wrtUserNm}||'%'
|
||||
</if>
|
||||
<if test='wrtOrgan != null and wrtOrgan != ""'>
|
||||
and a.wrt_organ = #{wrtOrgan}
|
||||
</if>
|
||||
<if test='dateSelector == "receiptDt"'>
|
||||
<if test='startDate != null and startDate != ""'>
|
||||
and a.receipt_dt >= #{startDate}::date
|
||||
</if>
|
||||
<if test='endDate != null and endDate != ""'>
|
||||
and a.receipt_dt <= #{endDate}::date+1
|
||||
</if>
|
||||
</if>
|
||||
<if test='dateSelector == "resultDt"'>
|
||||
<if test='startDate != null and startDate != ""'>
|
||||
and a.result_dt >= #{startDate}::date
|
||||
</if>
|
||||
<if test='endDate != null and endDate != ""'>
|
||||
and a.result_dt <= #{endDate}::date+1
|
||||
</if>
|
||||
</if>
|
||||
<if test='dateSelector == "wrtDt"'>
|
||||
<if test='startDate != null and startDate != ""'>
|
||||
and a.wrt_dt >= #{startDate}::date
|
||||
</if>
|
||||
<if test='endDate != null and endDate != ""'>
|
||||
and a.wrt_dt <= #{endDate}::date+1
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
</sql>
|
||||
<select id="selectActivityCaseList" parameterType="ActivityCase" resultType="ActivityCase">
|
||||
select a.ciw_key,
|
||||
a.status,
|
||||
a.work_rating,
|
||||
a.work_start_date,
|
||||
a.work_end_date,
|
||||
a.re_rating_date1,
|
||||
a.re_rating_date2,
|
||||
a.arrest_type1,
|
||||
a.arrest_type2,
|
||||
a.title,
|
||||
a.wrt_organ,
|
||||
a.wrt_part,
|
||||
a.wrt_user_seq,
|
||||
a.wrt_user_grd,
|
||||
a.wrt_user_nm,
|
||||
a.wrt_dt,
|
||||
b.fileCnt
|
||||
from counter_intelligence_work a
|
||||
left outer join (select ciw_key, count(*) as fileCnt from ciw_file group by ciw_key) b
|
||||
on a.ciw_key = b.ciw_key
|
||||
<include refid="selectActivityCaseListWhere"></include>
|
||||
ORDER BY a.ciw_key DESC
|
||||
LIMIT #{rowCnt} OFFSET #{firstIndex}
|
||||
</select>
|
||||
<select id="selectActivityCaseCnt" parameterType="ActivityCase" resultType="int">
|
||||
select count(*)
|
||||
from counter_intelligence_work a
|
||||
left outer join (select ciw_key, count(*) as fileCnt from ciw_file group by ciw_key) b
|
||||
on a.ciw_key = b.ciw_key
|
||||
<include refid="selectActivityCaseListWhere"></include>
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,167 @@
|
|||
|
||||
$(document).on('click', '#addActivityCaseBtn', function (){
|
||||
getActivityCaseEditModal(null);
|
||||
})
|
||||
|
||||
$(document).on('click', '#saveTempBtn,#saveActivityCaseBtn', function(){
|
||||
saveActivityCase($(this).attr("data-status"));
|
||||
})
|
||||
|
||||
$(document).on('click', '.activityCaseTr', function (){
|
||||
getActivityCaseViewModal($(this).find(".ciwKey").val());
|
||||
})
|
||||
|
||||
$(document).on('click', '#editActivityCaseBtn', function (){
|
||||
$("#activityCaseViewModal").modal('hide');
|
||||
getActivityCaseEditModal($(this).attr("data-casekey"));
|
||||
})
|
||||
|
||||
$(document).on('click', '#deleteActivityCaseBtn', function (){
|
||||
deleteActivityCase($(this).attr("data-casekey"));
|
||||
})
|
||||
|
||||
function getActivityCaseEditModal(caseKey){
|
||||
$.ajax({
|
||||
url: '/counterIntelligence/activityCaseEditModal',
|
||||
data: {caseKey: caseKey},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
success: function(html){
|
||||
$("#activityCaseEditModalContent").empty().append(html)
|
||||
$(".dateSelector").datepicker({
|
||||
format: "yyyy-mm-dd",
|
||||
language: "ko",
|
||||
autoclose: true
|
||||
});
|
||||
setUploadDiv();
|
||||
setEditor('editor', '400');
|
||||
$("#activityCaseEditModal").modal('show');
|
||||
},
|
||||
error:function(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function getActivityCaseViewModal(caseKey){
|
||||
$.ajax({
|
||||
url: '/counterIntelligence/activityCaseViewModal',
|
||||
data: {caseKey: caseKey},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
success: function(html){
|
||||
$("#activityCaseViewModalBody").empty().append(html)
|
||||
$("#activityCaseViewModal").modal('show');
|
||||
},
|
||||
error:function(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function saveActivityCase(status){
|
||||
if(confirm("저장하시겠습니까?")){
|
||||
let flag = true;
|
||||
if(status === "DST007"){
|
||||
flag = contentCheck();
|
||||
}
|
||||
if(flag){
|
||||
contentFade("in");
|
||||
const activityCaseEditForm = $("#activityCaseEditForm");
|
||||
activityCaseEditForm.find("#status").val(status);
|
||||
const formData = new FormData(activityCaseEditForm[0]);
|
||||
for(const file of files) {
|
||||
if(!file.isDelete)
|
||||
formData.append('uploadFiles', file, file.name);
|
||||
}
|
||||
$(".text-decoration-line-through").each(function (idx, el){
|
||||
formData.append('fileSeq', $(el).attr("data-fileseq"));
|
||||
})
|
||||
formData.append('content', CrossEditor.GetBodyValue());
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
url : "/counterIntelligence/saveActivityCase",
|
||||
processData: false,
|
||||
contentType: false,
|
||||
success : function(result) {
|
||||
alert("저장되었습니다.");
|
||||
contentFade("out");
|
||||
$("#activityCaseEditModal").modal('hide');
|
||||
getActivityCaseViewModal(result);
|
||||
},
|
||||
error : function(xhr, status) {
|
||||
alert("저장에 실패하였습니다.")
|
||||
contentFade("out");
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function deleteActivityCase(caseKey){
|
||||
if(confirm("삭제하시겠습니까?")){
|
||||
contentFade("in");
|
||||
const formData = new FormData();
|
||||
formData.append('caseKey', caseKey);
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
url : "/counterIntelligence/deleteActivityCase",
|
||||
processData: false,
|
||||
contentType: false,
|
||||
beforeSend: function (xhr){
|
||||
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
|
||||
},
|
||||
success : function(result) {
|
||||
alert("삭제되었습니다.");
|
||||
contentFade("out");
|
||||
location.reload();
|
||||
},
|
||||
error : function(xhr, status) {
|
||||
alert("삭제를 실패하였습니다.")
|
||||
contentFade("out");
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
function contentCheck(){
|
||||
if(!$("#workStartDate").val()){
|
||||
alert("착수일을 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#workEndDate").val()){
|
||||
alert("종결일을 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#reRatingDate1").val()){
|
||||
alert("1차재평가를 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#reRatingDate2").val()){
|
||||
alert("2차재평가를 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#workRating").val()){
|
||||
alert("등급을 선택해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#arrestType1").val()){
|
||||
alert("검거유형1을 선택해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#arrestType2").val()){
|
||||
alert("검거유형2를 선택해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#title").val()){
|
||||
alert("공작명을 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
if(!$("#summaryInfo").val()){
|
||||
alert("사건개요를 입력해주세요.")
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
@ -0,0 +1,232 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="ko" xmlns:th="http://www.thymeleaf.org"
|
||||
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
||||
layout:decorate="~{layout/layout}">
|
||||
<th:block layout:fragment="script">
|
||||
<script type="text/javascript" th:src="@{/js/counterIntelligence/activityCase.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main>
|
||||
<div class="row justify-content-between">
|
||||
<div class="col-auto">
|
||||
<h4>담당 사건 목록</h4>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<p class="mb-0 mt-2">외사방첩관리 > 외사활동 > 담당 사건 목록</p>
|
||||
</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="row mx-0">
|
||||
<div class="col-12 card bg-light text-center">
|
||||
<div class="card-body">
|
||||
<form method="get" th:action="${searchUrl}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
<div class="row justify-content-between py-1">
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="rowCnt" id="rowCnt">
|
||||
<th:block th:each="num : ${#numbers.sequence(1,5)}">
|
||||
<option th:value="${num*10}" th:text="${num*10}" th:selected="${searchParams.rowCnt eq num*10}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-8">
|
||||
<div class="row">
|
||||
<div class="col-11">
|
||||
<div class="row justify-content-end pb-1">
|
||||
<!--<div class="col-2" th:if="${accessAuth eq 'ACC003'}">
|
||||
<select class="form-select form-select-sm" name="wrtOrgan">
|
||||
<option value="">관서 선택</option>
|
||||
<th:block th:each="code:${session.commonCode.get('OG')}">
|
||||
<th:block th:if="${#lists.contains(downOrganCdList, code.itemCd)}">
|
||||
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.wrtOrgan}"></option>
|
||||
</th:block>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<select class="form-select form-select-sm" name="workRating">
|
||||
<option value="">등급</option>
|
||||
<th:block th:each="code:${session.commonCode.get('CIWR')}">
|
||||
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.workRating}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<select class="form-select form-select-sm" name="arrestType1">
|
||||
<option value="">검거유형1</option>
|
||||
<th:block th:each="code:${session.commonCode.get('AT')}">
|
||||
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.arrestType1}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<select class="form-select form-select-sm" name="arrestType2">
|
||||
<option value="">검거유형2</option>
|
||||
<th:block th:each="code:${session.commonCode.get(arrestType1)}">
|
||||
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.arrestType2}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>-->
|
||||
<div class="col-2">
|
||||
<input type="text" class="form-control form-control-sm" placeholder="제목" name="title">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row justify-content-end">
|
||||
<div class="col-2">
|
||||
<input type="text" class="form-control form-control-sm" placeholder="작성자" name="wrtUserNm" th:value="${searchParams.wrtUserNm}">
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<div class="input-group input-daterange" id="dateSelectorDiv">
|
||||
<select class="form-select form-select-sm w-30" name="dateSelector">
|
||||
<option value="wrtDt" th:selected="${searchParams.dateSelector eq 'wrtDt'}">작성일</option>
|
||||
<option value="workStartDate" th:selected="${searchParams.dateSelector eq 'receiptDt'}">접수일</option>
|
||||
<option value="workEndDate" th:selected="${searchParams.dateSelector eq 'resultDt'}">종결일</option>
|
||||
</select>
|
||||
<input type="text" class="form-control form-control-sm w-35" id="startDate" name="startDate" placeholder="시작일" autocomplete="off" readonly th:value="${searchParams.startDate}">
|
||||
<input type="text" class="form-control form-control-sm w-35" id="endDate" name="endDate" placeholder="종료일" autocomplete="off" readonly th:value="${searchParams.endDate}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-1 d-grid gap-2">
|
||||
<input type="submit" class="btn btn-sm btn-primary" id="searchBtn" value="검색">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-12 overflow-auto">
|
||||
<table class="table table-sm table-bordered table-hover">
|
||||
<thead>
|
||||
<tr class="table-secondary">
|
||||
<th>순번</th>
|
||||
<th>첨부파일</th>
|
||||
<th>경과</th>
|
||||
<th>구분</th>
|
||||
<th>병합</th>
|
||||
<th>접수번호</th>
|
||||
<th>사건번호</th>
|
||||
<th>접수단서</th>
|
||||
<th>피(혐)의자</th>
|
||||
<th>죄명</th>
|
||||
<th>피해자</th>
|
||||
<th>진행상태</th>
|
||||
<th>지휘서/메모</th>
|
||||
<th>종결번호</th>
|
||||
<th>결정</th>
|
||||
<th>요구/요청</th>
|
||||
<th>이의</th>
|
||||
<th>자체재개</th>
|
||||
<th>메모</th>
|
||||
<th>정수사관</th>
|
||||
<th>부수사관</th>
|
||||
<th>주책임관</th>
|
||||
<th>비고</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider">
|
||||
<!--<tr class="activityCaseTr" th:each="ciWork:${activityCaseList}">
|
||||
<input type="hidden" class="ciwKey" th:value="${ciWork.ciwKey}">
|
||||
<td>
|
||||
<th:block th:each="code:${session.commonCode.get('CIWR')}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.workRating}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</td>
|
||||
<td>
|
||||
<th:block th:each="code:${session.commonCode.get('AT')}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.arrestType1}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</td>
|
||||
<td>
|
||||
<th:block th:each="code:${session.commonCode.get(ciWork.arrestType1)}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.arrestType2}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</td>
|
||||
<td>
|
||||
<th:block th:if="${ciWork.status eq 'DST002'}">[임시]</th:block>
|
||||
<th:block th:text="${ciWork.title}"></th:block>
|
||||
</td>
|
||||
<td>
|
||||
<div th:text="${ciWork.workStartDate}"></div>
|
||||
<div th:text="${#strings.concat('~ ', ciWork.workEndDate)}"></div>
|
||||
</td>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OG')}">
|
||||
<td th:if="${ciWork.wrtOrgan eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
|
||||
</th:block>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OFC')}">
|
||||
<td th:if="${ciWork.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
|
||||
</th:block>
|
||||
<td>
|
||||
<th:block th:each="code:${session.commonCode.get('JT')}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.wrtUserGrd}" th:text="|${code.itemValue} ${ciWork.wrtUserNm}|"></th:block>
|
||||
</th:block>
|
||||
</td>
|
||||
<td th:text="${#temporals.format(ciWork.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
|
||||
<td th:text="${ciWork.fileCnt eq null?'파일 없음':#strings.concat(ciWork.fileCnt,' 건')}"></td>
|
||||
<td>
|
||||
<div th:text="|1차: ${ciWork.reRatingDate1}|"></div>
|
||||
<div th:text="|2차: ${ciWork.reRatingDate2}|"></div>
|
||||
</td>
|
||||
</tr>-->
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row justify-content-between">
|
||||
<div class="col-auto"></div>
|
||||
<div class="col-auto">
|
||||
<nav aria-label="Page navigation">
|
||||
<ul class="pagination mb-0">
|
||||
<th:block th:if="${searchParams.pageIndex>3}">
|
||||
<li class="page-item" th:data-pageindex="${(searchParams.pageIndex)-3}">
|
||||
<a class="page-link" href="#" aria-label="Previous">
|
||||
<span aria-hidden="true">«</span>
|
||||
</a>
|
||||
</li>
|
||||
</th:block>
|
||||
<th:block th:each="num : ${#numbers.sequence(searchParams.startNum, searchParams.endNum)}">
|
||||
<li class="page-item" th:data-pageindex="${num}" th:classappend="${searchParams.pageIndex eq num?'active':''}">
|
||||
<a class="page-link" href="#" th:text="${num}"></a>
|
||||
</li>
|
||||
</th:block>
|
||||
<th:block th:if="${searchParams.maxNum>searchParams.endNum+2}">
|
||||
<li class="page-item" th:data-pageindex="${(searchParams.pageIndex)+3}">
|
||||
<a class="page-link" href="#" aria-label="Next">
|
||||
<span aria-hidden="true">»</span>
|
||||
</a>
|
||||
</li>
|
||||
</th:block>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="button" class="btn btn-success" value="등록" id="addActivityCaseBtn" th:unless="${accessAuth eq 'ACC001'}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<div class="modal fade" id="activityCaseEditModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="activityCaseModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog modal-xl modal-dialog-scrollable">
|
||||
<div class="modal-content" id="activityCaseEditModalContent">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade" id="activityCaseViewModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="activityCaseModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog modal-xl modal-dialog-scrollable">
|
||||
<div class="modal-content" id="activityCaseViewModalBody">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,107 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
|
||||
<div class="modal-header bg-dark">
|
||||
<h5 class="modal-title text-white" id="activityCaseEditModalLabel" th:text="${activityCase.caseKey eq null?'사건 등록':'사건 수정'}"></h5>
|
||||
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body" id="activityCaseEditBody">
|
||||
<form action="#" method="post" id="activityCaseEditForm">
|
||||
<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="caseKey" th:value="${activityCase.caseKey}">
|
||||
<input type="hidden" name="wrtOrgan" th:value="${activityCase.wrtOrgan}">
|
||||
<input type="hidden" name="wrtPart" th:value="${activityCase.wrtPart}">
|
||||
<input type="hidden" name="wrtUserSeq" th:value="${activityCase.wrtUserSeq}">
|
||||
<input type="hidden" name="wrtUserGrd" th:value="${activityCase.wrtUserGrd}">
|
||||
<input type="hidden" name="wrtUserNm" th:value="${activityCase.wrtUserNm}">
|
||||
<input type="hidden" name="status" id="status" th:value="${activityCase.status}">
|
||||
<div class="row mb-1">
|
||||
<label for="wrtUserNm" class="col-sm-1 col-form-label col-form-label-sm text-center">작성자</label>
|
||||
<div class="col-sm-2">
|
||||
<th:block th:if="${activityCase.wrtUserGrd eq null}">
|
||||
<input type="text" class="form-control form-control-sm" id="wrtUserNm" th:value="${activityCase.wrtUserNm}" readonly>
|
||||
</th:block>
|
||||
<th:block th:unless="${activityCase.wrtUserGrd eq null}">
|
||||
<th:block th:each="code:${session.commonCode.get('JT')}">
|
||||
<th:block th:if="${code.itemCd eq activityCase.wrtUserGrd}">
|
||||
<input type="text" class="form-control form-control-sm" id="wrtUserNm" th:value="|${code.itemValue} ${activityCase.wrtUserNm}|" readonly>
|
||||
</th:block>
|
||||
</th:block>
|
||||
</th:block>
|
||||
</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="wrtDt" name="wrtDt" th:value="${#temporals.format(activityCase.wrtDt, 'yyyy-MM-dd HH:mm')}" readonly>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label for="receiptNum" 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="receiptNum" name="receiptNum" th:value="${activityCase.receiptNum}">
|
||||
</div>
|
||||
<label for="receiptNum" 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="receiptNum" name="receiptNum" th:value="${activityCase.receiptNum}">
|
||||
</div>
|
||||
<label for="receiptNum" 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="receiptNum" name="receiptNum" th:value="${activityCase.receiptNum}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label for="receiptNum" 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="receiptNum" name="receiptNum" th:value="${activityCase.receiptNum}">
|
||||
</div>
|
||||
<label for="receiptNum" 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="receiptNum" name="receiptNum" th:value="${activityCase.receiptNum}">
|
||||
</div>
|
||||
<label for="resultNum" 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="resultNum" name="resultNum" th:value="${activityCase.resultNum}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label for="receiptDt" 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 dateSelector" id="receiptDt" name="receiptDt" th:value="${#temporals.format(activityCase.receiptDt, 'yyyy-MM-dd')}" readonly>
|
||||
</div>
|
||||
<label for="resultDt" 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 dateSelector" id="resultDt" name="resultDt" th:value="${#temporals.format(activityCase.resultDt, 'yyyy-MM-dd')}" readonly>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-1 justify-content-center">
|
||||
<label for="summaryInfo" class="col-sm-1 col-form-label col-form-label-sm text-center">사건개요</label>
|
||||
<div class="col-sm-11">
|
||||
<textarea class="form-control form-control-sm" id="summaryInfo" name="summaryInfo"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-3">
|
||||
<label for="fileInputer" class="col-sm-1 col-form-label col-form-label-sm text-center">첨부파일</label>
|
||||
<div class="col-sm-11" style="min-height: 70px;">
|
||||
<div class="w-100 h-100 border border-info rounded text-center" id="uploadDiv">
|
||||
<th:block th:if="${#arrays.isEmpty(activityCase.fileList)}">
|
||||
<br>클릭 & 드레그로 파일을 업로드 해주세요.
|
||||
</th:block>
|
||||
<th:block th:unless="${#arrays.isEmpty(activityCase.fileList)}">
|
||||
<div class='row-col-6' th:each="file:${activityCase.fileList}">
|
||||
<span th:data-fileseq="${file.fileSeq}" th:text="|${file.origNm}.${file.fileExtn} ${file.fileSize}|"></span>
|
||||
<a href='#' class='uploadedFileDelete text-danger text-decoration-none'>삭제</a>
|
||||
</div>
|
||||
</th:block>
|
||||
</div>
|
||||
</div>
|
||||
<input type="file" class="d-none" id="fileInputer" multiple>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<th:block th:if="${activityCase.caseKey ne null and accessAuth eq 'ACC003'}">
|
||||
<button type="button" class="btn btn-danger" id="deleteActivityCaseBtn" th:data-casekey="${activityCase.caseKey}">삭제</button>
|
||||
</th:block>
|
||||
<button type="button" class="btn btn-warning" id="saveTempBtn" data-status="DST002">임시저장</button>
|
||||
<button type="button" class="btn btn-primary" id="saveActivityCaseBtn" data-status="DST007">저장</button>
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
|
||||
</div>
|
||||
|
|
@ -0,0 +1,118 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
|
||||
<div class="modal-header bg-dark">
|
||||
<h5 class="modal-title text-white" id="ciWorkViewModalLabel">방첩공작 열람</h5>
|
||||
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body" id="ciWorkViewBody">
|
||||
<input type="hidden" id="ciwKey" th:value="${ciWork.ciwKey}">
|
||||
<ul class="nav nav-tabs" id="userTab" role="tablist">
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link active" id="boardTab" data-bs-toggle="tab" data-bs-target="#boardTabPanel" type="button" role="tab" aria-controls="boardTabPanel" aria-selected="true">본문</button>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation" th:if="${#lists.size(ciWork.fileList)>0}">
|
||||
<button class="nav-link" id="fileTab" data-bs-toggle="tab" data-bs-target="#fileTabPanel" type="button" role="tab" aria-controls="fileTabPanel" aria-selected="false" th:text="${#strings.concat('첨부파일(', #lists.size(ciWork.fileList), ')')}"></button>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="tab-content bg-white border border-top-0 p-2">
|
||||
<div class="tab-pane fade p-2 show active" id="boardTabPanel" role="tabpanel" tabindex="0">
|
||||
<div class="row mb-1">
|
||||
<div class="col-sm-9"></div>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">작성일시</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(ciWork.wrtDt, 'yyyy-MM-dd HH:mm')}"></label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">공작명</label>
|
||||
<label class="col-sm-8 col-form-label col-form-label-sm text-start" th:text="|${ciWork.status eq 'DST002'?'[임시] ':''}${ciWork.title}|"></label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">작성자</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${ciWork.wrtUserNm}"></label>
|
||||
</div>
|
||||
<hr class="my-1">
|
||||
<div class="row mb-1">
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">착수일</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(ciWork.workStartDate, 'yyyy-MM-dd')}"></label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">종결일(예정)</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(ciWork.workEndDate, 'yyyy-MM-dd')}"></label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">1차재평가</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(ciWork.reRatingDate1, 'yyyy-MM-dd')}"></label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">2차재평가</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(ciWork.reRatingDate2, 'yyyy-MM-dd')}"></label>
|
||||
</div>
|
||||
<div class="row mb-1">
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">등급</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
|
||||
<th:block th:each="code:${session.commonCode.get('CIWR')}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.workRating}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">검거유형1</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
|
||||
<th:block th:each="code:${session.commonCode.get('AT')}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.arrestType1}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</label>
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">검거유형2</label>
|
||||
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
|
||||
<th:block th:each="code:${session.commonCode.get(ciWork.arrestType1)}">
|
||||
<th:block th:if="${code.itemCd eq ciWork.arrestType2}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</label>
|
||||
</div>
|
||||
<hr class="my-1">
|
||||
<div class="row mb-1">
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">사건개요</label>
|
||||
<div class="col-sm-11 form-control-sm" th:utext="${#strings.replace(ciWork.summaryInfo, lineSeparator, '<br>')}"></div>
|
||||
</div>
|
||||
<hr class="my-1">
|
||||
<div class="row mb-1">
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">내용</label>
|
||||
<div class="col-sm-11 form-control-sm" th:utext="${ciWork.content}"></div>
|
||||
</div>
|
||||
<hr class="my-1">
|
||||
<div class="row mb-1">
|
||||
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold">해시태그</label>
|
||||
<label class="col-sm-11 col-form-label col-form-label-sm text-start" th:text="${ciWork.hashTags}"></label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tab-pane fade p-2" id="fileTabPanel" role="tabpanel" tabindex="0">
|
||||
<div class="row mb-3">
|
||||
<div class="col-sm-12">
|
||||
<table class="table table-sm" id="fileTable">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>파일명</th>
|
||||
<th>사이즈</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<th:block th:if="${#lists.isEmpty(ciWork.fileList)}">
|
||||
<tr>
|
||||
<td colspan="2">파일이 없습니다.</td>
|
||||
</tr>
|
||||
</th:block>
|
||||
<th:block th:unless="${#lists.isEmpty(ciWork.fileList)}">
|
||||
<th:block th:each="file:${ciWork.fileList}">
|
||||
<tr class="fileInfoTr">
|
||||
<td>
|
||||
<a href="#" class="fileDownLink" data-board="ciWork"
|
||||
th:data-parentkey="${file.ciwKey}" th:data-fileseq="${file.fileSeq}"
|
||||
th:text="|${file.origNm}.${file.fileExtn}|"></a>
|
||||
</td>
|
||||
<td th:text="${file.fileSize}"></td>
|
||||
</tr>
|
||||
</th:block>
|
||||
</th:block>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-light">
|
||||
<th:block th:if="${accessAuth eq 'ACC003'}">
|
||||
<button type="button" class="btn btn-danger" id="deleteCiWorkBtn" th:data-ciwkey="${ciWork.ciwKey}">삭제</button>
|
||||
</th:block>
|
||||
<th:block th:if="${viewUserSeq eq ciWork.wrtUserSeq}">
|
||||
<button type="button" class="btn btn-warning" id="editCiWorkBtn" th:data-ciwkey="${ciWork.ciwKey}">수정</button>
|
||||
</th:block>
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
|
||||
</div>
|
||||
Loading…
Reference in New Issue