This commit is contained in:
2026-02-05 10:42:13 +09:00
67 changed files with 8090 additions and 1860 deletions

View File

@@ -22,7 +22,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') {
@@ -252,7 +252,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 => {
@@ -286,7 +286,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 => {
@@ -405,7 +405,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({
@@ -490,7 +490,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({
@@ -518,7 +518,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') {
@@ -549,7 +549,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}`
@@ -671,7 +671,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({
@@ -772,7 +772,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 => {