교육현황 목록 조회 양식 변경

master
강석 최 2023-02-22 15:34:22 +09:00
parent 4edbc824c8
commit 2e45e86966
6 changed files with 90 additions and 37 deletions

View File

@ -27,8 +27,6 @@ public interface UserInfoMapper {
PersonnelStatus nowPersonnelStatus(String ogCd);
UserInfo selectPoliceInfo(Integer userSeq);
List<UserEdu> selectEduList(UserEdu userEdu);
List<UserRequestLog> selectRequestLogList(UserRequestLog requestLog);

View File

@ -8,6 +8,7 @@ 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 com.dbnt.faisp.main.userInfo.repository.UserInfoRepository;
import lombok.RequiredArgsConstructor;
import org.springframework.security.core.annotation.AuthenticationPrincipal;
import org.springframework.stereotype.Service;
@ -21,7 +22,7 @@ import java.util.List;
@Service
@RequiredArgsConstructor
public class PoliceService {
private final UserInfoRepository userInfoRepository;
private final UserCareerRepository userCareerRepository;
private final UserEduRepository userEduRepository;
private final PersonnelStatusRepository personnelStatusRepository;
@ -136,6 +137,6 @@ public class PoliceService {
}
public UserInfo selectPoliceInfo(Integer userSeq) {
return userInfoMapper.selectPoliceInfo(userSeq);
return userInfoRepository.findById(userSeq).orElse(null);
}
}

View File

@ -187,19 +187,25 @@
select (ROW_NUMBER() OVER(order by user_nm desc)) AS rownum,
a.user_seq,
(select item_value from code_mgt where item_cd = title_cd) as title_cd,
user_nm,
og_cd,
a.user_nm,
a.og_cd,
(select item_value from code_mgt where item_cd = og_cd) as organ_nm,
(select item_value from code_mgt where item_cd = ofc_cd) as ofc_cd,
birth_date,
a.birth_date,
(select item_value from code_mgt where item_cd = sex) as sex,
police_in_date,
title_in_date,
ofc_in_date,
duty_cd,
a.police_in_date,
a.title_in_date,
a.ofc_in_date,
a.duty_cd,
(select item_value from code_mgt where item_cd = outturn_cd) as outturn_cd,
(select item_value from code_mgt where item_cd = job_in_cd) as job_in_cd,
wrt_dt,
a.wrt_dt,
(select item_value from code_mgt where item_cd = a.language_cd) as language_cd,
a.use_language,
a.language_grd,
(select item_value from code_mgt where item_cd = a.education_grd) as education_grd,
a.school,
a.specialism,
b.lastEduWrtDt,
c.edu_name,
c.edu_sdate,
@ -370,20 +376,6 @@
order by a.og_cd
</select>
<select id="selectPoliceInfo" resultType="UserInfo" parameterType="Integer">
select user_seq,
user_nm,
dic_code,
(select item_value from code_mgt where item_cd = title_cd) as title_cd,
(select item_value from code_mgt where item_cd = og_cd) as og_cd,
(select item_value from code_mgt where item_cd = ofc_cd) as ofc_cd,
(select item_value from code_mgt where item_cd = sex) as sex,
birth_date,
(select item_value from code_mgt where item_cd = language_cd) as language_cd
from user_info
where user_seq = #{userSeq}
</select>
<select id="selectEduList" resultType="UserEdu" parameterType="UserEdu">
select edu_seq,
user_seq,

View File

@ -1,7 +1,18 @@
<!DOCTYPE html>
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
<div class="modal-header bg-dark">
<h5 class="modal-title text-white" th:text="|${userInfo.ogCd} ${userInfo.ofcCd eq null?'':userInfo.ofcCd} ${userInfo.titleCd eq null?'':userInfo.titleCd} ${userInfo.userNm}|"></h5>
<h5 class="modal-title text-white">
<th:block th:each="code:${session.commonCode.get('OG')}">
<th:block th:if="${code.itemCd eq userInfo.ogCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:each="code:${session.commonCode.get('OFC')}">
<th:block th:if="${code.itemCd eq userInfo.ofcCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:each="code:${session.commonCode.get('JT')}">
<th:block th:if="${code.itemCd eq userInfo.titleCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:text="${userInfo.userNm}"></th:block>
</h5>
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">

View File

@ -7,13 +7,50 @@
<div class="modal-body">
<div class="mb-3 mt-3 row">
<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="${userInfo.ogCd}"></label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
<th:block th:each="code:${session.commonCode.get('OG')}">
<th:block th:if="${code.itemCd eq userInfo.ogCd}" 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">부서</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${userInfo.ofcCd}"></label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
<th:block th:each="code:${session.commonCode.get('OFC')}">
<th:block th:if="${code.itemCd eq userInfo.ofcCd}" 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">직급</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${userInfo.titleCd}"></label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
<th:block th:each="code:${session.commonCode.get('JT')}">
<th:block th:if="${code.itemCd eq userInfo.titleCd}" 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">이름</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${userInfo.userNm}"></label>
<label class="col-sm-1 col-form-label col-form-label-sm text-center fw-bold fs-10">외국어특채</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
<th:block th:each="code:${session.commonCode.get('LNG')}">
<th:block th:if="${code.itemCd eq userInfo.languageCd}" 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 fs-10">구사외국어</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${userInfo.useLanguage}"></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:block th:if="${userInfo.languageGrd eq '1'}"></th:block>
<th:block th:if="${userInfo.languageGrd eq '2'}"></th:block>
<th:block th:if="${userInfo.languageGrd eq '3'}"></th:block>
</label>
<div class="col-3"></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:block th:each="code:${session.commonCode.get('UED')}">
<th:block th:if="${code.itemCd eq userInfo.educationGrd}" 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">학교명</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${userInfo.school}"></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="${userInfo.specialism}"></label>
</div>
<div class="card">
<div class="card-body text-center">

View File

@ -93,6 +93,11 @@
<th>교육일</th>
<th>담당기관</th>
<th>최종수정일</th>
<th>외국어</th>
<th>수준</th>
<th>학력</th>
<th>학교</th>
<th>전공</th>
</tr>
</thead>
<tbody class="table-group-divider">
@ -112,13 +117,22 @@
<td th:text="${police.userNm}"></td>
<td th:text="${police.birthDate}"></td>
<td th:text="${police.sex}"></td>
<td th:text="${police.eduName}"></td>
<td>
<th:block th:if="${police.eduEdate eq null}"></th:block>
<th:block th:unless="${police.eduEdate eq null}" th:text="|${police.eduSdate}~${police.eduEdate}|"></th:block>
</td>
<td th:text="${police.eduRa}"></td>
<td th:text="${police.eduName}"></td>
<td>
<th:block th:if="${police.eduEdate eq null}"></th:block>
<th:block th:unless="${police.eduEdate eq null}" th:text="|${police.eduSdate}~${police.eduEdate}|"></th:block>
</td>
<td th:text="${police.eduRa}"></td>
<td th:text="${#temporals.format(police.lastEduWrtDt, 'yyyy-MM-dd')}"></td>
<td th:text="${police.useLanguage}"></td>
<td>
<th:block th:if="${police.languageGrd eq '1'}"></th:block>
<th:block th:if="${police.languageGrd eq '2'}"></th:block>
<th:block th:if="${police.languageGrd eq '3'}"></th:block>
</td>
<td th:text="${police.educationGrd}"></td>
<td th:text="${police.school}"></td>
<td th:text="${police.specialism}"></td>
</tr>
</tbody>
</table>