사용자로그 작업중.
parent
977584c15e
commit
9696cac273
|
|
@ -1,5 +1,6 @@
|
|||
package com.dbnt.faisp.config;
|
||||
|
||||
import com.dbnt.faisp.main.codeMgt.model.CodeMgt;
|
||||
import com.dbnt.faisp.main.menuMgt.service.MenuMgtService;
|
||||
import com.dbnt.faisp.main.organMgt.service.OrganConfigService;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
|
|
@ -13,6 +14,8 @@ import org.springframework.web.bind.annotation.RestController;
|
|||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import javax.servlet.http.HttpSession;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
|
|
@ -71,6 +74,25 @@ public class BaseController {
|
|||
loginUser.setDownOrganCdList(organConfigService.selectDownOrganListWhereUserOgCd(loginUser.getOgCd()));
|
||||
loginUser.setUpOrganCdList(organConfigService.selectUpOrganListWhereUserOgCd(loginUser.getOgCd()));
|
||||
session.setAttribute("menuList", menuMgtService.selectAccessMenuListWhereUserSeq(loginUser.getUserSeq()));
|
||||
session.setAttribute("commonCode", codeMgtService.getCommonCode());
|
||||
Map<String, List<CodeMgt>> codeMap = codeMgtService.getCommonCode();
|
||||
session.setAttribute("commonCode", codeMap);
|
||||
String belongValue = "";
|
||||
belongValue += searchCodeValue(loginUser.getOgCd(), codeMap.get("OG"));
|
||||
belongValue += searchCodeValue(loginUser.getOfcCd(), codeMap.get("OFC"));
|
||||
belongValue += searchCodeValue(loginUser.getTitleCd(), codeMap.get("JT"));
|
||||
belongValue += loginUser.getUserNm()+"("+loginUser.getUserId()+")";
|
||||
session.setAttribute("belongValue", belongValue);
|
||||
}
|
||||
private String searchCodeValue(String itemCd, List<CodeMgt> codeList){
|
||||
if(itemCd==null){
|
||||
return "";
|
||||
}else{
|
||||
for(CodeMgt code: codeList){
|
||||
if(itemCd.equals(code.getItemCd())){
|
||||
return code.getItemValue()+" ";
|
||||
}
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,27 +1,42 @@
|
|||
package com.dbnt.faisp.config;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserRequestLog;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserInfoService;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserLogService;
|
||||
import com.dbnt.faisp.util.Utils;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.method.HandlerMethod;
|
||||
import org.springframework.web.servlet.HandlerInterceptor;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
@Component
|
||||
@RequiredArgsConstructor
|
||||
public class FaispInterceptor implements HandlerInterceptor {
|
||||
|
||||
private Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
private final UserLogService userLogService;
|
||||
|
||||
@Override
|
||||
public boolean preHandle(
|
||||
public void afterCompletion(
|
||||
HttpServletRequest request,
|
||||
HttpServletResponse response,
|
||||
Object handler
|
||||
Object handler,
|
||||
Exception ex
|
||||
) throws Exception {
|
||||
System.out.println(request.getUserPrincipal());
|
||||
System.out.println(request.getRequestURI());
|
||||
|
||||
return true;
|
||||
//페이지 렌더링 후 실행.
|
||||
UserRequestLog log = new UserRequestLog();
|
||||
log.setContactIp(Utils.getClientIP(request));
|
||||
log.setRequestUrl(request.getRequestURI());
|
||||
log.setRequestMethod(request.getMethod());
|
||||
log.setSearchParams(request.getQueryString());
|
||||
log.setHandlerDescription(((HandlerMethod) handler).toString());
|
||||
log.setUserBelong((String) request.getSession().getAttribute("belongValue"));
|
||||
userLogService.saveRequestLog(log);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,28 +0,0 @@
|
|||
package com.dbnt.faisp.config;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
@AllArgsConstructor
|
||||
@Getter
|
||||
public enum LogStatus {
|
||||
WRITE("작성"),
|
||||
MODIFY("수정"),
|
||||
MOVE("이동"),
|
||||
DELETE("삭제"),
|
||||
FILE_ADD("파일추가"),
|
||||
FILE_REMOVE("파일삭제"),
|
||||
FILE_DOWN("파일다운로드");
|
||||
|
||||
private String value;
|
||||
|
||||
public static HashMap<String, String> getStatusMap(){
|
||||
HashMap<String, String> statusMap = new HashMap<>();
|
||||
for(LogStatus status: LogStatus.values()){
|
||||
statusMap.put(status.name(), status.getValue());
|
||||
}
|
||||
return statusMap;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,6 +1,9 @@
|
|||
package com.dbnt.faisp.config;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInoutLog;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserLogService;
|
||||
import com.dbnt.faisp.util.Utils;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
|
@ -14,7 +17,9 @@ import org.springframework.security.web.AuthenticationEntryPoint;
|
|||
import org.springframework.security.web.DefaultRedirectStrategy;
|
||||
import org.springframework.security.web.SecurityFilterChain;
|
||||
import org.springframework.security.web.access.AccessDeniedHandler;
|
||||
import org.springframework.security.web.authentication.AuthenticationFailureHandler;
|
||||
import org.springframework.security.web.authentication.AuthenticationSuccessHandler;
|
||||
import org.springframework.security.web.authentication.logout.LogoutSuccessHandler;
|
||||
import org.springframework.security.web.savedrequest.HttpSessionRequestCache;
|
||||
import org.springframework.security.web.savedrequest.SavedRequest;
|
||||
import org.springframework.security.web.util.matcher.AntPathRequestMatcher;
|
||||
|
|
@ -27,6 +32,7 @@ import javax.servlet.http.HttpServletResponse;
|
|||
public class SecurityConfig{
|
||||
private final Logger log = LoggerFactory.getLogger(getClass());
|
||||
private final BaseController baseController;
|
||||
private final UserLogService userLogService;
|
||||
|
||||
@Bean
|
||||
public PasswordEncoder passwordEncoder(){
|
||||
|
|
@ -61,6 +67,14 @@ public class SecurityConfig{
|
|||
return (request, response, authentication) -> {
|
||||
SavedRequest savedRequest = new HttpSessionRequestCache().getRequest(request,response);
|
||||
baseController.setSession((UserInfo)authentication.getPrincipal(), request.getSession());
|
||||
|
||||
UserInoutLog inoutLog = new UserInoutLog();
|
||||
inoutLog.setInoutType("IOT001");
|
||||
inoutLog.setContactIp(Utils.getClientIP(request));
|
||||
inoutLog.setSessionId(request.getSession().getId());
|
||||
inoutLog.setUserBelong((String) request.getSession().getAttribute("belongValue"));
|
||||
userLogService.saveInoutLog(inoutLog);
|
||||
|
||||
if(savedRequest != null){
|
||||
String targetUrl = savedRequest.getRedirectUrl();
|
||||
new DefaultRedirectStrategy().sendRedirect(request,response,targetUrl);
|
||||
|
|
@ -69,6 +83,30 @@ public class SecurityConfig{
|
|||
}
|
||||
};
|
||||
}
|
||||
@Bean
|
||||
public AuthenticationFailureHandler loginFailureHandler(){
|
||||
return (request, response, exception) -> {
|
||||
UserInoutLog inoutLog = new UserInoutLog();
|
||||
inoutLog.setInoutType("IOT002");
|
||||
inoutLog.setContactIp(Utils.getClientIP(request));
|
||||
userLogService.saveInoutLog(inoutLog);
|
||||
|
||||
new DefaultRedirectStrategy().sendRedirect(request, response, "/login-error");
|
||||
};
|
||||
}
|
||||
@Bean
|
||||
public LogoutSuccessHandler logoutSuccessHandler(){
|
||||
return (request, response, authentication) -> {
|
||||
UserInoutLog inoutLog = new UserInoutLog();
|
||||
inoutLog.setInoutType("IOT003");
|
||||
inoutLog.setContactIp(Utils.getClientIP(request));
|
||||
inoutLog.setSessionId(request.getSession().getId());
|
||||
inoutLog.setUserBelong((String) request.getSession().getAttribute("belongValue"));
|
||||
userLogService.saveInoutLog(inoutLog);
|
||||
|
||||
new DefaultRedirectStrategy().sendRedirect(request, response, "/");
|
||||
};
|
||||
}
|
||||
|
||||
@Bean
|
||||
protected SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
|
||||
|
|
@ -88,7 +126,7 @@ public class SecurityConfig{
|
|||
"/affairResult/**",
|
||||
"/faStatistics/**",
|
||||
"/translator/**",
|
||||
"/faisp/**",
|
||||
"/police/**",
|
||||
"/sri/**"
|
||||
).hasRole(Role.USER.name()) // USER 접근 허용
|
||||
.antMatchers(
|
||||
|
|
@ -110,15 +148,11 @@ public class SecurityConfig{
|
|||
).permitAll() // 로그인 페이지는 권한 없이 접근 허용
|
||||
.and() // 로그인 설정
|
||||
.formLogin().loginPage("/login") // Custom login form 사용
|
||||
.failureUrl("/login-error") // 로그인 실패 시 이동
|
||||
.defaultSuccessUrl("/") // 로그인 성공 시 이동
|
||||
/*.failureHandler((request, response, exception) -> {
|
||||
|
||||
})*/ // 로그인 실패시 동작 수행
|
||||
.failureHandler(loginFailureHandler()) // 로그인 실패시 동작 수행
|
||||
.successHandler(loginSuccessHandler()) // 로그인 성공시 동작 수행.
|
||||
.and() // 로그아웃 설정
|
||||
.logout().logoutRequestMatcher(new AntPathRequestMatcher("/logout")) // 로그아웃 시 URL 재정의
|
||||
.logoutSuccessUrl("/") // 로그아웃 성공 시 redirect 이동
|
||||
.logoutSuccessHandler(logoutSuccessHandler()) // 로그아웃 성공시 동작 수행.
|
||||
.invalidateHttpSession(true) // HTTP Session 초기화
|
||||
.deleteCookies("JSESSIONID") // 특정 쿠키 제거
|
||||
.and() // 403 예외처리 핸들링
|
||||
|
|
|
|||
|
|
@ -1,17 +1,24 @@
|
|||
package com.dbnt.faisp.config;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
|
||||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
||||
|
||||
@Configuration
|
||||
@RequiredArgsConstructor
|
||||
public class WebMvcConfig implements WebMvcConfigurer {
|
||||
|
||||
private final FaispInterceptor faispInterceptor;
|
||||
@Override
|
||||
public void addInterceptors(InterceptorRegistry registry) {
|
||||
registry.addInterceptor(new FaispInterceptor())
|
||||
|
||||
registry.addInterceptor(faispInterceptor)
|
||||
.addPathPatterns("/**")
|
||||
.excludePathPatterns(
|
||||
"/",
|
||||
"/favicon.ico",
|
||||
"/editorFileDisplay",
|
||||
"/fileDisplay",
|
||||
"/css/**",
|
||||
"/img/**",
|
||||
"/js/**",
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ public class CrackdownStatus extends CrackdownStatusBaseEntity {
|
|||
@Transient
|
||||
private String boatNnySi;
|
||||
@Transient
|
||||
private Integer tonCnt;
|
||||
private Double tonCnt;
|
||||
@Transient
|
||||
private String boat_material;
|
||||
@Transient
|
||||
|
|
|
|||
|
|
@ -3,23 +3,17 @@ package com.dbnt.faisp.main.userInfo;
|
|||
|
||||
import com.dbnt.faisp.kwms.service.KwmsService;
|
||||
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.fipTarget.model.PartInfo;
|
||||
import com.dbnt.faisp.main.fipTarget.model.ShipInfo;
|
||||
import com.dbnt.faisp.main.userInfo.model.*;
|
||||
import com.dbnt.faisp.main.userInfo.service.PoliceService;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserInfoService;
|
||||
import com.dbnt.faisp.util.ParamMap;
|
||||
import com.dbnt.faisp.util.Utils;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.Collections;
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
|
|
@ -29,18 +23,19 @@ import org.springframework.web.servlet.ModelAndView;
|
|||
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@RequestMapping("/faisp")
|
||||
public class FaispController {
|
||||
@RequestMapping("/police")
|
||||
public class PoliceController {
|
||||
|
||||
private final AuthMgtService authMgtService;
|
||||
private final CodeMgtService codeMgtService;
|
||||
private final UserInfoService userInfoService;
|
||||
private final PoliceService policeService;
|
||||
private final KwmsService kwmsService;
|
||||
|
||||
|
||||
@GetMapping("/policeList")
|
||||
public ModelAndView policeList(@AuthenticationPrincipal UserInfo loginUser, UserInfo userInfo, HttpServletResponse response) {
|
||||
ModelAndView mav = new ModelAndView("faisp/police/policeList");
|
||||
ModelAndView mav = new ModelAndView("police/police/policeList");
|
||||
userInfo.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
if(userInfo.getUserStatus() == null) {
|
||||
userInfo.setUserStatus("USC003");
|
||||
|
|
@ -75,7 +70,7 @@ public class FaispController {
|
|||
}
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/policeList").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/policeList").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
userInfo.setQueryInfo();
|
||||
mav.addObject("policeList", userInfoService.selectPoliceList(userInfo));
|
||||
|
|
@ -89,7 +84,7 @@ public class FaispController {
|
|||
|
||||
@GetMapping("/policeEditModal")
|
||||
public ModelAndView policeEditModal(@AuthenticationPrincipal UserInfo loginUser,UserInfo userInfo){
|
||||
ModelAndView mav = new ModelAndView("/faisp/police/policeEditModal");
|
||||
ModelAndView mav = new ModelAndView("police/police/policeEditModal");
|
||||
mav.addObject("ogList", codeMgtService.selectCodeMgtList("OG", ""));
|
||||
mav.addObject("ofcList", codeMgtService.selectCodeMgtList("OFC", ""));
|
||||
mav.addObject("titleList", codeMgtService.selectCodeMgtList("JT", ""));
|
||||
|
|
@ -99,7 +94,7 @@ public class FaispController {
|
|||
mav.addObject("statusList", codeMgtService.selectCodeMgtList("USC", ""));
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/policeList").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/policeList").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
mav.addObject("userInfo", userInfoService.selectUserInfo(userInfo.getUserSeq()));
|
||||
return mav;
|
||||
|
|
@ -113,8 +108,8 @@ public class FaispController {
|
|||
|
||||
@GetMapping("/policeHistory")
|
||||
public ModelAndView policeHistory(@AuthenticationPrincipal UserInfo loginUser,UserInfoHistory userInfoHistory){
|
||||
ModelAndView mav = new ModelAndView("/faisp/police/policeHistory");
|
||||
mav.addObject("userStatus", userInfoService.selectuserStatus(userInfoHistory));
|
||||
ModelAndView mav = new ModelAndView("police/police/policeHistory");
|
||||
mav.addObject("userStatus", userInfoService.selectUserStatus(userInfoHistory));
|
||||
mav.addObject("policeList", userInfoService.selectPoliceHisList(userInfoHistory));
|
||||
|
||||
return mav;
|
||||
|
|
@ -123,7 +118,7 @@ public class FaispController {
|
|||
@GetMapping("/policeHistoryView")
|
||||
@ResponseBody
|
||||
public UserInfoHistory policeHistoryView(UserInfoHistory userInfoHistory){
|
||||
return userInfoService.selectpoliceHistoryView(userInfoHistory);
|
||||
return userInfoService.selectPoliceHistoryView(userInfoHistory);
|
||||
}
|
||||
|
||||
@PostMapping("/policeStatusUpdate")
|
||||
|
|
@ -151,9 +146,9 @@ public class FaispController {
|
|||
|
||||
@GetMapping("/personnelStatus")
|
||||
public ModelAndView personnelStatus(@AuthenticationPrincipal UserInfo loginUser, PersonnelStatus personnelStatus){
|
||||
ModelAndView mav = new ModelAndView("faisp/personnelStatus/personnelStatus");
|
||||
ModelAndView mav = new ModelAndView("police/personnelStatus/personnelStatus");
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/personnelStatus").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/personnelStatus").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
|
||||
if(personnelStatus.getYear()==null){
|
||||
|
|
@ -162,7 +157,7 @@ public class FaispController {
|
|||
personnelStatus.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
mav.addObject("searchParams", personnelStatus);
|
||||
mav.addObject("jtList", codeMgtService.selectCodeMgtList("JT", "reverse"));
|
||||
List<PersonnelStatus> statusList = userInfoService.selectPersonnelStatusList(personnelStatus);
|
||||
List<PersonnelStatus> statusList = policeService.selectPersonnelStatusList(personnelStatus);
|
||||
statusList = calcStatusList(statusList);
|
||||
mav.addObject("statusSummary", makeStatusSummary(statusList));
|
||||
mav.addObject("statusList", statusList);
|
||||
|
|
@ -171,42 +166,42 @@ public class FaispController {
|
|||
|
||||
@GetMapping("/personnelStatusRow")
|
||||
public ModelAndView personnelStatusRow(@AuthenticationPrincipal UserInfo loginUser){
|
||||
ModelAndView mav = new ModelAndView("faisp/personnelStatus/personnelStatusRow");
|
||||
ModelAndView mav = new ModelAndView("police/personnelStatus/personnelStatusRow");
|
||||
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
|
||||
return mav;
|
||||
}
|
||||
@GetMapping("/selectPersonnelStatus")
|
||||
public PersonnelStatus selectPersonnelStatus(PersonnelStatus personnelStatus){
|
||||
return userInfoService.selectPersonnelStatusLastVersion(personnelStatus);
|
||||
return policeService.selectPersonnelStatusLastVersion(personnelStatus);
|
||||
}
|
||||
@GetMapping("/nowPersonnelStatus")
|
||||
public PersonnelStatus nowPersonnelStatus(String ogCd){
|
||||
return userInfoService.nowPersonnelStatus(ogCd);
|
||||
return policeService.nowPersonnelStatus(ogCd);
|
||||
}
|
||||
@PostMapping("/savePersonnelStatus")
|
||||
@ResponseBody
|
||||
public void savePersonnelStatus(@AuthenticationPrincipal UserInfo loginUser, @RequestBody List<PersonnelStatus> personnelStatusList){
|
||||
userInfoService.savePersonnelStatus(loginUser, personnelStatusList);
|
||||
policeService.savePersonnelStatus(loginUser, personnelStatusList);
|
||||
}
|
||||
@GetMapping("/personnelStatusHistory")
|
||||
public ModelAndView personnelStatusHistory(PersonnelStatus status){
|
||||
ModelAndView mav = new ModelAndView("faisp/personnelStatus/personnelStatusHistory");
|
||||
ModelAndView mav = new ModelAndView("police/personnelStatus/personnelStatusHistory");
|
||||
mav.addObject("jtList", codeMgtService.selectCodeMgtList("JT", "reverse"));
|
||||
List<PersonnelStatus> statusList = userInfoService.selectPersonnelStatusHistoryList(status);
|
||||
List<PersonnelStatus> statusList = policeService.selectPersonnelStatusHistoryList(status);
|
||||
mav.addObject("statusList", calcStatusList(statusList));
|
||||
return mav;
|
||||
}
|
||||
|
||||
@GetMapping("/careerMgt")
|
||||
public ModelAndView careerMgt(@AuthenticationPrincipal UserInfo loginUser, UserInfo userInfo){
|
||||
ModelAndView mav = new ModelAndView("faisp/career/careerMgt");
|
||||
ModelAndView mav = new ModelAndView("police/career/careerMgt");
|
||||
userInfo.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
if(userInfo.getUserStatus() == null) {
|
||||
userInfo.setUserStatus("USC003");
|
||||
}
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/careerMgt").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/careerMgt").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
userInfo.setQueryInfo();
|
||||
mav.addObject("policeList", userInfoService.selectPoliceList(userInfo));
|
||||
|
|
@ -219,21 +214,21 @@ public class FaispController {
|
|||
}
|
||||
@GetMapping("/careerModal")
|
||||
public ModelAndView careerModal(@AuthenticationPrincipal UserInfo loginUser, UserCareer career){
|
||||
ModelAndView mav = new ModelAndView("faisp/career/careerModal");
|
||||
ModelAndView mav = new ModelAndView("police/career/careerModal");
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/careerMgt").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/careerMgt").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
mav.addObject("selectedTab", career.getCareerCd());
|
||||
mav.addObject("crcList", codeMgtService.selectCodeMgtList("CRC", ""));
|
||||
mav.addObject("userInfo", userInfoService.selectPoliceInfo(career.getUserSeq()));
|
||||
mav.addObject("careerList", userInfoService.selectCareerList(career.getUserSeq()));
|
||||
mav.addObject("userInfo", policeService.selectPoliceInfo(career.getUserSeq()));
|
||||
mav.addObject("careerList", policeService.selectCareerList(career.getUserSeq()));
|
||||
mav.addObject("userSeq", loginUser.getUserSeq());
|
||||
return mav;
|
||||
}
|
||||
@GetMapping("/careerFormModal")
|
||||
public ModelAndView careerFormModal(@AuthenticationPrincipal UserInfo loginUser, UserCareer career){
|
||||
ModelAndView mav = new ModelAndView("faisp/career/careerFormModal");
|
||||
ModelAndView mav = new ModelAndView("police/career/careerFormModal");
|
||||
mav.addObject("crcList", codeMgtService.selectCodeMgtList("CRC", ""));
|
||||
mav.addObject("dsnList", codeMgtService.selectCodeMgtList("DSN", ""));
|
||||
mav.addObject("ogList", codeMgtService.selectCodeMgtList("OG", ""));
|
||||
|
|
@ -250,7 +245,7 @@ public class FaispController {
|
|||
career.setWrtUserGrd(loginUser.getTitleCd());
|
||||
career.setWrtUserNm(loginUser.getUserNm());
|
||||
career.setWrtDt(LocalDateTime.now());
|
||||
userInfoService.saveCareer(career);
|
||||
policeService.saveCareer(career);
|
||||
}
|
||||
@PostMapping("/saveCareerList")
|
||||
public void saveCareerList(@AuthenticationPrincipal UserInfo loginUser, UserCareer info){
|
||||
|
|
@ -262,23 +257,23 @@ public class FaispController {
|
|||
career.setWrtUserNm(loginUser.getUserNm());
|
||||
career.setWrtDt(LocalDateTime.now());
|
||||
}
|
||||
userInfoService.saveCareerList(info.getCareerList());
|
||||
policeService.saveCareerList(info.getCareerList());
|
||||
}
|
||||
@PostMapping("/deleteCareer")
|
||||
public void deleteCareer(UserCareer career){
|
||||
userInfoService.deleteCareer(career);
|
||||
policeService.deleteCareer(career);
|
||||
}
|
||||
|
||||
@GetMapping("/educationMgt")
|
||||
public ModelAndView educationMgt(@AuthenticationPrincipal UserInfo loginUser, UserInfo userInfo, HttpServletResponse response){
|
||||
ModelAndView mav = new ModelAndView("faisp/education/educationMgt");
|
||||
ModelAndView mav = new ModelAndView("police/education/educationMgt");
|
||||
userInfo.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
if(userInfo.getUserStatus() == null) {
|
||||
userInfo.setUserStatus("USC003");
|
||||
}
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/educationMgt").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/educationMgt").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
userInfo.setQueryInfo();
|
||||
mav.addObject("policeList", userInfoService.selectPoliceList(userInfo));
|
||||
|
|
@ -292,13 +287,13 @@ public class FaispController {
|
|||
|
||||
@GetMapping("/eduEditModal")
|
||||
public ModelAndView eduEditModal(@AuthenticationPrincipal UserInfo loginUser,UserEdu userEdu){
|
||||
ModelAndView mav = new ModelAndView("/faisp/education/eduEditModal");
|
||||
ModelAndView mav = new ModelAndView("police/education/eduEditModal");
|
||||
|
||||
//메뉴권한 확인
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/faisp/educationMgt").get(0).getAccessAuth();
|
||||
String accessAuth = authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/police/educationMgt").get(0).getAccessAuth();
|
||||
mav.addObject("accessAuth", accessAuth);
|
||||
mav.addObject("userInfo", userInfoService.selectPoliceInfo(userEdu.getUserSeq()));
|
||||
mav.addObject("eduList", userInfoService.selectEduList(userEdu));
|
||||
mav.addObject("userInfo", policeService.selectPoliceInfo(userEdu.getUserSeq()));
|
||||
mav.addObject("eduList", policeService.selectEduList(userEdu));
|
||||
mav.addObject("userSeq", loginUser.getUserSeq());
|
||||
return mav;
|
||||
}
|
||||
|
|
@ -306,13 +301,13 @@ public class FaispController {
|
|||
@PostMapping("/saveEdu")
|
||||
@ResponseBody
|
||||
public int saveEdu(@AuthenticationPrincipal UserInfo loginUser,@RequestBody List<UserEdu> userEdu){
|
||||
return userInfoService.saveEdu(loginUser,userEdu);
|
||||
return policeService.saveEdu(loginUser,userEdu);
|
||||
}
|
||||
|
||||
@PostMapping("/deleteEdu")
|
||||
@ResponseBody
|
||||
public int deleteEdu(@RequestBody UserEdu userEdu) {
|
||||
return userInfoService.deleteEdu(userEdu);
|
||||
return policeService.deleteEdu(userEdu);
|
||||
}
|
||||
|
||||
private List<PersonnelStatus> calcStatusList(List<PersonnelStatus> statusList) {
|
||||
|
|
@ -2,8 +2,11 @@ package com.dbnt.faisp.main.userInfo;
|
|||
|
||||
import com.dbnt.faisp.kwms.service.KwmsService;
|
||||
import com.dbnt.faisp.main.codeMgt.service.CodeMgtService;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInoutLog;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserRequestLog;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserInfoService;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import com.dbnt.faisp.main.userInfo.service.UserLogService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
|
|
@ -16,9 +19,10 @@ import org.springframework.web.servlet.ModelAndView;
|
|||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@RequestMapping("/userMgt")
|
||||
public class userMgtController {
|
||||
public class UserMgtController {
|
||||
|
||||
private final UserInfoService userInfoService;
|
||||
private final UserLogService userLogService;
|
||||
private final CodeMgtService codeMgtService;
|
||||
private final KwmsService kwmsService;
|
||||
|
||||
|
|
@ -91,4 +95,29 @@ public class userMgtController {
|
|||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
@GetMapping("/userLog/requestLog")
|
||||
public ModelAndView requestLog(@AuthenticationPrincipal UserInfo loginUser, UserRequestLog requestLog){
|
||||
ModelAndView mav = new ModelAndView("adminPage/userLog/requestLog");
|
||||
requestLog.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
requestLog.setQueryInfo();
|
||||
mav.addObject("logList", userLogService.selectRequestLogList(requestLog));
|
||||
requestLog.setContentCnt(userLogService.selectRequestLogListCnt(requestLog));
|
||||
requestLog.setPaginationInfo();
|
||||
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
|
||||
mav.addObject("searchParams", requestLog);
|
||||
return mav;
|
||||
}
|
||||
@GetMapping("/userLog/inoutLog")
|
||||
public ModelAndView inoutLog(@AuthenticationPrincipal UserInfo loginUser, UserInoutLog inoutLog){
|
||||
ModelAndView mav = new ModelAndView("adminPage/userLog/inoutLog");
|
||||
inoutLog.setDownOrganCdList(loginUser.getDownOrganCdList());
|
||||
inoutLog.setQueryInfo();
|
||||
mav.addObject("logList", userLogService.selectInoutLogList(inoutLog));
|
||||
inoutLog.setContentCnt(userLogService.selectInoutLogListCnt(inoutLog));
|
||||
inoutLog.setPaginationInfo();
|
||||
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
|
||||
mav.addObject("searchParams", inoutLog);
|
||||
return mav;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,10 +1,6 @@
|
|||
package com.dbnt.faisp.main.userInfo.mapper;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.model.DashboardConfig;
|
||||
import com.dbnt.faisp.main.userInfo.model.PersonnelStatus;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserEdu;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfoHistory;
|
||||
import com.dbnt.faisp.main.userInfo.model.*;
|
||||
import com.dbnt.faisp.util.ParamMap;
|
||||
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
|
@ -37,4 +33,11 @@ public interface UserInfoMapper {
|
|||
|
||||
List<UserEdu> selectEduList(UserEdu userEdu);
|
||||
|
||||
List<UserRequestLog> selectRequestLogList(UserRequestLog requestLog);
|
||||
|
||||
Integer selectRequestLogListCnt(UserRequestLog requestLog);
|
||||
|
||||
List<UserInoutLog> selectInoutLogList(UserInoutLog inoutLog);
|
||||
|
||||
Integer selectInoutLogListCnt(UserInoutLog inoutLog);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,41 @@
|
|||
package com.dbnt.faisp.main.userInfo.model;
|
||||
|
||||
import com.dbnt.faisp.config.BaseModel;
|
||||
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 javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "user_inout_log")
|
||||
public class UserInoutLog extends BaseModel {
|
||||
@Id
|
||||
@Column(name = "inout_key")
|
||||
private String inoutKey;
|
||||
@Column(name = "inout_type")
|
||||
private String inoutType;
|
||||
@Column(name = "contact_ip")
|
||||
private String contactIp;
|
||||
@Column(name = "session_id")
|
||||
private String sessionId;
|
||||
@Column(name = "user_belong")
|
||||
private String userBelong;
|
||||
@Column(name = "wrt_dt")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDateTime wrtDt;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,50 @@
|
|||
package com.dbnt.faisp.main.userInfo.model;
|
||||
|
||||
import com.dbnt.faisp.config.BaseModel;
|
||||
import lombok.*;
|
||||
import org.hibernate.annotations.DynamicInsert;
|
||||
import org.hibernate.annotations.DynamicUpdate;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@NoArgsConstructor
|
||||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "user_request_log")
|
||||
public class UserRequestLog extends BaseModel {
|
||||
@Id
|
||||
@Column(name = "ul_key")
|
||||
private String ulKey;
|
||||
@Column(name = "contact_ip")
|
||||
private String contactIp;
|
||||
@Column(name = "request_url")
|
||||
private String requestUrl;
|
||||
@Column(name = "request_method")
|
||||
private String requestMethod;
|
||||
@Column(name = "search_params")
|
||||
private String searchParams;
|
||||
@Column(name = "handler_description")
|
||||
private String handlerDescription;
|
||||
@Column(name = "user_belong")
|
||||
private String userBelong;
|
||||
@Column(name = "wrt_dt")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDateTime wrtDt;
|
||||
|
||||
@Transient
|
||||
private String organValue;
|
||||
@Transient
|
||||
private String officeValue;
|
||||
@Transient
|
||||
private String titleValue;
|
||||
@Transient
|
||||
private String userNm;
|
||||
@Transient
|
||||
private String userId;
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
package com.dbnt.faisp.main.userInfo.repository;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInoutLog;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
|
||||
public interface UserInoutLogRepository extends JpaRepository<UserInoutLog, String> {
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
package com.dbnt.faisp.main.userInfo.repository;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.model.UserRequestLog;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
|
||||
public interface UserRequestLogRepository extends JpaRepository<UserRequestLog, String> {
|
||||
}
|
||||
|
|
@ -0,0 +1,130 @@
|
|||
package com.dbnt.faisp.main.userInfo.service;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.mapper.UserInfoMapper;
|
||||
import com.dbnt.faisp.main.userInfo.model.PersonnelStatus;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserCareer;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserEdu;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInfo;
|
||||
import com.dbnt.faisp.main.userInfo.repository.PersonnelStatusRepository;
|
||||
import com.dbnt.faisp.main.userInfo.repository.UserCareerRepository;
|
||||
import com.dbnt.faisp.main.userInfo.repository.UserEduRepository;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.security.core.annotation.AuthenticationPrincipal;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.temporal.ChronoUnit;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class PoliceService {
|
||||
|
||||
private final UserCareerRepository userCareerRepository;
|
||||
private final UserEduRepository userEduRepository;
|
||||
private final PersonnelStatusRepository personnelStatusRepository;
|
||||
private final UserInfoMapper userInfoMapper;
|
||||
|
||||
|
||||
public void saveCareer(UserCareer career) {
|
||||
UserCareer lastCareer = userCareerRepository.findTop1ByUserSeqOrderByCareerSeqDesc(career.getUserSeq()).orElse(null);
|
||||
career.setCareerSeq(lastCareer==null?1:(lastCareer.getCareerSeq()+1));
|
||||
career.setWorkMonth((int) ChronoUnit.MONTHS.between(career.getStartDate(), career.getEndDate()));
|
||||
career.setWorkDay((int) ChronoUnit.DAYS.between(career.getStartDate(), career.getEndDate()));
|
||||
userCareerRepository.save(career);
|
||||
}
|
||||
|
||||
public void saveCareerList(List<UserCareer> careerList) {
|
||||
UserCareer lastCareer = userCareerRepository.findTop1ByUserSeqOrderByCareerSeqDesc(careerList.get(0).getUserSeq()).orElse(null);
|
||||
int careerSeq = lastCareer==null?1:(lastCareer.getCareerSeq()+1);
|
||||
for(UserCareer career: careerList){
|
||||
career.setCareerSeq(careerSeq++);
|
||||
}
|
||||
userCareerRepository.saveAll(careerList);
|
||||
}
|
||||
|
||||
public List<UserCareer> selectCareerList(Integer userSeq) {
|
||||
return userCareerRepository.findByUserSeqOrderByStartDateDesc(userSeq);
|
||||
}
|
||||
|
||||
public void deleteCareer(UserCareer career) {
|
||||
userCareerRepository.deleteById(new UserCareer.UserCareerId(career.getUserSeq(), career.getCareerSeq()));
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public int saveEdu(@AuthenticationPrincipal UserInfo loginUser, List<UserEdu> userEdu) {
|
||||
int userSeq = 0;
|
||||
for(UserEdu ue : userEdu ) {
|
||||
UserEdu dbEdu = userEduRepository.findTopByUserSeqOrderByEduSeqDesc(ue.getUserSeq());
|
||||
if (dbEdu == null) {
|
||||
ue.setEduSeq(1);
|
||||
ue.setWrtOrgan(loginUser.getOgCd());
|
||||
ue.setWrtPart(loginUser.getOfcCd());
|
||||
ue.setWrtTitle(loginUser.getTitleCd());
|
||||
ue.setWrtUserSeq(loginUser.getUserSeq());
|
||||
ue.setWrtNm(loginUser.getUserNm());
|
||||
ue.setWrtDt(LocalDateTime.now());
|
||||
userEduRepository.save(ue);
|
||||
} else {
|
||||
ue.setEduSeq(dbEdu.getEduSeq()+ 1);
|
||||
ue.setWrtOrgan(loginUser.getOgCd());
|
||||
ue.setWrtPart(loginUser.getOfcCd());
|
||||
ue.setWrtTitle(loginUser.getTitleCd());
|
||||
ue.setWrtUserSeq(loginUser.getUserSeq());
|
||||
ue.setWrtNm(loginUser.getUserNm());
|
||||
ue.setWrtDt(LocalDateTime.now());
|
||||
userEduRepository.save(ue);
|
||||
}
|
||||
userSeq = ue.getUserSeq();
|
||||
}
|
||||
return userSeq;
|
||||
}
|
||||
public List<UserEdu> selectEduList(UserEdu userEdu) {
|
||||
return userInfoMapper.selectEduList(userEdu);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public int deleteEdu(UserEdu userEdu) {
|
||||
userEduRepository.deleteById(new UserEdu.UserEduId(userEdu.getEduSeq(), userEdu.getUserSeq()));
|
||||
return userEdu.getUserSeq();
|
||||
}
|
||||
|
||||
|
||||
|
||||
public List<PersonnelStatus> selectPersonnelStatusList(PersonnelStatus personnelStatus) {
|
||||
return userInfoMapper.selectPersonnelStatusList(personnelStatus);
|
||||
}
|
||||
public PersonnelStatus selectPersonnelStatusLastVersion(PersonnelStatus personnelStatus) {
|
||||
return personnelStatusRepository
|
||||
.findTop1ByYearAndOgCdOrderByVersionNoDesc
|
||||
(personnelStatus.getYear(), personnelStatus.getOgCd()).orElse(personnelStatus);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void savePersonnelStatus(UserInfo loginUser, List<PersonnelStatus> personnelStatusList) {
|
||||
for(PersonnelStatus status: personnelStatusList){
|
||||
PersonnelStatus lastVersion = personnelStatusRepository.findTop1ByYearAndOgCdOrderByVersionNoDesc(status.getYear(), status.getOgCd()).orElse(null);
|
||||
status.setVersionNo(lastVersion==null?1:(lastVersion.getVersionNo()+1));
|
||||
status.setWrtOrgan(loginUser.getOgCd());
|
||||
status.setWrtPart(loginUser.getOfcCd());
|
||||
status.setWrtUserSeq(loginUser.getUserSeq());
|
||||
status.setWrtUserNm(loginUser.getUserNm());
|
||||
status.setWrtUserGrd(loginUser.getTitleCd());
|
||||
status.setWrtDt(LocalDateTime.now());
|
||||
}
|
||||
personnelStatusRepository.saveAll(personnelStatusList);
|
||||
}
|
||||
|
||||
public PersonnelStatus nowPersonnelStatus(String ogCd) {
|
||||
return userInfoMapper.nowPersonnelStatus(ogCd);
|
||||
}
|
||||
|
||||
public List<PersonnelStatus> selectPersonnelStatusHistoryList(PersonnelStatus status) {
|
||||
return personnelStatusRepository.findByYearAndOgCdOrderByVersionNoDesc(status.getYear(), status.getOgCd());
|
||||
}
|
||||
|
||||
public UserInfo selectPoliceInfo(Integer userSeq) {
|
||||
return userInfoMapper.selectPoliceInfo(userSeq);
|
||||
}
|
||||
}
|
||||
|
|
@ -3,13 +3,11 @@ package com.dbnt.faisp.main.userInfo.service;
|
|||
import com.dbnt.faisp.config.Role;
|
||||
import com.dbnt.faisp.main.userInfo.mapper.UserInfoMapper;
|
||||
import com.dbnt.faisp.main.userInfo.model.*;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserEdu.UserEduId;
|
||||
import com.dbnt.faisp.main.userInfo.repository.*;
|
||||
import com.dbnt.faisp.util.ParamMap;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
|
||||
import org.springframework.security.core.annotation.AuthenticationPrincipal;
|
||||
import org.springframework.security.core.userdetails.UserDetails;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||
|
|
@ -18,8 +16,6 @@ import org.springframework.stereotype.Service;
|
|||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.Period;
|
||||
import java.time.temporal.ChronoUnit;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
|
|
@ -29,9 +25,6 @@ public class UserInfoService implements UserDetailsService {
|
|||
private final UserInfoRepository userInfoRepository;
|
||||
private final UserInfoHistoryRepository userInfoHistoryRepository;
|
||||
private final DashboardConfigRepository dashboardConfigRepository;
|
||||
private final PersonnelStatusRepository personnelStatusRepository;
|
||||
private final UserCareerRepository userCareerRepository;
|
||||
private final UserEduRepository userEduRepository;
|
||||
private final UserInfoMapper userInfoMapper;
|
||||
|
||||
@Transactional
|
||||
|
|
@ -285,110 +278,11 @@ public class UserInfoService implements UserDetailsService {
|
|||
return userInfoMapper.selectPoliceHisList(userInfoHistory);
|
||||
}
|
||||
|
||||
public UserInfoHistory selectpoliceHistoryView(UserInfoHistory userInfoHistory) {
|
||||
public UserInfoHistory selectPoliceHistoryView(UserInfoHistory userInfoHistory) {
|
||||
return userInfoMapper.selectpoliceHistoryView(userInfoHistory);
|
||||
}
|
||||
public String selectuserStatus(UserInfoHistory userInfoHistory) {
|
||||
public String selectUserStatus(UserInfoHistory userInfoHistory) {
|
||||
return userInfoRepository.getUserStatus(userInfoHistory.getUserSeq());
|
||||
}
|
||||
|
||||
public List<PersonnelStatus> selectPersonnelStatusList(PersonnelStatus personnelStatus) {
|
||||
return userInfoMapper.selectPersonnelStatusList(personnelStatus);
|
||||
}
|
||||
public PersonnelStatus selectPersonnelStatusLastVersion(PersonnelStatus personnelStatus) {
|
||||
return personnelStatusRepository
|
||||
.findTop1ByYearAndOgCdOrderByVersionNoDesc
|
||||
(personnelStatus.getYear(), personnelStatus.getOgCd()).orElse(personnelStatus);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void savePersonnelStatus(UserInfo loginUser, List<PersonnelStatus> personnelStatusList) {
|
||||
for(PersonnelStatus status: personnelStatusList){
|
||||
PersonnelStatus lastVersion = personnelStatusRepository.findTop1ByYearAndOgCdOrderByVersionNoDesc(status.getYear(), status.getOgCd()).orElse(null);
|
||||
status.setVersionNo(lastVersion==null?1:(lastVersion.getVersionNo()+1));
|
||||
status.setWrtOrgan(loginUser.getOgCd());
|
||||
status.setWrtPart(loginUser.getOfcCd());
|
||||
status.setWrtUserSeq(loginUser.getUserSeq());
|
||||
status.setWrtUserNm(loginUser.getUserNm());
|
||||
status.setWrtUserGrd(loginUser.getTitleCd());
|
||||
status.setWrtDt(LocalDateTime.now());
|
||||
}
|
||||
personnelStatusRepository.saveAll(personnelStatusList);
|
||||
}
|
||||
|
||||
public PersonnelStatus nowPersonnelStatus(String ogCd) {
|
||||
return userInfoMapper.nowPersonnelStatus(ogCd);
|
||||
}
|
||||
|
||||
public List<PersonnelStatus> selectPersonnelStatusHistoryList(PersonnelStatus status) {
|
||||
return personnelStatusRepository.findByYearAndOgCdOrderByVersionNoDesc(status.getYear(), status.getOgCd());
|
||||
}
|
||||
|
||||
public UserInfo selectPoliceInfo(Integer userSeq) {
|
||||
return userInfoMapper.selectPoliceInfo(userSeq);
|
||||
}
|
||||
|
||||
public void saveCareer(UserCareer career) {
|
||||
UserCareer lastCareer = userCareerRepository.findTop1ByUserSeqOrderByCareerSeqDesc(career.getUserSeq()).orElse(null);
|
||||
career.setCareerSeq(lastCareer==null?1:(lastCareer.getCareerSeq()+1));
|
||||
career.setWorkMonth((int) ChronoUnit.MONTHS.between(career.getStartDate(), career.getEndDate()));
|
||||
career.setWorkDay((int) ChronoUnit.DAYS.between(career.getStartDate(), career.getEndDate()));
|
||||
userCareerRepository.save(career);
|
||||
}
|
||||
|
||||
public void saveCareerList(List<UserCareer> careerList) {
|
||||
UserCareer lastCareer = userCareerRepository.findTop1ByUserSeqOrderByCareerSeqDesc(careerList.get(0).getUserSeq()).orElse(null);
|
||||
int careerSeq = lastCareer==null?1:(lastCareer.getCareerSeq()+1);
|
||||
for(UserCareer career: careerList){
|
||||
career.setCareerSeq(careerSeq++);
|
||||
}
|
||||
userCareerRepository.saveAll(careerList);
|
||||
}
|
||||
|
||||
public List<UserCareer> selectCareerList(Integer userSeq) {
|
||||
return userCareerRepository.findByUserSeqOrderByStartDateDesc(userSeq);
|
||||
}
|
||||
|
||||
public void deleteCareer(UserCareer career) {
|
||||
userCareerRepository.deleteById(new UserCareer.UserCareerId(career.getUserSeq(), career.getCareerSeq()));
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public int saveEdu(@AuthenticationPrincipal UserInfo loginUser,List<UserEdu> userEdu) {
|
||||
int userSeq = 0;
|
||||
for(UserEdu ue : userEdu ) {
|
||||
UserEdu dbEdu = userEduRepository.findTopByUserSeqOrderByEduSeqDesc(ue.getUserSeq());
|
||||
if (dbEdu == null) {
|
||||
ue.setEduSeq(1);
|
||||
ue.setWrtOrgan(loginUser.getOgCd());
|
||||
ue.setWrtPart(loginUser.getOfcCd());
|
||||
ue.setWrtTitle(loginUser.getTitleCd());
|
||||
ue.setWrtUserSeq(loginUser.getUserSeq());
|
||||
ue.setWrtNm(loginUser.getUserNm());
|
||||
ue.setWrtDt(LocalDateTime.now());
|
||||
userEduRepository.save(ue);
|
||||
} else {
|
||||
ue.setEduSeq(dbEdu.getEduSeq()+ 1);
|
||||
ue.setWrtOrgan(loginUser.getOgCd());
|
||||
ue.setWrtPart(loginUser.getOfcCd());
|
||||
ue.setWrtTitle(loginUser.getTitleCd());
|
||||
ue.setWrtUserSeq(loginUser.getUserSeq());
|
||||
ue.setWrtNm(loginUser.getUserNm());
|
||||
ue.setWrtDt(LocalDateTime.now());
|
||||
userEduRepository.save(ue);
|
||||
}
|
||||
userSeq = ue.getUserSeq();
|
||||
}
|
||||
return userSeq;
|
||||
}
|
||||
public List<UserEdu> selectEduList(UserEdu userEdu) {
|
||||
return userInfoMapper.selectEduList(userEdu);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public int deleteEdu(UserEdu userEdu) {
|
||||
userEduRepository.deleteById(new UserEduId(userEdu.getEduSeq(), userEdu.getUserSeq()));
|
||||
return userEdu.getUserSeq();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,53 @@
|
|||
package com.dbnt.faisp.main.userInfo.service;
|
||||
|
||||
import com.dbnt.faisp.main.userInfo.mapper.UserInfoMapper;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserInoutLog;
|
||||
import com.dbnt.faisp.main.userInfo.model.UserRequestLog;
|
||||
import com.dbnt.faisp.main.userInfo.repository.UserInoutLogRepository;
|
||||
import com.dbnt.faisp.main.userInfo.repository.UserRequestLogRepository;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class UserLogService {
|
||||
private final UserRequestLogRepository requestLogRepository;
|
||||
private final UserInoutLogRepository inoutLogRepository;
|
||||
private final UserInfoMapper userInfoMapper;
|
||||
|
||||
@Transactional
|
||||
public void saveRequestLog(UserRequestLog requestLog){
|
||||
LocalDateTime dateTime = LocalDateTime.now();
|
||||
requestLog.setUlKey(dateTime.format(DateTimeFormatter.ofPattern("yyyyMMddHHmmssSSS")));
|
||||
requestLog.setWrtDt(dateTime);
|
||||
requestLogRepository.save(requestLog);
|
||||
}
|
||||
@Transactional
|
||||
public void saveInoutLog(UserInoutLog inoutLog){
|
||||
LocalDateTime dateTime = LocalDateTime.now();
|
||||
inoutLog.setInoutKey(dateTime.format(DateTimeFormatter.ofPattern("yyyyMMddHHmmssSSS")));
|
||||
inoutLog.setWrtDt(dateTime);
|
||||
inoutLogRepository.save(inoutLog);
|
||||
}
|
||||
|
||||
public List<UserRequestLog> selectRequestLogList(UserRequestLog requestLog) {
|
||||
return userInfoMapper.selectRequestLogList(requestLog);
|
||||
}
|
||||
|
||||
public Integer selectRequestLogListCnt(UserRequestLog requestLog) {
|
||||
return userInfoMapper.selectRequestLogListCnt(requestLog);
|
||||
}
|
||||
|
||||
public List<UserInoutLog> selectInoutLogList(UserInoutLog inoutLog) {
|
||||
return userInfoMapper.selectInoutLogList(inoutLog);
|
||||
}
|
||||
|
||||
public Integer selectInoutLogListCnt(UserInoutLog inoutLog) {
|
||||
return userInfoMapper.selectInoutLogListCnt(inoutLog);
|
||||
}
|
||||
}
|
||||
|
|
@ -9,6 +9,7 @@ import java.time.format.DateTimeFormatter;
|
|||
import java.util.*;
|
||||
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
|
||||
|
|
@ -1069,5 +1070,26 @@ public class Utils {
|
|||
|
||||
}
|
||||
|
||||
public static String getClientIP(HttpServletRequest request) {
|
||||
String ip = request.getHeader("X-Forwarded-For");
|
||||
|
||||
if (ip == null) {
|
||||
ip = request.getHeader("Proxy-Client-IP");
|
||||
}
|
||||
if (ip == null) {
|
||||
ip = request.getHeader("WL-Proxy-Client-IP");
|
||||
}
|
||||
if (ip == null) {
|
||||
ip = request.getHeader("HTTP_CLIENT_IP");
|
||||
}
|
||||
if (ip == null) {
|
||||
ip = request.getHeader("HTTP_X_FORWARDED_FOR");
|
||||
}
|
||||
if (ip == null) {
|
||||
ip = request.getRemoteAddr();
|
||||
}
|
||||
|
||||
return ip;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -314,4 +314,38 @@
|
|||
where user_seq = #{userSeq}
|
||||
order by edu_seq desc
|
||||
</select>
|
||||
<sql id="selectRequestLogListWhere">
|
||||
<where>
|
||||
|
||||
</where>
|
||||
</sql>
|
||||
<select id="selectRequestLogList" resultType="UserRequestLog" parameterType="UserRequestLog">
|
||||
select *
|
||||
from user_request_log
|
||||
<include refid="selectRequestLogListWhere"></include>
|
||||
order by ul_key desc
|
||||
limit #{rowCnt} offset #{firstIndex}
|
||||
</select>
|
||||
<select id="selectRequestLogListCnt" resultType="int" parameterType="UserRequestLog">
|
||||
select count(*)
|
||||
from user_request_log
|
||||
<include refid="selectRequestLogListWhere"></include>
|
||||
</select>
|
||||
<sql id="selectInoutLogListWhere">
|
||||
<where>
|
||||
|
||||
</where>
|
||||
</sql>
|
||||
<select id="selectInoutLogList" resultType="UserInoutLog" parameterType="UserInoutLog">
|
||||
select *
|
||||
from user_inout_log
|
||||
<include refid="selectInoutLogListWhere"></include>
|
||||
order by inout_key desc
|
||||
limit #{rowCnt} offset #{firstIndex}
|
||||
</select>
|
||||
<select id="selectInoutLogListCnt" resultType="int" parameterType="UserInoutLog">
|
||||
select count(*)
|
||||
from user_inout_log
|
||||
<include refid="selectInoutLogListWhere"></include>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -1,15 +1,15 @@
|
|||
$(document).on('click', '#previousTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/careerMgt?userStatus="+userStatus;
|
||||
location.href = "/police/careerMgt?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '#presentTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/careerMgt?userStatus="+userStatus;
|
||||
location.href = "/police/careerMgt?userStatus="+userStatus;
|
||||
})
|
||||
$(document).on('click', '#notPoliceTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/careerMgt?userStatus="+userStatus;
|
||||
location.href = "/police/careerMgt?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '.policeTr', function (){
|
||||
|
|
@ -18,7 +18,7 @@ $(document).on('click', '.policeTr', function (){
|
|||
|
||||
$(document).on('click', '.careerAddBtn', function (){
|
||||
$.ajax({
|
||||
url: '/faisp/careerFormModal',
|
||||
url: '/police/careerFormModal',
|
||||
data: {
|
||||
userSeq: $("#mngModelUserSeq").val(),
|
||||
careerCd: $(this).attr("data-careercd")
|
||||
|
|
@ -70,7 +70,7 @@ $(document).on('click', '#kwmsModalSelectBtn', function (){
|
|||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
url : "/faisp/saveCareerList",
|
||||
url : "/police/saveCareerList",
|
||||
processData: false,
|
||||
contentType: false,
|
||||
beforeSend: function (xhr){
|
||||
|
|
@ -115,7 +115,7 @@ $(document).on('click', '#saveBtn', function (){
|
|||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
url : "/faisp/saveCareer",
|
||||
url : "/police/saveCareer",
|
||||
processData: false,
|
||||
contentType: false,
|
||||
beforeSend: function (xhr){
|
||||
|
|
@ -141,7 +141,7 @@ $(document).on('click', '.deleteCareerBtn', function (){
|
|||
const tabCd = $(this).attr("data-tab")
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
url : "/faisp/deleteCareer",
|
||||
url : "/police/deleteCareer",
|
||||
data : {
|
||||
userSeq: userSeq,
|
||||
careerSeq: $(this).attr("data-careerseq")
|
||||
|
|
@ -164,7 +164,7 @@ $(document).on('click', '.deleteCareerBtn', function (){
|
|||
|
||||
function getCareerModal(userSeq, careerCd){
|
||||
$.ajax({
|
||||
url: '/faisp/careerModal',
|
||||
url: '/police/careerModal',
|
||||
data: {userSeq: userSeq, careerCd: careerCd},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
|
|
@ -11,7 +11,7 @@ $(document).on('click', '.policeTr', function (event){
|
|||
|
||||
function showModal(userSeq){
|
||||
$.ajax({
|
||||
url: '/faisp/eduEditModal',
|
||||
url: '/police/eduEditModal',
|
||||
data: {userSeq: userSeq},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
|
|
@ -32,16 +32,16 @@ function showModal(userSeq){
|
|||
|
||||
$(document).on('click', '#previousTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/educationMgt?userStatus="+userStatus;
|
||||
location.href = "/police/educationMgt?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '#presentTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/educationMgt?userStatus="+userStatus;
|
||||
location.href = "/police/educationMgt?userStatus="+userStatus;
|
||||
})
|
||||
$(document).on('click', '#notPoliceTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/educationMgt?userStatus="+userStatus;
|
||||
location.href = "/police/educationMgt?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '#eduAddBtn', function (){
|
||||
|
|
@ -119,7 +119,7 @@ $(document).on('click', '#saveBtn', function (){
|
|||
$.ajax({
|
||||
type : 'POST',
|
||||
data : JSON.stringify(eduList),
|
||||
url : "/faisp/saveEdu",
|
||||
url : "/police/saveEdu",
|
||||
contentType: 'application/json',
|
||||
beforeSend: function (xhr){
|
||||
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
|
||||
|
|
@ -144,7 +144,7 @@ $(document).on('click', '#deleteBtn', function (){
|
|||
if(confirm("삭제하시겠습니까?")){
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
url : "/faisp/deleteEdu",
|
||||
url : "/police/deleteEdu",
|
||||
data : JSON.stringify({eduSeq:eduSeq,
|
||||
userSeq:userSeq}),
|
||||
contentType: 'application/json',
|
||||
|
|
@ -13,7 +13,7 @@ $(document).on('click', '#personnelStatusEditModalBtn', function (){
|
|||
|
||||
$(document).on('click', '#personnelStatusAddBtn', function (){
|
||||
$.ajax({
|
||||
url: '/faisp/personnelStatusRow',
|
||||
url: '/police/personnelStatusRow',
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
success: function(html){
|
||||
|
|
@ -34,7 +34,7 @@ $(document).on('change', '.ogCd', function (){
|
|||
if(this.value !== ''){
|
||||
personnelStatusRow.find(".nowPersonnelStatusBtn")[0].className = "btn btn-sm btn-success nowPersonnelStatusBtn";
|
||||
$.ajax({
|
||||
url: '/faisp/selectPersonnelStatus',
|
||||
url: '/police/selectPersonnelStatus',
|
||||
type: 'GET',
|
||||
data: {year: new Date().getFullYear(), ogCd: this.value},
|
||||
dataType:"json",
|
||||
|
|
@ -66,7 +66,7 @@ $(document).on('change', '.ogCd', function (){
|
|||
$(document).on('click', '.nowPersonnelStatusBtn', function (){
|
||||
const personnelStatusRow = $(this).parents(".personnelStatusRow");
|
||||
$.ajax({
|
||||
url: '/faisp/nowPersonnelStatus',
|
||||
url: '/police/nowPersonnelStatus',
|
||||
type: 'GET',
|
||||
data: {ogCd: personnelStatusRow.find(".ogCd").val()},
|
||||
dataType:"json",
|
||||
|
|
@ -121,7 +121,7 @@ $(document).on('click', '#saveBtn', function (){
|
|||
$.ajax({
|
||||
type : 'POST',
|
||||
data : JSON.stringify(personnelStatusList),
|
||||
url : "/faisp/savePersonnelStatus",
|
||||
url : "/police/savePersonnelStatus",
|
||||
contentType: 'application/json',
|
||||
beforeSend: function (xhr){
|
||||
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
|
||||
|
|
@ -144,7 +144,7 @@ $(document).on('click', '#saveBtn', function (){
|
|||
$(document).on('click', '.statusTr', function (){
|
||||
const statusTr = $(this);
|
||||
$.ajax({
|
||||
url: '/faisp/personnelStatusHistory',
|
||||
url: '/police/personnelStatusHistory',
|
||||
type: 'GET',
|
||||
data: {year: statusTr.attr("data-year"), ogCd: statusTr.attr("data-ogcd")},
|
||||
dataType:"html",
|
||||
|
|
@ -8,7 +8,7 @@ $(document).on('click', '.policeTr', function (event){
|
|||
|
||||
function showModal(userSeq){
|
||||
$.ajax({
|
||||
url: '/faisp/policeEditModal',
|
||||
url: '/police/policeEditModal',
|
||||
data: {userSeq: userSeq},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
|
|
@ -42,7 +42,7 @@ $(document).on('click', '#syncToKwmsBtn', function (){
|
|||
function syncUserInfoToKwms(userList){
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
url : "/faisp/syncUserInfoToKwms",
|
||||
url : "/police/syncUserInfoToKwms",
|
||||
data : JSON.stringify(userList),
|
||||
contentType: 'application/json',
|
||||
beforeSend: function (xhr){
|
||||
|
|
@ -67,7 +67,7 @@ $(document).on('click', '#updateBtn', function (){
|
|||
$.ajax({
|
||||
type : 'POST',
|
||||
data : formData,
|
||||
url : "/faisp/updateUserInfo",
|
||||
url : "/police/updateUserInfo",
|
||||
processData: false,
|
||||
contentType: false,
|
||||
success : function(data) {
|
||||
|
|
@ -86,7 +86,7 @@ $(document).on('click', '#updateBtn', function (){
|
|||
$(document).on('click', '#historyTab', function (){
|
||||
const userSeq = (Number($(this).data('userseq')));
|
||||
$.ajax({
|
||||
url: '/faisp/policeHistory',
|
||||
url: '/police/policeHistory',
|
||||
data: {userSeq: userSeq},
|
||||
type: 'GET',
|
||||
dataType:"html",
|
||||
|
|
@ -112,7 +112,7 @@ $(document).on('click', '.historyInfoTr', function (){
|
|||
$(this).find('.hisChk').prop('checked',true)
|
||||
}
|
||||
$.ajax({
|
||||
url: '/faisp/policeHistoryView',
|
||||
url: '/police/policeHistoryView',
|
||||
data: {
|
||||
userSeq: Number($(this).find(".userSeq").val()),
|
||||
versionNo : Number($(this).find(".verNo").val())
|
||||
|
|
@ -146,16 +146,16 @@ $(document).on('click', '.historyInfoTr', function (){
|
|||
|
||||
$(document).on('click', '#previousTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/policeList?userStatus="+userStatus;
|
||||
location.href = "/police/policeList?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '#presentTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/policeList?userStatus="+userStatus;
|
||||
location.href = "/police/policeList?userStatus="+userStatus;
|
||||
})
|
||||
$(document).on('click', '#notPoliceTab', function (){
|
||||
const userStatus = $(this).data('userstatus');
|
||||
location.href = "/faisp/policeList?userStatus="+userStatus;
|
||||
location.href = "/police/policeList?userStatus="+userStatus;
|
||||
})
|
||||
|
||||
$(document).on('click', '#outBtn', function (){
|
||||
|
|
@ -173,7 +173,7 @@ $(document).on('click', '#outBtn', function (){
|
|||
})
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
url : "/faisp/policeStatusUpdate",
|
||||
url : "/police/policeStatusUpdate",
|
||||
data : JSON.stringify(checkArr),
|
||||
contentType: 'application/json',
|
||||
beforeSend: function (xhr){
|
||||
|
|
@ -205,7 +205,7 @@ $(document).on('click', '#inBtn', function (){
|
|||
})
|
||||
$.ajax({
|
||||
type : 'POST',
|
||||
url : "/faisp/policeStatusUpdate",
|
||||
url : "/police/policeStatusUpdate",
|
||||
data : JSON.stringify(checkArr),
|
||||
contentType: 'application/json',
|
||||
beforeSend: function (xhr){
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
|
||||
$(document).on('click', '#requestTab', function (){
|
||||
location.href='/userMgt/userLog/requestLog';
|
||||
})
|
||||
$(document).on('click', '#inoutTab', function (){
|
||||
location.href='/userMgt/userLog/inoutLog';
|
||||
})
|
||||
|
||||
$(document).on('click', '.requestLogTr', function (){
|
||||
const logTr = $(this);
|
||||
$("#contactIp").val(logTr.find(".contactIp").val());
|
||||
$("#requestUrl").val(logTr.find(".requestUrl").val());
|
||||
$("#requestMethod").val(logTr.find(".requestMethod").val());
|
||||
$("#searchParams").val(logTr.find(".searchParams").val());
|
||||
$("#handlerDescription").val(logTr.find(".handlerDescription").val());
|
||||
$("#userBelong").val(logTr.find(".userBelong").val());
|
||||
$("#wrtDt").val(logTr.find(".wrtDt").val());
|
||||
$("#requestLogModal").modal("show")
|
||||
})
|
||||
|
||||
$(document).on('click', '.inoutLogTr', function (){
|
||||
const logTr = $(this);
|
||||
$("#contactIp").val(logTr.find(".contactIp").val());
|
||||
$("#inoutType").val(logTr.find(".inoutType").val());
|
||||
$("#sessionId").val(logTr.find(".sessionId").val());
|
||||
$("#userBelong").val(logTr.find(".userBelong").val());
|
||||
$("#wrtDt").val(logTr.find(".wrtDt").val());
|
||||
$("#inoutLogModal").modal("show")
|
||||
})
|
||||
|
|
@ -0,0 +1,180 @@
|
|||
<!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/userMgt/userLog.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
<h4>외사경찰 관리</h4>
|
||||
<ul class="nav nav-tabs" id="boardTab" role="tablist">
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link" id="requestTab" data-bs-toggle="tab" type="button" role="tab">메뉴로그</button>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link active" id="inoutTab" data-bs-toggle="tab" type="button" role="tab">접속로그</button>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="row mx-0">
|
||||
<div class="col-12 tab-content border border-top-0 p-2">
|
||||
<form method="get" th:action="@{/userMgt/userLog/inoutLog}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
<div class="row justify-content-between pe-3 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==num*10}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<div class="row justify-content-end">
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="ogCd">
|
||||
<option value="">관서 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OG')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="ofcCd">
|
||||
<option value="">부서 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OFC')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="titleCd">
|
||||
<option value="">계급 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" class="form-control form-control-sm" name="userNm" placeholder="사용자명">
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" class="form-control form-control-sm" name="userId" placeholder="사용자 아이디">
|
||||
</div>
|
||||
<input type="submit" class="btn btn-sm btn-primary col-auto" id="searchBtn" value="검색">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="row justify-content-start">
|
||||
<div class="col-12">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<table class="table table-hover table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>접속아이피</th>
|
||||
<th>결과</th>
|
||||
<th>사용자</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider">
|
||||
<tr class="inoutLogTr" th:each="log:${logList}">
|
||||
<input type="hidden" class="contactIp" th:value="${log.contactIp}">
|
||||
<th:block th:each="code:${session.commonCode.get('IOT')}">
|
||||
<th:block th:if="${code.itemCd eq log.inoutType}">
|
||||
<input type="hidden" class="inoutType" th:value="${code.itemValue}">
|
||||
</th:block>
|
||||
</th:block>
|
||||
<input type="hidden" class="sessionId" th:value="${log.sessionId}">
|
||||
<input type="hidden" class="userBelong" th:value="${log.userBelong}">
|
||||
<input type="hidden" class="wrtDt" th:value="${#temporals.format(log.wrtDt, 'yyyy-MM-dd HH:mm:ss')}">
|
||||
<td th:text="${log.contactIp}"></td>
|
||||
<td>
|
||||
<th:block th:each="code:${session.commonCode.get('IOT')}">
|
||||
<th:block th:if="${code.itemCd eq log.inoutType}" th:text="${code.itemValue}"></th:block>
|
||||
</th:block>
|
||||
</td>
|
||||
<td th:text="${log.userBelong}"></td>
|
||||
<td th:text="${#temporals.format(log.wrtDt, 'yyyy-MM-dd HH:mm:ss')}"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-auto">
|
||||
<nav aria-label="Page navigation">
|
||||
<ul class="pagination">
|
||||
<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==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>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<div class="modal fade" id="inoutLogModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="inoutLogModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog modal-lg modal-dialog-scrollable">
|
||||
<div class="modal-content" id="inoutLogModalContent">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="inoutLogModalLabel">로그 상세</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row justify-content-start">
|
||||
<label for="userBelong" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">사용자</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="userBelong" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">등록일</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="wrtDt" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="contactIp" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">접속아이피</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="contactIp" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="inoutType" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">결과</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="inoutType" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="sessionId" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">세션 ID</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control form-control-sm" id="sessionId" autocomplete="off" readonly>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
|
||||
<button type="button" class="btn btn-primary" id="saveAuthBtn">저장</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,185 @@
|
|||
<!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/userMgt/userLog.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
<h4>외사경찰 관리</h4>
|
||||
<ul class="nav nav-tabs" id="boardTab" role="tablist">
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link active" id="requestTab" data-bs-toggle="tab" type="button" role="tab">메뉴로그</button>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link" id="inoutTab" data-bs-toggle="tab" type="button" role="tab">접속로그</button>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="row mx-0">
|
||||
<div class="col-12 tab-content border border-top-0 p-2">
|
||||
<form method="get" th:action="@{/userMgt/userLog/requestLog}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
<div class="row justify-content-between pe-3 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==num*10}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<div class="row justify-content-end">
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="ogCd">
|
||||
<option value="">관서 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OG')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="ofcCd">
|
||||
<option value="">부서 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('OFC')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<select class="form-select form-select-sm" name="titleCd">
|
||||
<option value="">계급 선택</option>
|
||||
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
|
||||
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"></option>
|
||||
</th:block>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" class="form-control form-control-sm" name="userNm" placeholder="사용자명">
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" class="form-control form-control-sm" name="userId" placeholder="사용자 아이디">
|
||||
</div>
|
||||
<input type="submit" class="btn btn-sm btn-primary col-auto" id="searchBtn" value="검색">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="row justify-content-start">
|
||||
<div class="col-12">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<table class="table table-hover table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>접속아이피</th>
|
||||
<th>요청 URL</th>
|
||||
<th>접근 방식</th>
|
||||
<th>사용자</th>
|
||||
<th>등록일</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="table-group-divider">
|
||||
<tr class="requestLogTr" th:each="log:${logList}">
|
||||
<input type="hidden" class="contactIp" th:value="${log.contactIp}">
|
||||
<input type="hidden" class="requestUrl" th:value="${log.requestUrl}">
|
||||
<input type="hidden" class="requestMethod" th:value="${log.requestMethod}">
|
||||
<input type="hidden" class="searchParams" th:value="${log.searchParams}">
|
||||
<input type="hidden" class="handlerDescription" th:value="${log.handlerDescription}">
|
||||
<input type="hidden" class="userBelong" th:value="${log.userBelong}">
|
||||
<input type="hidden" class="wrtDt" th:value="${#temporals.format(log.wrtDt, 'yyyy-MM-dd HH:mm:ss')}">
|
||||
<td th:text="${log.contactIp}"></td>
|
||||
<td th:text="${log.requestUrl}"></td>
|
||||
<td th:text="${log.requestMethod}"></td>
|
||||
<td th:text="${log.userBelong}"></td>
|
||||
<td th:text="${#temporals.format(log.wrtDt, 'yyyy-MM-dd HH:mm:ss')}"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-auto">
|
||||
<nav aria-label="Page navigation">
|
||||
<ul class="pagination">
|
||||
<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==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>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<div class="modal fade" id="requestLogModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="requestLogModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog modal-lg modal-dialog-scrollable">
|
||||
<div class="modal-content" id="requestLogModalContent">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="requestLogModalLabel">로그 상세</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row justify-content-start">
|
||||
<label for="userBelong" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">사용자</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="userBelong" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="wrtDt" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">등록일</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="wrtDt" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="contactIp" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">접속아이피</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="contactIp" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="requestUrl" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">요청 URL</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="requestUrl" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="requestMethod" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">접근방식</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control form-control-sm" id="requestMethod" autocomplete="off" readonly>
|
||||
</div>
|
||||
<div class="col-sm-6"></div>
|
||||
<label for="searchParams" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">검색조건</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control form-control-sm" id="searchParams" autocomplete="off" readonly>
|
||||
</div>
|
||||
<label for="handlerDescription" class="col-sm-2 col-form-label col-form-label-sm text-center pb-2">동작 메서드</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control form-control-sm" id="handlerDescription" autocomplete="off" readonly>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
|
||||
<button type="button" class="btn btn-primary" id="saveAuthBtn">저장</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</html>
|
||||
|
|
@ -28,7 +28,7 @@
|
|||
<th:block sec:authorize="hasRole('ROLE_SUB_ADMIN')">
|
||||
<li><a href="/userMgt/userMgtPage" class="dropdown-item">외사경찰관리</a></li>
|
||||
<li><a href="/authMgt/authMgtPage" class="dropdown-item">권한설정</a></li>
|
||||
<li><a href="#" class="dropdown-item">사용자로그</a></li>
|
||||
<li><a href="/userMgt/userLog/requestLog" class="dropdown-item">사용자로그</a></li>
|
||||
<li><a href="#" class="dropdown-item">접속설정</a></li>
|
||||
</th:block>
|
||||
</ul>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
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/faisp/careerMgt.js}"></script>
|
||||
<script type="text/javascript" th:src="@{/js/police/careerMgt.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
|
|
@ -31,7 +31,7 @@
|
|||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-12 pb-2">
|
||||
<form id="searchFm" method="get" th:action="@{/faisp/careerMgt}">
|
||||
<form id="searchFm" method="get" th:action="@{/police/careerMgt}">
|
||||
<input type="hidden" name="userStatus" th:value="${userStatus}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
<div class="row justify-content-between">
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
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/faisp/edu.js}"></script>
|
||||
<script type="text/javascript" th:src="@{/js/police/edu.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
|
|
@ -31,7 +31,7 @@
|
|||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<form id="searchFm" method="get" th:action="@{/faisp/educationMgt}">
|
||||
<form id="searchFm" method="get" th:action="@{/police/educationMgt}">
|
||||
<input type="hidden" name="excel">
|
||||
<input type="hidden" name="userStatus" th:value="${userStatus}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
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/faisp/personnelStatus.js}"></script>
|
||||
<script type="text/javascript" th:src="@{/js/police/personnelStatus.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
|
|
@ -13,7 +13,7 @@
|
|||
<div class="row mx-0">
|
||||
<div class="col-12 card text-center">
|
||||
<div class="card-body">
|
||||
<form id="searchFm" method="get" th:action="@{/faisp/personnelStatus}">
|
||||
<form id="searchFm" method="get" th:action="@{/police/personnelStatus}">
|
||||
<div class="row justify-content-between py-1">
|
||||
<div class="col-auto">
|
||||
<select class="form-select" name="year" id="year">
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
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/faisp/police.js}"></script>
|
||||
<script type="text/javascript" th:src="@{/js/police/police.js}"></script>
|
||||
</th:block>
|
||||
<div layout:fragment="content">
|
||||
<main class="pt-3">
|
||||
|
|
@ -31,7 +31,7 @@
|
|||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<form id="searchFm" method="get" th:action="@{/faisp/policeList}">
|
||||
<form id="searchFm" method="get" th:action="@{/police/policeList}">
|
||||
<input type="hidden" name="excel">
|
||||
<input type="hidden" name="userStatus" th:value="${userStatus}">
|
||||
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
||||
Loading…
Reference in New Issue