Procházet zdrojové kódy

ST24PRJ-702 [결함][front] 네이버로그인이 본창으로 이동하여 로그인 실패하는 현상

card007 před 4 roky
rodič
revize
5881aa622d
1 změnil soubory, kde provedl 16 přidání a 12 odebrání
  1. 16 12
      src/main/webapp/ux/style24_link.js

+ 16 - 12
src/main/webapp/ux/style24_link.js

@@ -474,8 +474,10 @@ var cfnLoginNaver = function (requestGb, chkRememberMe) {
 	let popupX = (window.screen.width / 2) - (popupWidth / 2);
 	let popupY = (window.screen.height / 3) - (popupHeight / 3);
 	var frontGb = cfnCheckMobileDevice();
-	if ('P' === frontGb) {
+	if ('P' == frontGb) {
 		window.open(actionUrl, 'naverLogin', 'top=' + popupY + ',left=' + popupX + ',height=' + popupHeight + ',width=' + popupWidth + ', fullscreen=no,menubar=no,status=no,toolbar=no,titlebar=yes,location=no,scrollbars=yes', '');
+	} else if ('A' == frontGb) {
+		document.location.href = 'public://?link=' + actionUrl + '&requestGb=' + requestGb;
 	} else {
 		document.location.href = actionUrl + '&requestGb=' + requestGb;
 	}
@@ -1893,15 +1895,17 @@ function noneImg(noneSrc) {
  * @author : sshong
  */
 function cfnCheckMobileDevice() {
-    var mobileKeyWords = new Array('Android', 'iPhone', 'iPod', 'BlackBerry', 'Windows CE', 'SAMSUNG', 'LG', 'MOT', 'SonyEricsson');
-    var device = "";
-    for (var info in mobileKeyWords) {
-        if (navigator.userAgent.match(mobileKeyWords[info]) != null) {
-        	device = "M";
-        	return device;
-        } else{
-        	device = "P";
-        	return device;
-        }
-    }
+	var mobileKeyWords = new Array('Android', 'iPhone', 'iPod', 'BlackBerry', 'Windows CE', 'SAMSUNG', 'LG', 'MOT', 'SonyEricsson');
+	var device = "P";
+	for (var info in mobileKeyWords) {
+		if (navigator.userAgent.match(mobileKeyWords[info])) {
+			if (navigator.userAgent.match('istyle24')) {
+				device = "A";
+			} else {
+				device = "M";
+			}
+			return device;
+		}
+	}
+	return device;
 }