<!DOCTYPE html>
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
<div class="modal-header">
  <h5 class="modal-title">인사시스템 경력정보</h5>
  <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
  <div class="card">
    <div class="card-body text-center">
      <table class="table table-hover">
        <thead>
        <tr>
          <th>경력구분</th>
          <th>임용구분</th>
          <th>근무지</th>
          <th>직급</th>
          <th>시작일</th>
          <th>종료일</th>
          <th>일수</th>
          <th>개월수</th>
        </tr>
        </thead>
        <tbody>
        <tr class="kwmsCareerTr" th:each="career:${careerList}">
          <input type="hidden" class="designationCd" th:value="${career.designationCd}">
          <input type="hidden" class="workPositionStr" th:value="${career.workPositionStr}">
          <input type="hidden" class="workTitle" th:value="${career.workTitle}">
          <input type="hidden" class="startDate" th:value="${career.startDate}">
          <input type="hidden" class="endDate" th:value="${career.endDate}">
          <input type="hidden" class="workDay" th:value="${career.workDay}">
          <input type="hidden" class="workMonth" th:value="${career.workMonth}">
          <input type="hidden" class="hordCd" th:value="${career.hordCd}">
          <td>
            <select class="form-select form-select-sm careerSelector">
              <option value="">선택</option>
              <th:block th:each="code:${crcList}">
                <option th:value="${code.itemCd}" th:text="${code.itemValue}"></option>
              </th:block>
            </select>
          </td>
          <td>
            <th:block th:each="code:${session.commonCode.get('DSN')}">
              <th:block th:if="${code.itemCd eq career.designationCd}" th:text="${code.itemValue}"></th:block>
            </th:block>
          </td>
          <td th:text="${career.workPositionStr}"></td>
          <th:block th:each="code:${session.commonCode.get('JT')}">
            <th:block th:if="${code.itemCd eq career.workTitle}">
              <td th:text="${code.itemValue}"></td>
            </th:block>
          </th:block>
          <td th:text="${#temporals.format(career.startDate, 'yyyy-MM-dd')}"></td>
          <td th:text="${#temporals.format(career.endDate, 'yyyy-MM-dd')}"></td>
          <td th:text="${career.workDay}"></td>
          <td th:text="${career.workMonth}"></td>
        </tr>
        </tbody>
      </table>
    </div>
  </div>
</div>
<div class="modal-footer justify-content-between">
  <button type="button" class="btn btn-primary" id="kwmsModalSelectBtn">선택</button>
  <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
</div>
</html>