사용자 > 기소유예 > 교육신청 모바일 완료
This commit is contained in:
parent
897b73eb20
commit
ed88ca4ca5
@ -91,6 +91,57 @@ $(document).ready(function(){
|
||||
$applyButton.removeAttr('data-tooltip');
|
||||
}
|
||||
});
|
||||
// 상태값 확인 모바일
|
||||
$(".ddlnCdSttsM").each(function() {
|
||||
var $thisCell = $(this);
|
||||
var $applyButton = $thisCell.closest('ul').find(".aplctBtnM button");
|
||||
// var $aprvlCd = $thisCell.closest('tr').find(".aplctBtn input");
|
||||
// 텍스트가 비어있는지 확인
|
||||
if ($thisCell.text().trim() === "") {
|
||||
var $currentRow = $thisCell.closest('ul');
|
||||
|
||||
var strtPnttm = new Date($currentRow.find("li:eq(2)").find("span:eq(1)").text().split("~")[0].trim());
|
||||
var endPnttm = new Date($currentRow.find("li:eq(2)").find("span:eq(1)").text().split("~")[1].trim());
|
||||
var currentDate = new Date();
|
||||
// new Date에서 년, 월, 일만 생성
|
||||
currentDate = new Date(currentDate.getFullYear(), currentDate.getMonth(), currentDate.getDate());
|
||||
|
||||
// 시간, 분, 초 초기화
|
||||
strtPnttm.setHours(0, 0, 0, 0);
|
||||
endPnttm.setHours(0, 0, 0, 0);
|
||||
currentDate.setHours(0, 0, 0, 0);
|
||||
|
||||
var ddlnCdText = '';
|
||||
|
||||
if (currentDate < strtPnttm) {
|
||||
ddlnCdText = "접수전";
|
||||
} else if (currentDate >= strtPnttm && currentDate <= endPnttm) {
|
||||
ddlnCdText = "접수중";
|
||||
} else if (currentDate > endPnttm) {
|
||||
ddlnCdText = "접수종료";
|
||||
}
|
||||
|
||||
$thisCell.text(ddlnCdText);
|
||||
|
||||
}
|
||||
|
||||
console.log('$thisCell.text() : ', $thisCell.text());
|
||||
console.log('$thisCell.text().trim() !== "접수중" : ', $thisCell.text().trim() !== "접수중");
|
||||
// 텍스트가 "접수중"인지 확인
|
||||
//if ($thisCell.text().trim() !== "접수중" && $thisCell.text().trim() !== "취소") {
|
||||
if ($thisCell.text().trim() !== "접수중") {
|
||||
$applyButton.prop('disabled', true); // 버튼 비활성화
|
||||
}
|
||||
/* 24.01.22 웹접근성 검사를 위하여 disabled 사용제외 */
|
||||
if($applyButton.prop('disabled')){
|
||||
$applyButton.removeAttr('onclick');
|
||||
$applyButton.prop('disabled', false);
|
||||
$applyButton.css('background-color', '#888');
|
||||
/*24.01.23 웹접근성 검사를 위하여 title 추가*/
|
||||
$applyButton.attr('title','비활성화됨');
|
||||
$applyButton.removeAttr('data-tooltip');
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
// 달력 웹접근성
|
||||
@ -730,7 +781,64 @@ $(document).ready(function(){
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<!-- 모바일 시작 -->
|
||||
<!-- 모바일 시작 -->
|
||||
<!-- 모바일 시작 -->
|
||||
<!-- moblie table -->
|
||||
<div class="tb_list01_m class_m">
|
||||
<c:forEach var="list" items="${list}" varStatus="status">
|
||||
<ul onclick="fncGoDetail('<c:out value="${list.prcsAplctPrdOrd}"/>');">
|
||||
<li>
|
||||
<span>교육구분</span>
|
||||
<span><kc:code codeId="VEA001" code="${list.prcsDiv}"/></span>
|
||||
</li>
|
||||
<li>
|
||||
<span>과정명</span>
|
||||
<span>
|
||||
<c:choose>
|
||||
<c:when test="${not empty list.title}">
|
||||
<c:out value="${list.title}"/>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<c:out value="${list.prcsNm}"/>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</span>
|
||||
</li>
|
||||
<li>
|
||||
<span>신청기간</span>
|
||||
<span><c:out value="${list.strtPnttm}"/>~<c:out value="${list.endPnttm}"/></span>
|
||||
</li>
|
||||
<li>
|
||||
<span>교육일자</span>
|
||||
<span><c:out value="${list.eduStrtPnttm}"/></span>
|
||||
</li>
|
||||
<li>
|
||||
<span>신청자/정원</span>
|
||||
<span><c:out value="${list.nosCnt1}"/>/<c:out value="${list.nos}"/></span>
|
||||
</li>
|
||||
<li>
|
||||
<span>상태</span>
|
||||
<span class="ddlnCdSttsM">
|
||||
<c:choose>
|
||||
<c:when test="${not empty list.ddlnCd}">
|
||||
<kc:code codeId="VEA004" code="${list.ddlnCd}"/>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<kc:code codeId="VE0003" code="${list.aprvlCd}"/>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</span>
|
||||
</li>
|
||||
<li class="aplctBtnM">
|
||||
<span>교육신청</span>
|
||||
<button type="button" class="btnType04" data-info="<c:out value='${list.prcsAplctPrdOrd}'/>" data-tooltip="sub36_pop02"
|
||||
onclick="fncGoDetail('<c:out value="${list.prcsAplctPrdOrd}"/>');" title="팝업 열림">신청</button>
|
||||
</li>
|
||||
</ul>
|
||||
</c:forEach>
|
||||
</div>
|
||||
<!--// moblie table -->
|
||||
<div class="btn_wrap btn_layout01">
|
||||
<div class="btn_left">
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user