From c26eca231f54194d338e9f688e348d09a3d5722d Mon Sep 17 00:00:00 2001 From: "DESKTOP-E9DJS27\\etribe" Date: Thu, 12 Jun 2025 15:00:28 +0900 Subject: [PATCH 1/2] =?UTF-8?q?=EA=B0=92=20=EC=B2=B4=ED=81=AC=EC=8B=9C=20s?= =?UTF-8?q?elect-group=20=EC=A0=95=EC=83=81=20=EA=B0=92=EB=8F=84=20?= =?UTF-8?q?=EC=A7=80=EC=9B=8C=EC=A7=80=EB=8F=84=EB=A1=9D=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/src/main/resources/static/ui/ajaxUtil.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/front/src/main/resources/static/ui/ajaxUtil.js b/front/src/main/resources/static/ui/ajaxUtil.js index 62fdd311..186fb618 100644 --- a/front/src/main/resources/static/ui/ajaxUtil.js +++ b/front/src/main/resources/static/ui/ajaxUtil.js @@ -159,6 +159,7 @@ var ajaxUtil = { const formElement = target.closest('form'); if (formElement.length > 0) { $(formElement).find('.component-input').removeClass('input-invalid'); + $(formElement).find('.select-group').removeClass('input-invalid'); $(formElement).find('.input-info').each(function () { $(this).remove(); }); @@ -191,7 +192,7 @@ var ajaxUtil = { } }); - if ($('.invalid-feedback').length === 0) { + if ($('.input-info').length === 0) { let fieldErrors = rstData.responseJSON != null ? rstData.responseJSON : null; if (fieldErrors != null && fieldErrors.length > 0) { ajaxUtil._alert(fieldErrors[0].defaultMessage, '유효성 체크'); From fb807cd479295e8a09b7aabcaef7adb67d6b4edd Mon Sep 17 00:00:00 2001 From: "DESKTOP-E9DJS27\\etribe" Date: Thu, 12 Jun 2025 15:23:58 +0900 Subject: [PATCH 2/2] =?UTF-8?q?alert=20=ED=83=80=EC=9D=B4=ED=8B=80=20?= =?UTF-8?q?=EC=A0=9C=EA=B1=B0,=20=20=20=20=20=EA=B3=B5=ED=86=B5=EC=BD=94?= =?UTF-8?q?=EB=93=9C=20=EC=B7=A8=EB=93=9D=EC=9A=A9=20enum=EC=B6=94?= =?UTF-8?q?=EA=B0=80.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../config/application/enums/UiCodeType.java | 12 ++++++++ .../src/main/resources/static/ui/ajaxUtil.js | 30 +++++++++++++------ 2 files changed, 33 insertions(+), 9 deletions(-) create mode 100644 core/src/main/java/app/module/core/config/application/enums/UiCodeType.java diff --git a/core/src/main/java/app/module/core/config/application/enums/UiCodeType.java b/core/src/main/java/app/module/core/config/application/enums/UiCodeType.java new file mode 100644 index 00000000..3f8c0714 --- /dev/null +++ b/core/src/main/java/app/module/core/config/application/enums/UiCodeType.java @@ -0,0 +1,12 @@ +package app.module.core.config.application.enums; + +import lombok.Getter; +import lombok.RequiredArgsConstructor; + +@Getter +@RequiredArgsConstructor +public enum UiCodeType { + REGION_MAIN("code.region.main"), + REGION_SUB("code.region.sub"); + private final String desc; +} diff --git a/front/src/main/resources/static/ui/ajaxUtil.js b/front/src/main/resources/static/ui/ajaxUtil.js index 186fb618..17805c1c 100644 --- a/front/src/main/resources/static/ui/ajaxUtil.js +++ b/front/src/main/resources/static/ui/ajaxUtil.js @@ -29,17 +29,29 @@ var ajaxUtil = { if (code == '400') { message = ajaxUtil._msg400; } - ajaxUtil._alert(message, '오류 안내'); + // ajaxUtil._alert(message, '오류 안내'); + ajaxUtil._alert(message, null); }, _alert : function (alertMessage, alertTitle, afterEvent) { - etUI.dialog.alert({ - title: alertTitle, - message: alertMessage, - type: "alert", - callback: function() { - console.log("alert callback"); - }, - }); + if(alertTitle){ + etUI.dialog.alert({ + title: alertTitle, + message: alertMessage, + type: "alert", + callback: function() { + console.log("alert callback"); + }, + }); + } else { + etUI.dialog.alert({ + message: alertMessage, + type: "alert", + callback: function() { + console.log("alert callback"); + }, + }); + } + }, _alertId : function (alertId, afterEvent) { ajaxUtil._alertMethod({