Add: Maestro AccoutType 0 = experience account

This commit is contained in:
2018-08-10 07:14:05 +09:00
parent be02c06f3d
commit ade28a3334
4 changed files with 38 additions and 5 deletions
+16 -1
View File
@@ -5,7 +5,7 @@ let isAvailableIDName = false;
let registeredMaestroIDName = "";
let registeredEmail = "";
let registeredPassword = "";
let registeredAccountType = -1;
let newMaestroIDName = "";
let newEmail = "";
@@ -34,6 +34,8 @@ function loadMaestroInfo(maestroID) {
registeredEmail = jsonData.email;
$("#email").val(registeredEmail);
registeredAccountType = jsonData.accountType;
},
(errorMessage, errorCode) => {
@@ -85,6 +87,11 @@ function checkMaestroIDName() {
}
function changeMaestroInfo() {
if(registeredAccountType === 0) {
showErrorMessage("체험 계정은 정보 수정이 불가능합니다.", "error");
return;
}
newMaestroIDName = $("#maestro_id").val();
if(newMaestroIDName.length === 0) {
showErrorMessage("변경할 아이디를 입력해 주세요.", "error");
@@ -130,6 +137,14 @@ function changeMaestroInfo() {
}
function checkPassword() {
if(registeredAccountType === 0) {
showErrorMessage("체험 계정은 암호 수정이 불가능합니다.", "error");
$('html, body').animate({
scrollTop: $("#message_box").offset().top + 'px'
}, 'fast');
return;
}
registeredPassword = $("#prev_password").val();
if(registeredPassword.length === 0) {
showErrorMessage("현재 암호를 입력해 주세요.", "error");