From 71291fabb565369e4bed544e1032e71eaa14bb47 Mon Sep 17 00:00:00 2001 From: ha-seungwon <12gktmddnjs@naver.com> Date: Thu, 17 Aug 2023 22:23:22 +0900 Subject: [PATCH] fix : record finish --- src/main/resources/static/js/record.js | 11 +++++------ src/main/resources/static/js/setting-account.js | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/main/resources/static/js/record.js b/src/main/resources/static/js/record.js index 18e87d9..9a1221c 100644 --- a/src/main/resources/static/js/record.js +++ b/src/main/resources/static/js/record.js @@ -150,16 +150,16 @@ async function fetchMyInfo() { currentScore.innerText = "현재 점수 : " + responseScoreInfoValue.currentScore + "점" expectedPassPercent.innerText = "합격 예상 :" + responseScoreInfoValue.expectedPassPercent.toFixed(2) + "%" - if(responseScoreInfoValue.expectedPassPercent == 0) { + if(responseScoreInfoValue.expectedPassPercent >= 95 ) { expectedGrade.innerText = "예측 결과 : 합격 확실" } - if(responseScoreInfoValue.expectedPassPercent ==1) { + if(responseScoreInfoValue.expectedPassPercent >= 85 && responseScoreInfoValue.expectedPassPercent < 95) { expectedGrade.innerText = "예측 결과 : 합격 유력" } - if(responseScoreInfoValue.expectedPassPercent == 2) { + if(responseScoreInfoValue.expectedPassPercent >= 80 && responseScoreInfoValue.expectedPassPercent < 85) { expectedGrade.innerText = "예측 결과 : 탈락 예상" } - if(responseScoreInfoValue.expectedPassPercent == 3) { + if(responseScoreInfoValue.expectedPassPercent < 80 ) { expectedGrade.innerText = "예측 결과 : 탈락 유력" } } @@ -170,8 +170,7 @@ async function monthlyRecordsGraph() { const yearScores = await fetch(currentDomain + "/api/score/year") const expectedScores = await fetch(currentDomain + "/api/score/expect") - let percentage = (100-((await expectedScores.json()).currentPercentile)) - + let percentage = (100-((await expectedScores.json()).currentPercentile)).toFixed(); const container = d3.select("#gauge-container"); const width = 256; const height = 214; diff --git a/src/main/resources/static/js/setting-account.js b/src/main/resources/static/js/setting-account.js index 2169e1a..3ae44e2 100644 --- a/src/main/resources/static/js/setting-account.js +++ b/src/main/resources/static/js/setting-account.js @@ -156,7 +156,7 @@ document.addEventListener("DOMContentLoaded", function () { console.log(passwordMachResult1,passwordMachResult2); // Call API to save password 여기서 저장 api 호출~~!! const restPassword = passwordInput.value - const resetApplicationTypeKey = dropdownText.textContent + let resetApplicationTypeKey = dropdownText.textContent if (resetApplicationTypeKey==="경찰직공무원(남)"){