Normalize admin routes and docker config
This commit is contained in:
1 parent
bf86b1d1e7
commit
410b2b7b48
30 files changed
+467
-231
No files matched your search
+3
-3
@@ -102,7 +102,7 @@ userGrid
|
||||
document.getElementById('detailCard').style.display = 'block'
|
||||
|
||||
// 하단 사용자 로드
|
||||
// fetch(`/kngil/bbs/adm.php?action=user_list&member_id=${record.member_id}`)
|
||||
// fetch(`/admin/api/super?action=user_list&member_id=${record.member_id}`)
|
||||
// .then(res => res.json())
|
||||
// .then(d => {
|
||||
// if (d.status !== 'success') {
|
||||
@@ -243,7 +243,7 @@ function formatBizNo(value) {
|
||||
상단 회사 목록 로드
|
||||
---------------------------------------- */
|
||||
function loadCompanies() {
|
||||
fetch('/kngil/bbs/adm.php')
|
||||
fetch('/admin/api/super')
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (!json.records) return
|
||||
@@ -340,7 +340,7 @@ export function bindSaveButton() {
|
||||
return
|
||||
}
|
||||
|
||||
fetch('/kngil/bbs/adm.php?action=save', {
|
||||
fetch('/admin/api/super?action=save', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
|
||||
@@ -9,7 +9,7 @@ function destroyGrid(name) {
|
||||
}
|
||||
|
||||
function loadBaseCode(mainCd) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=base_code&main_cd=${mainCd}`)
|
||||
return fetch(`/admin/api/company?action=base_code&main_cd=${mainCd}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -144,7 +144,7 @@ export async function createUserGrid(boxId, options = {}) {
|
||||
}
|
||||
|
||||
function loadUsers() {
|
||||
fetch('/kngil/bbs/adm_comp.php')
|
||||
fetch('/admin/api/company')
|
||||
.then(res => res.text()) // 🔥 먼저 text로 확인
|
||||
.then(text => {
|
||||
try {
|
||||
@@ -168,7 +168,7 @@ export function loadUsersByMember(member_id) {
|
||||
return
|
||||
}
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php')
|
||||
fetch('/admin/api/company')
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
g.clear()
|
||||
@@ -198,7 +198,7 @@ export function setUserGridMode(mode = 'view') {
|
||||
|
||||
export function loadData({ loadSummary = true } = {}) {
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php')
|
||||
fetch('/admin/api/company')
|
||||
.then(res => res.json())
|
||||
.then(async d => {
|
||||
|
||||
@@ -323,7 +323,7 @@ document.getElementById('btnSave_comp')?.addEventListener('click', () => {
|
||||
console.log('INSERTS', inserts)
|
||||
console.log('UPDATES', updates)
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php', {
|
||||
fetch('/admin/api/company', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -408,7 +408,7 @@ document.getElementById('btnDelete')?.addEventListener('click', () => {
|
||||
w2confirm(`선택한 ${ids.length}명의 사용자를 삭제하시겠습니까?`)
|
||||
.yes(() => {
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php', {
|
||||
fetch('/admin/api/company', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -436,7 +436,7 @@ document.getElementById('btnDelete')?.addEventListener('click', () => {
|
||||
})
|
||||
|
||||
function loadTotalArea(memberId) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=total_area&member_id=${memberId}`)
|
||||
return fetch(`/admin/api/company?action=total_area&member_id=${memberId}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -467,7 +467,7 @@ function doSearch() {
|
||||
}
|
||||
// ⚠️ type === 'id' 는 DB로 안 보냄
|
||||
|
||||
fetch(`/kngil/bbs/adm_comp.php?action=list`
|
||||
fetch(`/admin/api/company?action=list`
|
||||
+ `&user_nm=${encodeURIComponent(p_user_nm)}`
|
||||
+ `&dept_nm=${encodeURIComponent(p_dept_nm)}`
|
||||
+ `&use_yn=${useYn}`
|
||||
|
||||
@@ -21,7 +21,7 @@ function destroyGrid(name) {
|
||||
}
|
||||
|
||||
function loadBaseCode(mainCd) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=base_code&main_cd=${mainCd}`)
|
||||
return fetch(`/admin/api/company?action=base_code&main_cd=${mainCd}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -251,7 +251,7 @@ export function loadUsersByMember(memberId) {
|
||||
return
|
||||
}
|
||||
|
||||
fetch(`/kngil/bbs/adm_comp.php?action=list&member_id=${memberId}`)
|
||||
fetch(`/admin/api/company?action=list&member_id=${memberId}`)
|
||||
.then(res => res.json())
|
||||
.then(d => {
|
||||
|
||||
@@ -285,7 +285,7 @@ export function setUserGridMode(mode = 'view') {
|
||||
}
|
||||
|
||||
export function loadData({ loadSummary = true } = {}) {
|
||||
fetch('/kngil/bbs/adm_comp.php?action=list')
|
||||
fetch('/admin/api/company?action=list')
|
||||
.then(res => res.json())
|
||||
.then(async d => {
|
||||
|
||||
@@ -404,7 +404,7 @@ document.getElementById('btnSave_comp')?.addEventListener('click', () => {
|
||||
console.log('INSERTS', inserts)
|
||||
console.log('UPDATES', updates)
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php', {
|
||||
fetch('/admin/api/company', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -489,7 +489,7 @@ document.getElementById('btnDelete')?.addEventListener('click', () => {
|
||||
w2confirm(`선택한 ${ids.length}명의 사용자를 삭제하시겠습니까?`)
|
||||
.yes(() => {
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php', {
|
||||
fetch('/admin/api/company', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -517,7 +517,7 @@ document.getElementById('btnDelete')?.addEventListener('click', () => {
|
||||
})
|
||||
|
||||
function loadTotalArea(memberId) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=total_area`)
|
||||
return fetch(`/admin/api/company?action=total_area`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -548,7 +548,7 @@ function doSearch() {
|
||||
}
|
||||
// ⚠️ type === 'id' 는 DB로 안 보냄
|
||||
|
||||
fetch(`/kngil/bbs/adm_comp.php?action=list`
|
||||
fetch(`/admin/api/company?action=list`
|
||||
+ `&user_nm=${encodeURIComponent(p_user_nm)}`
|
||||
+ `&dept_nm=${encodeURIComponent(p_dept_nm)}`
|
||||
+ `&use_yn=${useYn}`
|
||||
@@ -670,7 +670,7 @@ function openBulkCreatePopup(memberId) {
|
||||
|
||||
function runBulkCreate(memberId, csvUrl) {
|
||||
|
||||
fetch('/kngil/bbs/adm_comp.php', {
|
||||
fetch('/admin/api/company', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -771,7 +771,7 @@ function loadDataByMemberId(memberId) {
|
||||
return;
|
||||
}
|
||||
|
||||
fetch(`/kngil/bbs/adm_comp.php?action=list&member_id=${encodeURIComponent(memberId)}`)
|
||||
fetch(`/admin/api/company?action=list&member_id=${encodeURIComponent(memberId)}`)
|
||||
.then(res => res.json())
|
||||
.then(async d => {
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ function destroyGrid(name) {
|
||||
}
|
||||
|
||||
function loadBaseCode(mainCd) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=base_code&main_cd=${mainCd}`)
|
||||
return fetch(`/admin/api/company?action=base_code&main_cd=${mainCd}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -100,7 +100,7 @@ export function openfaqPopup() {
|
||||
|
||||
// 3. 브라우저 기본 확인창 사용 (가장 확실함)
|
||||
if (confirm(`선택한 ${ids.length}개의 상품을 삭제하시겠습니까?`)) {
|
||||
fetch('/kngil/bbs/adm_faq_popup_delete.php', {
|
||||
fetch('/admin/api/faq/delete', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ action: 'delete', ids: ids })
|
||||
@@ -169,7 +169,7 @@ export function openfaqPopup() {
|
||||
console.log('INSERTS', inserts)
|
||||
console.log('UPDATES', updates)
|
||||
|
||||
fetch('/kngil/bbs/adm_faq_popup_save.php', {
|
||||
fetch('/admin/api/faq/save', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -270,7 +270,7 @@ async function loadfaqData() {
|
||||
try {
|
||||
w2ui.faqGrid.lock('조회 중...', true);
|
||||
|
||||
const response = await fetch('/kngil/bbs/adm_faq_popup.php'); // PHP 파일 호출
|
||||
const response = await fetch('/admin/api/faq'); // PHP 파일 호출
|
||||
const data = await response.json();
|
||||
|
||||
w2ui.faqGrid.clear();
|
||||
|
||||
@@ -11,7 +11,7 @@ function destroyGrid(name) {
|
||||
}
|
||||
|
||||
function loadBaseCode(mainCd) {
|
||||
return fetch(`/kngil/bbs/adm_comp.php?action=base_code&main_cd=${mainCd}`)
|
||||
return fetch(`/admin/api/company?action=base_code&main_cd=${mainCd}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
if (json.status !== 'success') {
|
||||
@@ -101,7 +101,7 @@ export function openProductPopup() {
|
||||
|
||||
// 3. 브라우저 기본 확인창 사용 (가장 확실함)
|
||||
if (confirm(`선택한 ${ids.length}개의 상품을 삭제하시겠습니까?`)) {
|
||||
fetch('/kngil/bbs/adm_product_popup_delete.php', {
|
||||
fetch('/admin/api/product/delete', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ action: 'delete', ids: ids })
|
||||
@@ -171,7 +171,7 @@ export function openProductPopup() {
|
||||
console.log('INSERTS', inserts)
|
||||
console.log('UPDATES', updates)
|
||||
|
||||
fetch('/kngil/bbs/adm_product_popup_save.php', {
|
||||
fetch('/admin/api/product/save', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -265,7 +265,7 @@ async function loadProductData() {
|
||||
try {
|
||||
w2ui.productGrid.lock('조회 중...', true);
|
||||
|
||||
const response = await fetch('/kngil/bbs/adm_product_popup.php'); // PHP 파일 호출
|
||||
const response = await fetch('/admin/api/product'); // PHP 파일 호출
|
||||
const data = await response.json();
|
||||
|
||||
w2ui.productGrid.clear();
|
||||
|
||||
@@ -117,7 +117,7 @@ async function loadPurchaseHistoryData(memberId) {
|
||||
searchParams.append('fbuy_dt', '');
|
||||
searchParams.append('tbuy_dt', '');
|
||||
|
||||
const response = await fetch('/kngil/bbs/adm_purch_popup.php', {
|
||||
const response = await fetch('/admin/api/purchase-history', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
||||
body: searchParams
|
||||
|
||||
@@ -173,7 +173,7 @@ function addServiceFromProduct(p) {
|
||||
------------------------------------------------- */
|
||||
function loadExistingPurchase(memberId, buyDate) {
|
||||
|
||||
fetch(`/kngil/bbs/adm_service.php?member_id=${memberId}&buy_date=${buyDate}`)
|
||||
fetch(`/admin/api/service?member_id=${memberId}&buy_date=${buyDate}`)
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
|
||||
|
||||
@@ -288,7 +288,7 @@ function createProductList() {
|
||||
new w2grid({
|
||||
name: 'productList',
|
||||
box: '#productList',
|
||||
url: '/kngil/bbs/adm_product_popup.php',
|
||||
url: '/admin/api/product',
|
||||
columns: [
|
||||
{ field: 'itm_nm', text: '상품명', size: '120px' },
|
||||
{
|
||||
@@ -413,7 +413,7 @@ function deleteServiceImmediately(row) {
|
||||
sq_no: row.sq_no
|
||||
})
|
||||
|
||||
fetch('/kngil/bbs/adm_service.php', {
|
||||
fetch('/admin/api/service', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -446,7 +446,7 @@ function isServiceItem(r) {
|
||||
------------------------------------------------- */
|
||||
function loadExistingPurchase(memberId, buyDate) {
|
||||
|
||||
fetch('/kngil/bbs/adm_service.php', {
|
||||
fetch('/admin/api/service', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
@@ -606,7 +606,7 @@ function saveService(ctx) {
|
||||
_deleted: r._deleted || false
|
||||
}))
|
||||
|
||||
fetch('/kngil/bbs/adm_service.php', {
|
||||
fetch('/admin/api/service', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({
|
||||
|
||||
@@ -131,7 +131,7 @@ async function loadUseHistoryData(memberId = ''){
|
||||
searchParams.append('user_nm', sUnm);
|
||||
searchParams.append('dept_nm', sDnm);
|
||||
|
||||
const response = await fetch('/kngil/bbs/adm_use_history.php', {
|
||||
const response = await fetch('/admin/api/use-history', {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
||||
body: searchParams
|
||||
|
||||
+41
-1
@@ -4286,4 +4286,44 @@ return lottie;
|
||||
*/
|
||||
|
||||
var Swiper=function(){"use strict";function e(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function t(s,a){void 0===s&&(s={}),void 0===a&&(a={});const i=["__proto__","constructor","prototype"];Object.keys(a).filter((e=>i.indexOf(e)<0)).forEach((i=>{void 0===s[i]?s[i]=a[i]:e(a[i])&&e(s[i])&&Object.keys(a[i]).length>0&&t(s[i],a[i])}))}const s={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function a(){const e="undefined"!=typeof document?document:{};return t(e,s),e}const i={document:s,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function r(){const e="undefined"!=typeof window?window:{};return t(e,i),e}function n(e){return void 0===e&&(e=""),e.trim().split(" ").filter((e=>!!e.trim()))}function l(e,t){return void 0===t&&(t=0),setTimeout(e,t)}function o(){return Date.now()}function d(e,t){void 0===t&&(t="x");const s=r();let a,i,n;const l=function(e){const t=r();let s;return t.getComputedStyle&&(s=t.getComputedStyle(e,null)),!s&&e.currentStyle&&(s=e.currentStyle),s||(s=e.style),s}(e);return s.WebKitCSSMatrix?(i=l.transform||l.webkitTransform,i.split(",").length>6&&(i=i.split(", ").map((e=>e.replace(",","."))).join(", ")),n=new s.WebKitCSSMatrix("none"===i?"":i)):(n=l.MozTransform||l.OTransform||l.MsTransform||l.msTransform||l.transform||l.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),a=n.toString().split(",")),"x"===t&&(i=s.WebKitCSSMatrix?n.m41:16===a.length?parseFloat(a[12]):parseFloat(a[4])),"y"===t&&(i=s.WebKitCSSMatrix?n.m42:16===a.length?parseFloat(a[13]):parseFloat(a[5])),i||0}function c(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)}function p(){const e=Object(arguments.length<=0?void 0:arguments[0]),t=["__proto__","constructor","prototype"];for(let a=1;a<arguments.length;a+=1){const i=a<0||arguments.length<=a?void 0:arguments[a];if(null!=i&&(s=i,!("undefined"!=typeof window&&void 0!==window.HTMLElement?s instanceof HTMLElement:s&&(1===s.nodeType||11===s.nodeType)))){const s=Object.keys(Object(i)).filter((e=>t.indexOf(e)<0));for(let t=0,a=s.length;t<a;t+=1){const a=s[t],r=Object.getOwnPropertyDescriptor(i,a);void 0!==r&&r.enumerable&&(c(e[a])&&c(i[a])?i[a].__swiper__?e[a]=i[a]:p(e[a],i[a]):!c(e[a])&&c(i[a])?(e[a]={},i[a].__swiper__?e[a]=i[a]:p(e[a],i[a])):e[a]=i[a])}}}var s;return e}function u(e,t,s){e.style.setProperty(t,s)}function m(e){let{swiper:t,targetPosition:s,side:a}=e;const i=r(),n=-t.translate;let l,o=null;const d=t.params.speed;t.wrapperEl.style.scrollSnapType="none",i.cancelAnimationFrame(t.cssModeFrameID);const c=s>n?"next":"prev",p=(e,t)=>"next"===c&&e>=t||"prev"===c&&e<=t,u=()=>{l=(new Date).getTime(),null===o&&(o=l);const e=Math.max(Math.min((l-o)/d,1),0),r=.5-Math.cos(e*Math.PI)/2;let c=n+r*(s-n);if(p(c,s)&&(c=s),t.wrapperEl.scrollTo({[a]:c}),p(c,s))return t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.scrollSnapType="",setTimeout((()=>{t.wrapperEl.style.overflow="",t.wrapperEl.scrollTo({[a]:c})})),void i.cancelAnimationFrame(t.cssModeFrameID);t.cssModeFrameID=i.requestAnimationFrame(u)};u()}function h(e){return e.querySelector(".swiper-slide-transform")||e.shadowRoot&&e.shadowRoot.querySelector(".swiper-slide-transform")||e}function f(e,t){void 0===t&&(t="");const s=r(),a=[...e.children];return s.HTMLSlotElement&&e instanceof HTMLSlotElement&&a.push(...e.assignedElements()),t?a.filter((e=>e.matches(t))):a}function g(e){try{return void console.warn(e)}catch(e){}}function v(e,t){void 0===t&&(t=[]);const s=document.createElement(e);return s.classList.add(...Array.isArray(t)?t:n(t)),s}function w(e){const t=r(),s=a(),i=e.getBoundingClientRect(),n=s.body,l=e.clientTop||n.clientTop||0,o=e.clientLeft||n.clientLeft||0,d=e===t?t.scrollY:e.scrollTop,c=e===t?t.scrollX:e.scrollLeft;return{top:i.top+d-l,left:i.left+c-o}}function b(e,t){return r().getComputedStyle(e,null).getPropertyValue(t)}function y(e){let t,s=e;if(s){for(t=0;null!==(s=s.previousSibling);)1===s.nodeType&&(t+=1);return t}}function E(e,t){const s=[];let a=e.parentElement;for(;a;)t?a.matches(t)&&s.push(a):s.push(a),a=a.parentElement;rLine truncated
|
||||
//# sourceMappingURL=swiper-bundle.min.js.map
|
||||
//# sourceMappingURL=swiper-bundle.min.js.map
|
||||
// OIDC 통합 로그인 버튼 처리
|
||||
(function() {
|
||||
'use strict';
|
||||
|
||||
function openOidcLogin() {
|
||||
const width = 500;
|
||||
const height = 600;
|
||||
const left = (window.screen.width / 2) - (width / 2);
|
||||
const top = (window.screen.height / 2) - (height / 2);
|
||||
|
||||
window.open(
|
||||
'/kngil/auth/oidc-login.php',
|
||||
'oidc_login_popup',
|
||||
`width=${width},height=${height},left=${left},top=${top},scrollbars=yes`
|
||||
);
|
||||
}
|
||||
|
||||
function bindOidcButtons() {
|
||||
const buttons = document.querySelectorAll('[data-oidc-login]');
|
||||
if (!buttons.length) return;
|
||||
buttons.forEach((button) => {
|
||||
button.addEventListener('click', openOidcLogin);
|
||||
});
|
||||
}
|
||||
|
||||
window.openOidcLogin = openOidcLogin;
|
||||
window.login = openOidcLogin;
|
||||
|
||||
window.addEventListener('message', (event) => {
|
||||
if (event.data && event.data.type === 'OIDC_LOGIN_SUCCESS') {
|
||||
window.location.reload();
|
||||
}
|
||||
});
|
||||
|
||||
if (document.readyState === 'loading') {
|
||||
document.addEventListener('DOMContentLoaded', bindOidcButtons);
|
||||
} else {
|
||||
bindOidcButtons();
|
||||
}
|
||||
})();
|
||||
@@ -894,6 +894,10 @@ function join() {
|
||||
}
|
||||
|
||||
function login() {
|
||||
if (typeof window.openOidcLogin === "function") {
|
||||
window.openOidcLogin();
|
||||
return;
|
||||
}
|
||||
$(".popup_wrap").hide();
|
||||
//새로고침 없이 다시 팝업창 열었을때 자동 입력된 id, pw 제거
|
||||
$("#login_id").val("");
|
||||
|
||||
@@ -35,23 +35,6 @@ if (form) {
|
||||
})
|
||||
}
|
||||
|
||||
// OIDC 로그인 처리
|
||||
const btnOidc = document.getElementById('btn_oidc_login')
|
||||
if (btnOidc) {
|
||||
btnOidc.addEventListener('click', () => {
|
||||
const width = 500;
|
||||
const height = 600;
|
||||
const left = (window.screen.width / 2) - (width / 2);
|
||||
const top = (window.screen.height / 2) - (height / 2);
|
||||
|
||||
window.open(
|
||||
'/kngil/auth/oidc-login.php',
|
||||
'oidc_login_popup',
|
||||
`width=${width},height=${height},left=${left},top=${top},scrollbars=yes`
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
// 팝업으로부터의 메시지 수신 (로그인 성공 시 새로고침)
|
||||
window.addEventListener('message', (event) => {
|
||||
// 보안을 위해 실제 서비스에서는 event.origin을 체크하는 것이 좋습니다.
|
||||
|
||||
@@ -894,6 +894,10 @@ function join() {
|
||||
}
|
||||
|
||||
function login() {
|
||||
if (typeof window.openOidcLogin === "function") {
|
||||
window.openOidcLogin();
|
||||
return;
|
||||
}
|
||||
$(".popup_wrap").hide();
|
||||
//새로고침 없이 다시 팝업창 열었을때 자동 입력된 id, pw 제거
|
||||
$("#login_id").val("");
|
||||
|
||||
Reference in new issue
Block a user