From 5d9dba7601c1c0f50c835afd1b805c9da41bd0cb Mon Sep 17 00:00:00 2001 From: wyu <kknd09321@nate.com> Date: 금, 07 1월 2022 13:38:58 +0900 Subject: [PATCH] 연락처 입력시 하이픈 X 조회할때만 하이픈 구분 (지역, 핸드폰 번호) --- src/main/webapp/scripts/app/user/userDetail.controller.js | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/src/main/webapp/scripts/app/user/userDetail.controller.js b/src/main/webapp/scripts/app/user/userDetail.controller.js index 227b6d8..2ef6651 100644 --- a/src/main/webapp/scripts/app/user/userDetail.controller.js +++ b/src/main/webapp/scripts/app/user/userDetail.controller.js @@ -28,7 +28,8 @@ issueHistoryVos : [], // �씠�뒋 湲곕줉 �젙蹂� issueHistoryDates : [], // �씠�뒋 湲곕줉 �젙蹂� �궇吏� myLevel : "", - myDepartments : [] + myDepartments : [], + phone : "" }; // 吏곸젒 �엯�젰�뿉�꽌 �궇吏� �꽑�깮�떆 �씠�뒋 湲곕줉 �젙蹂� 議고쉶 @@ -81,6 +82,11 @@ if (result.data.message.status === "success") { $scope.vm.myLevel = result.data.data.levelName; $scope.vm.myDepartments = result.data.data.departmentName; + // �쟾�솕踰덊샇 �븯�씠�뵂 異붽��븯�뿬 議고쉶 + $scope.vm.phone = $rootScope.user.phone; + let hyphen = $scope.vm.phone.trim(); + let phone = hyphen.replace(/(^02.{0}|^01.{1}|[0-9]{3})([0-9]+)([0-9]{4})/,"$1-$2-$3"); + $rootScope.user.phone = phone; } else { SweetAlert.swal($filter("translate")("users.failedToRetrieveIssueHistory"), result.data.message.message, "error"); // "�씠�뒋 湲곕줉 �젙蹂� 議고쉶 �떎�뙣" -- Gitblit v1.8.0