From ed88ca4ca56582f19960279b9aea2bd7b7efebf2 Mon Sep 17 00:00:00 2001 From: hylee Date: Thu, 14 Mar 2024 15:39:05 +0900 Subject: [PATCH] =?UTF-8?q?=EC=82=AC=EC=9A=A9=EC=9E=90=20>=20=EA=B8=B0?= =?UTF-8?q?=EC=86=8C=EC=9C=A0=EC=98=88=20>=20=EA=B5=90=EC=9C=A1=EC=8B=A0?= =?UTF-8?q?=EC=B2=AD=20=EB=AA=A8=EB=B0=94=EC=9D=BC=20=EC=99=84=EB=A3=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../web/ve/aplct/sspnIdtmt/eduAplctList.jsp | 110 +++++++++++++++++- 1 file changed, 109 insertions(+), 1 deletion(-) diff --git a/src/main/webapp/WEB-INF/jsp/web/ve/aplct/sspnIdtmt/eduAplctList.jsp b/src/main/webapp/WEB-INF/jsp/web/ve/aplct/sspnIdtmt/eduAplctList.jsp index bb63dd3f..2d475a17 100644 --- a/src/main/webapp/WEB-INF/jsp/web/ve/aplct/sspnIdtmt/eduAplctList.jsp +++ b/src/main/webapp/WEB-INF/jsp/web/ve/aplct/sspnIdtmt/eduAplctList.jsp @@ -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(){ - + + + + +
+ +
    ');"> +
  • + 교육구분 + +
  • +
  • + 과정명 + + + + + + + + + + +
  • +
  • + 신청기간 + ~ +
  • +
  • + 교육일자 + +
  • +
  • + 신청자/정원 + / +
  • +
  • + 상태 + + + + + + + + + + +
  • +
  • + 교육신청 + +
  • +
+
+
+