fix(core,engine): OFFSET 순회 중 필터 컬럼 변경으로 인한 처리 누락 수정

Laravel chunk/each 는 OFFSET 기반이라, 콜백이 행의 필터 소속을 바꾸면
(필터 컬럼을 채우거나 매칭 행을 삭제하면) 다음 조회가 그만큼 앞으로 밀려
미처리 행을 조용히 건너뛴다. 250건/청크 100 이면 정확히 100건이 남는다.
코어·번들 확장 전수 조사로 확정한 6곳을 chunkById(키셋 순회)로 통일했다.

브라우저 검수(28축)에서 계획에 없던 결함 12건이 드러나 같은 사슬에서
수정했다. 이 중 layout_strategy=keep 무효화와 수정 감지 실패 시 "수정 없음"
오보는 사용자 작업 소실에 직결된다.

재발 방지로 audit 룰을 추가했고, 수정 6곳을 원복해 red 6건 / 복원 후 green
0건으로 판별력을 검증했다.
This commit is contained in:
HeuJung committed 2026-07-31 21:50:45 +09:00
1 parent 1866f0d566
commit 1eedbbdda1
55 files changed
+2764 -198

No files matched your search

@@ -30,6 +30,10 @@
### Fixed
- 모듈·플러그인·템플릿 관리 화면에서 '업데이트 확인'을 눌러 업데이트가 발견돼도 항상 "모두 최신 상태입니다"라고 안내되던 문제를 수정했습니다.
- 게시판·상품 카테고리 목록의 새로고침 버튼과 언어팩 재활성화 안내에서 번역되지 않은 내부 문구가 그대로 보이던 문제를 수정했습니다.
- 모듈·플러그인·템플릿 관리 화면의 목록 요약이 항상 "총 0개 중 1-0개 표시"로 나오고, 목록이 한 화면을 넘어도 다음 쪽으로 넘어갈 수 없던 문제를 수정했습니다.
- 업데이트 모달에서 수정된 화면 확인에 실패했는데도 "수정된 레이아웃이 없습니다"라고 표시되던 문제를 수정했습니다. 그대로 '모두 교체'를 진행하면 직접 고친 화면이 사라질 수 있어, 이제 확인하지 못했다는 안내와 함께 '수정 유지'를 권장합니다.
- 본인확인 코드 입력 화면에서 "남은 시도" 안내를 제거했습니다. 외부 인증 화면을 거쳐 돌아온 경우 실제보다 많은 횟수가 표시될 수 있어, 잘못된 숫자를 보여주는 대신 표시하지 않도록 했습니다. 시도 횟수 제한 자체는 종전대로 적용됩니다.
- 회원 목록에서 검색할 때 페이지를 넘길 때와 달리 표 위에 로딩 표시가 뜨지 않던 문제를 수정했습니다.
- 회원·역할·스케줄 목록에서 검색·정렬·페이지 이동 시 표 위에 걸어 둔 로딩 표시가 실제로는 동작하지 않던 문제를 수정했습니다. 다른 관리자 목록 화면과 같은 방식으로 표 본문에만 표시됩니다.
@@ -0,0 +1,139 @@
/**
* @file layout-translation-keys.test.ts
* @description 레이아웃이 참조하는 `$t:` 키가 템플릿 언어 파일에 실제로 정의돼 있는지 전수 검사
*
* Chrome MCP 정밀 점검에서 `common.refresh` / `common.activate` / `common.skip` 세 키가
* 정의되지 않아, 게시판·이커머스 목록의 새로고침 버튼과 언어팩 재활성화 모달에 키 원문이
* 그대로 노출됐다(D13). 화면에는 아무 오류도 뜨지 않고 문자열만 깨져 보인다.
*
* 특정 키를 손으로 열거하면 다음에 추가되는 키를 다시 놓친다. 그래서 이 테스트는
* **레이아웃에서 참조된 키를 스캔해** 그 전부가 ko/en 양쪽에 있는지 확인한다.
* 검사 대상에는 이 템플릿의 레이아웃뿐 아니라, 같은 관리자 화면에 얹히는 번들
* 모듈/플러그인 레이아웃도 포함한다 — 이들이 참조하는 `common.*` 도 결국 이 템플릿의
* 언어 파일로 해석되기 때문이다.
*/
import { describe, it, expect } from 'vitest';
import fs from 'fs';
import path from 'path';
import { fileURLToPath } from 'url';
const here = path.dirname(fileURLToPath(import.meta.url));
const templateDir = path.resolve(here, '../..');
/** artisan 파일을 기준으로 프로젝트 루트를 찾는다 (_bundled/활성 디렉토리 모두 호환) */
function findProjectRoot(startDir: string): string {
let dir = startDir;
while (dir !== path.dirname(dir)) {
if (fs.existsSync(path.join(dir, 'artisan'))) return dir;
dir = path.dirname(dir);
}
return path.resolve(startDir, '../..');
}
const rootDir = findProjectRoot(templateDir);
/** 디렉토리 하위의 모든 JSON 파일 경로를 수집한다 */
function collectJsonFiles(dir: string): string[] {
if (!fs.existsSync(dir)) return [];
return fs.readdirSync(dir, { withFileTypes: true }).flatMap((entry) => {
const full = path.join(dir, entry.name);
if (entry.isDirectory()) return collectJsonFiles(full);
return entry.isFile() && entry.name.endsWith('.json') ? [full] : [];
});
}
/** 확장 종류별 번들 레이아웃 디렉토리를 수집한다 */
function collectBundledLayoutDirs(kind: 'modules' | 'plugins'): string[] {
const base = path.join(rootDir, kind, '_bundled');
if (!fs.existsSync(base)) return [];
return fs
.readdirSync(base, { withFileTypes: true })
.filter((e) => e.isDirectory())
.map((e) => path.join(base, e.name, 'resources', 'layouts'))
.filter((p) => fs.existsSync(p));
}
const LAYOUT_DIRS = [
path.join(templateDir, 'layouts'),
...collectBundledLayoutDirs('modules'),
...collectBundledLayoutDirs('plugins'),
];
/** `$t:<namespace>.<key>` 참조를 수집한다 (namespace → key 집합) */
function collectTranslationRefs(): Map<string, Map<string, Set<string>>> {
const refs = new Map<string, Map<string, Set<string>>>();
const pattern = /\$t:([a-zA-Z0-9_]+)\.([a-zA-Z0-9_.]+)/g;
for (const dir of LAYOUT_DIRS) {
for (const file of collectJsonFiles(dir)) {
const raw = fs.readFileSync(file, 'utf8');
for (const match of raw.matchAll(pattern)) {
const [, namespace, key] = match;
// 표현식 끝의 마침표는 키의 일부가 아니다
const normalized = key.replace(/\.$/, '');
if (!refs.has(namespace)) refs.set(namespace, new Map());
const byKey = refs.get(namespace)!;
if (!byKey.has(normalized)) byKey.set(normalized, new Set());
byKey.get(normalized)!.add(path.relative(rootDir, file));
}
}
}
return refs;
}
/** 로케일별 언어 파일을 읽는다 (없으면 null) */
function loadLangFile(locale: string, namespace: string): Record<string, unknown> | null {
const file = path.join(templateDir, 'lang', 'partial', locale, `${namespace}.json`);
if (!fs.existsSync(file)) return null;
return JSON.parse(fs.readFileSync(file, 'utf8'));
}
/** 점 표기 경로가 객체에 존재하는지 확인한다 */
function hasPath(source: Record<string, unknown>, dotted: string): boolean {
return dotted.split('.').reduce<unknown>(
(acc, segment) =>
acc && typeof acc === 'object' ? (acc as Record<string, unknown>)[segment] : undefined,
source
) !== undefined;
}
const REFS = collectTranslationRefs();
const LOCALES = ['ko', 'en'];
describe('레이아웃 $t: 키 정의 검사', () => {
it('검사 대상 레이아웃과 참조 키가 실제로 수집되어야 함 (모집단 도달 확인)', () => {
expect(LAYOUT_DIRS.length).toBeGreaterThan(1);
expect(REFS.get('common')?.size ?? 0).toBeGreaterThan(10);
});
it.each(LOCALES)('common 네임스페이스의 모든 참조 키가 %s 에 정의되어야 함', (locale) => {
const defined = loadLangFile(locale, 'common');
expect(defined, `lang/partial/${locale}/common.json 이 없습니다`).not.toBeNull();
const missing: string[] = [];
for (const [key, files] of REFS.get('common') ?? []) {
if (!hasPath(defined!, key)) {
missing.push(`common.${key} (참조: ${[...files].slice(0, 3).join(', ')})`);
}
}
expect(
missing,
`정의되지 않은 키가 화면에 원문으로 노출됩니다:\n - ${missing.join('\n - ')}`
).toEqual([]);
});
it('D13 회귀: 새로고침·활성화·건너뛰기 키가 ko/en 양쪽에 있어야 함', () => {
for (const locale of LOCALES) {
const defined = loadLangFile(locale, 'common')!;
for (const key of ['refresh', 'activate', 'skip']) {
expect(hasPath(defined, key), `${locale}/common.json 에 ${key} 누락`).toBe(true);
}
}
});
});
@@ -0,0 +1,99 @@
/**
* @file extension-list-contract.test.tsx
* @description 확장(모듈/플러그인/템플릿) 목록·업데이트 모달의 API 계약 회귀 테스트
*
* Chrome MCP 정밀 점검에서 실측된 결함 3건을 레이아웃 JSON 수준에서 고정한다.
*
* 1) check-updates 응답 필드는 `updated_count` 인데 레이아웃이 `update_count` 를 읽어
* 업데이트가 감지돼도 항상 "모든 X가 최신 상태입니다" 토스트가 떴다.
* 2) 목록 페이지네이션이 `data.total` / `data.current_page` 를 읽는데 실제 응답은
* `data.pagination.*` 이라 "총 0개 중 1-0개 표시" 로 고정 표기됐다.
* 3) check-modified-layouts 호출에 onError 가 없어, 네트워크 실패 시 모달이
* "수정된 레이아웃이 없습니다" 라고 단언 → '모두 교체' 진행 시 수정 소실.
*/
import { describe, it, expect } from 'vitest';
import moduleList from '../../layouts/admin_module_list.json';
import pluginList from '../../layouts/admin_plugin_list.json';
import templateList from '../../layouts/admin_template_list.json';
import tabAdmin from '../../layouts/partials/admin_template_list/_tab_admin.json';
import tabUser from '../../layouts/partials/admin_template_list/_tab_user.json';
import moduleModal from '../../layouts/partials/admin_module_list/_modal_update.json';
import pluginModal from '../../layouts/partials/admin_plugin_list/_modal_update.json';
import templateModal from '../../layouts/partials/admin_template_list/_modal_update.json';
const LIST_LAYOUTS: Array<[string, unknown]> = [
['admin_module_list', moduleList],
['admin_plugin_list', pluginList],
['admin_template_list', templateList],
];
const PAGINATION_LAYOUTS: Array<[string, unknown, string]> = [
['admin_module_list', moduleList, 'modules'],
['admin_plugin_list', pluginList, 'plugins'],
['_tab_admin', tabAdmin, 'templates'],
['_tab_user', tabUser, 'templates'],
];
const MODALS: Array<[string, unknown, string]> = [
['module', moduleModal, 'Module'],
['plugin', pluginModal, 'Plugin'],
['template', templateModal, 'Template'],
];
const CHECK_SOURCES: Array<[string, unknown, string]> = [
['admin_module_list', moduleList, 'Module'],
['admin_plugin_list', pluginList, 'Plugin'],
['_tab_admin', tabAdmin, 'Template'],
['_tab_user', tabUser, 'Template'],
];
describe('확장 목록 레이아웃 — API 계약', () => {
it.each(LIST_LAYOUTS)('%s: check-updates 는 updated_count 를 읽어야 함', (_name, layout) => {
const json = JSON.stringify(layout);
expect(json).toContain('response.data?.updated_count');
// 잘못된 필드명이 남아있으면 토스트가 영구히 "최신 상태" 로 고정된다
expect(json).not.toContain('response.data?.update_count');
expect(json).not.toContain('response.data.update_count');
});
it.each(PAGINATION_LAYOUTS)('%s: 페이지네이션은 data.pagination.* 경로여야 함', (_name, layout, ds) => {
const json = JSON.stringify(layout);
for (const key of ['total', 'current_page', 'last_page', 'per_page']) {
expect(json).not.toContain(`${ds}?.data?.${key}`);
}
expect(json).toContain(`${ds}?.data?.pagination?.total`);
});
it.each(CHECK_SOURCES)('%s: check-modified-layouts 호출에 onError 가 있어야 함', (_name, layout, kind) => {
const found: any[] = [];
const walk = (node: any) => {
if (Array.isArray(node)) { node.forEach(walk); return; }
if (!node || typeof node !== 'object') return;
if (node.handler === 'apiCall' && typeof node.target === 'string'
&& node.target.includes('/check-modified-layouts')) {
found.push(node);
}
Object.values(node).forEach(walk);
};
walk(layout);
expect(found.length).toBeGreaterThan(0);
for (const call of found) {
expect(Array.isArray(call.onError)).toBe(true);
expect(JSON.stringify(call.onError)).toContain(`modified${kind}LayoutsCheckFailed`);
// 성공 시에는 플래그를 반드시 해제해야 재조회가 경고에 갇히지 않는다
expect(JSON.stringify(call.onSuccess)).toContain(`modified${kind}LayoutsCheckFailed`);
}
});
it.each(MODALS)('%s 업데이트 모달: 확인 실패 분기가 있고 "수정 없음" 단언을 가로막아야 함', (_name, modal, kind) => {
const json = JSON.stringify(modal);
expect(json).toContain('modified_layouts_check_failed');
expect(json).toContain(`_global.modified${kind}LayoutsCheckFailed`);
// "수정된 레이아웃이 없습니다" 는 확인이 성공했을 때만 표시되어야 한다
expect(json).toContain(
`{{!_global.hasModified${kind}Layouts && !_global.modified${kind}LayoutsCheckFailed}}`
);
});
});
@@ -723,6 +723,7 @@
"layout_strategy_keep_desc": "Preserve user-modified layouts.",
"modified_layouts_warning": "{{count}} modified layout(s) exist. Choosing 'Overwrite All' will discard the modifications.",
"no_modified_layouts": "No modified layouts.",
"modified_layouts_check_failed": "Could not check for modified layouts. Check your connection and retry, or choose 'Keep changes' to be safe.",
"modified_layouts_list_title": "Modified layouts to keep ({{count}})",
"modified_layouts_keep_notice": "These layouts will retain their current content after the update."
},
@@ -928,6 +929,7 @@
"layout_strategy_keep_desc": "Preserve user-modified layouts.",
"modified_layouts_warning": "{{count}} modified layout(s) exist. Choosing 'Overwrite All' will discard the modifications.",
"no_modified_layouts": "No modified layouts.",
"modified_layouts_check_failed": "Could not check for modified layouts. Check your connection and retry, or choose 'Keep changes' to be safe.",
"modified_layouts_list_title": "Modified layouts to keep ({{count}})",
"modified_layouts_keep_notice": "These layouts will retain their current content after the update."
},
@@ -2120,6 +2122,7 @@
"layout_strategy_keep_desc": "Keep user-modified layouts.",
"modified_layouts_warning": "{{count}} layout(s) have been modified. Selecting 'Overwrite All' will discard modifications.",
"no_modified_layouts": "No modified layouts found.",
"modified_layouts_check_failed": "Could not check for modified layouts. Check your connection and retry, or choose 'Keep changes' to be safe.",
"modified_layouts_list_title": "Modified layouts to be preserved ({{count}})",
"modified_layouts_keep_notice": "These layouts will retain their current content after the update.",
"activate_warning_title": "Template Activation Warning",
@@ -76,5 +76,8 @@
"scope_type_role_desc": "Only resources from users with the same role",
"multilingual": {
"add_language": "Add Language"
}
}
},
"refresh": "Refresh",
"activate": "Activate",
"skip": "Skip"
}
@@ -727,6 +727,7 @@
"layout_strategy_keep_desc": "사용자가 수정한 레이아웃을 유지합니다.",
"modified_layouts_warning": "수정된 레이아웃이 {{count}}개 있습니다. '모두 교체'를 선택하면 수정 내용이 삭제됩니다.",
"no_modified_layouts": "수정된 레이아웃이 없습니다.",
"modified_layouts_check_failed": "수정 여부를 확인하지 못했습니다. 네트워크 상태를 확인한 뒤 다시 시도하거나, 안전하게 '수정 유지'를 선택하세요.",
"modified_layouts_list_title": "유지될 수정 레이아웃 ({{count}}개)",
"modified_layouts_keep_notice": "위 레이아웃은 업데이트 후에도 현재 내용이 유지됩니다."
},
@@ -932,6 +933,7 @@
"layout_strategy_keep_desc": "사용자가 수정한 레이아웃을 유지합니다.",
"modified_layouts_warning": "수정된 레이아웃이 {{count}}개 있습니다. '모두 교체'를 선택하면 수정 내용이 삭제됩니다.",
"no_modified_layouts": "수정된 레이아웃이 없습니다.",
"modified_layouts_check_failed": "수정 여부를 확인하지 못했습니다. 네트워크 상태를 확인한 뒤 다시 시도하거나, 안전하게 '수정 유지'를 선택하세요.",
"modified_layouts_list_title": "유지될 수정 레이아웃 ({{count}}개)",
"modified_layouts_keep_notice": "위 레이아웃은 업데이트 후에도 현재 내용이 유지됩니다."
},
@@ -2124,6 +2126,7 @@
"layout_strategy_keep_desc": "사용자가 수정한 레이아웃을 유지합니다.",
"modified_layouts_warning": "수정된 레이아웃이 {{count}}개 있습니다. '모두 교체'를 선택하면 수정 내용이 삭제됩니다.",
"no_modified_layouts": "수정된 레이아웃이 없습니다.",
"modified_layouts_check_failed": "수정 여부를 확인하지 못했습니다. 네트워크 상태를 확인한 뒤 다시 시도하거나, 안전하게 '수정 유지'를 선택하세요.",
"modified_layouts_list_title": "유지될 수정 레이아웃 ({{count}}개)",
"modified_layouts_keep_notice": "위 레이아웃은 업데이트 후에도 현재 내용이 유지됩니다.",
"activate_warning_title": "템플릿 활성화 경고",
@@ -76,5 +76,8 @@
"scope_type_role_desc": "같은 역할의 사용자 리소스만",
"multilingual": {
"add_language": "언어 추가"
}
}
},
"refresh": "새로고침",
"activate": "활성화",
"skip": "건너뛰기"
}
@@ -49,10 +49,12 @@
"fallback": {
"data": {
"data": [],
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
"pagination": {
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
}
}
}
},
@@ -167,7 +169,7 @@
"handler": "toast",
"params": {
"type": "success",
"message": "{{response.data?.update_count > 0 ? '$t:admin.modules.check_updates_success|count=' + response.data.update_count : '$t:admin.modules.check_updates_no_updates'}}"
"message": "{{response.data?.updated_count > 0 ? '$t:admin.modules.check_updates_success|count=' + response.data.updated_count : '$t:admin.modules.check_updates_no_updates'}}"
}
}
],
@@ -640,8 +642,8 @@
"pagination": true,
"alwaysShowPagination": true,
"serverSidePagination": true,
"serverCurrentPage": "{{modules?.data?.current_page ?? 1}}",
"serverTotalPages": "{{modules?.data?.last_page ?? 1}}",
"serverCurrentPage": "{{modules?.data?.pagination?.current_page ?? 1}}",
"serverTotalPages": "{{modules?.data?.pagination?.last_page ?? 1}}",
"cardClassName": "border border-gray-200 dark:border-gray-700 rounded-lg p-4 relative",
"cardColumns": [
{
@@ -1010,7 +1012,8 @@
"moduleLayoutStrategy": "overwrite",
"hasModifiedModuleLayouts": false,
"modifiedModuleLayoutsCount": 0,
"modifiedModuleLayouts": []
"modifiedModuleLayouts": [],
"modifiedModuleLayoutsCheckFailed": false
}
},
{
@@ -1027,7 +1030,17 @@
"target": "global",
"hasModifiedModuleLayouts": "{{response.data?.has_modified_layouts ?? false}}",
"modifiedModuleLayoutsCount": "{{response.data?.modified_count ?? 0}}",
"modifiedModuleLayouts": "{{response.data?.modified_layouts ?? []}}"
"modifiedModuleLayouts": "{{response.data?.modified_layouts ?? []}}",
"modifiedModuleLayoutsCheckFailed": false
}
}
],
"onError": [
{
"handler": "setState",
"params": {
"target": "global",
"modifiedModuleLayoutsCheckFailed": true
}
}
]
@@ -1397,7 +1410,7 @@
{
"type": "basic",
"name": "Span",
"text": "$t:admin.modules.pagination_info|total={{modules?.data?.total ?? 0}}|from={{((modules?.data?.current_page ?? 1) - 1) * (modules?.data?.per_page ?? 12) + 1}}|to={{Math.min((modules?.data?.current_page ?? 1) * (modules?.data?.per_page ?? 12), modules?.data?.total ?? 0)}}"
"text": "$t:admin.modules.pagination_info|total={{modules?.data?.pagination?.total ?? 0}}|from={{((modules?.data?.pagination?.current_page ?? 1) - 1) * (modules?.data?.pagination?.per_page ?? 12) + 1}}|to={{Math.min((modules?.data?.pagination?.current_page ?? 1) * (modules?.data?.pagination?.per_page ?? 12), modules?.data?.pagination?.total ?? 0)}}"
}
]
}
@@ -49,10 +49,12 @@
"fallback": {
"data": {
"data": [],
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
"pagination": {
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
}
}
}
},
@@ -167,7 +169,7 @@
"handler": "toast",
"params": {
"type": "success",
"message": "{{response.data?.update_count > 0 ? '$t:admin.plugins.check_updates_success|count=' + response.data.update_count : '$t:admin.plugins.check_updates_no_updates'}}"
"message": "{{response.data?.updated_count > 0 ? '$t:admin.plugins.check_updates_success|count=' + response.data.updated_count : '$t:admin.plugins.check_updates_no_updates'}}"
}
}
],
@@ -649,8 +651,8 @@
"pagination": true,
"alwaysShowPagination": true,
"serverSidePagination": true,
"serverCurrentPage": "{{plugins?.data?.current_page ?? 1}}",
"serverTotalPages": "{{plugins?.data?.last_page ?? 1}}",
"serverCurrentPage": "{{plugins?.data?.pagination?.current_page ?? 1}}",
"serverTotalPages": "{{plugins?.data?.pagination?.last_page ?? 1}}",
"cardClassName": "border border-gray-200 dark:border-gray-700 rounded-lg p-4 relative",
"cardColumns": [
{
@@ -1022,7 +1024,8 @@
"pluginLayoutStrategy": "overwrite",
"hasModifiedPluginLayouts": false,
"modifiedPluginLayoutsCount": 0,
"modifiedPluginLayouts": []
"modifiedPluginLayouts": [],
"modifiedPluginLayoutsCheckFailed": false
}
},
{
@@ -1039,7 +1042,17 @@
"target": "global",
"hasModifiedPluginLayouts": "{{response.data?.has_modified_layouts ?? false}}",
"modifiedPluginLayoutsCount": "{{response.data?.modified_count ?? 0}}",
"modifiedPluginLayouts": "{{response.data?.modified_layouts ?? []}}"
"modifiedPluginLayouts": "{{response.data?.modified_layouts ?? []}}",
"modifiedPluginLayoutsCheckFailed": false
}
}
],
"onError": [
{
"handler": "setState",
"params": {
"target": "global",
"modifiedPluginLayoutsCheckFailed": true
}
}
]
@@ -1422,7 +1435,7 @@
{
"type": "basic",
"name": "Span",
"text": "$t:admin.plugins.pagination_info|total={{plugins?.data?.total ?? 0}}|from={{((plugins?.data?.current_page ?? 1) - 1) * (plugins?.data?.per_page ?? 12) + 1}}|to={{Math.min((plugins?.data?.current_page ?? 1) * (plugins?.data?.per_page ?? 12), plugins?.data?.total ?? 0)}}"
"text": "$t:admin.plugins.pagination_info|total={{plugins?.data?.pagination?.total ?? 0}}|from={{((plugins?.data?.pagination?.current_page ?? 1) - 1) * (plugins?.data?.pagination?.per_page ?? 12) + 1}}|to={{Math.min((plugins?.data?.pagination?.current_page ?? 1) * (plugins?.data?.pagination?.per_page ?? 12), plugins?.data?.pagination?.total ?? 0)}}"
}
]
}
@@ -52,10 +52,12 @@
"fallback": {
"data": {
"data": [],
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
"pagination": {
"current_page": 1,
"last_page": 1,
"per_page": 12,
"total": 0
}
}
}
},
@@ -170,7 +172,7 @@
"handler": "toast",
"params": {
"type": "success",
"message": "{{response.data?.update_count > 0 ? '$t:admin.templates.check_updates_success|count=' + response.data.update_count : '$t:admin.templates.check_updates_no_updates'}}"
"message": "{{response.data?.updated_count > 0 ? '$t:admin.templates.check_updates_success|count=' + response.data.updated_count : '$t:admin.templates.check_updates_no_updates'}}"
}
}
],
@@ -440,7 +440,17 @@
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedModuleLayouts}}",
"if": "{{_global.modifiedModuleLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-700 rounded text-xs text-red-700 dark:text-red-400",
"role": "alert"
},
"text": "$t:admin.modules.modals.modified_layouts_check_failed"
},
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedModuleLayouts && !_global.modifiedModuleLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-green-50 dark:bg-green-900/30 border border-green-200 dark:border-green-700 rounded text-xs text-green-700 dark:text-green-400"
},
@@ -440,7 +440,17 @@
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedPluginLayouts}}",
"if": "{{_global.modifiedPluginLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-700 rounded text-xs text-red-700 dark:text-red-400",
"role": "alert"
},
"text": "$t:admin.plugins.modals.modified_layouts_check_failed"
},
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedPluginLayouts && !_global.modifiedPluginLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-green-50 dark:bg-green-900/30 border border-green-200 dark:border-green-700 rounded text-xs text-green-700 dark:text-green-400"
},
@@ -440,7 +440,17 @@
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedTemplateLayouts}}",
"if": "{{_global.modifiedTemplateLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-700 rounded text-xs text-red-700 dark:text-red-400",
"role": "alert"
},
"text": "$t:admin.templates.modals.modified_layouts_check_failed"
},
{
"type": "basic",
"name": "Div",
"if": "{{!_global.hasModifiedTemplateLayouts && !_global.modifiedTemplateLayoutsCheckFailed}}",
"props": {
"className": "mb-2 p-2 bg-green-50 dark:bg-green-900/30 border border-green-200 dark:border-green-700 rounded text-xs text-green-700 dark:text-green-400"
},
@@ -104,8 +104,8 @@
"pagination": true,
"alwaysShowPagination": true,
"serverSidePagination": true,
"serverCurrentPage": "{{templates?.data?.current_page ?? 1}}",
"serverTotalPages": "{{templates?.data?.last_page ?? 1}}",
"serverCurrentPage": "{{templates?.data?.pagination?.current_page ?? 1}}",
"serverTotalPages": "{{templates?.data?.pagination?.last_page ?? 1}}",
"cardClassName": "border border-gray-200 dark:border-gray-700 rounded-lg p-4 relative",
"cardColumns": [
{
@@ -122,7 +122,7 @@
"type": "basic",
"name": "Div",
"props": {
"className": "flex-shrink-0 w-12 h-12 bg-gray-100 dark:bg-gray-700 rounded-lg flex items-center justify-center"
"className": "flex-shrink-0 text-5xl bg-gray-100 dark:bg-gray-700 rounded-lg flex items-center justify-center"
},
"children": [
{
@@ -272,7 +272,7 @@
"name": "Icon",
"props": {
"name": "exclamation-triangle",
"className": "w-3 h-3"
"className": "text-xs"
}
},
{
@@ -346,7 +346,7 @@
"if": "{{dep.type === 'module'}}",
"props": {
"name": "cube",
"className": "w-3.5 h-3.5 text-gray-500 dark:text-gray-400"
"className": "text-sm text-gray-500 dark:text-gray-400"
}
},
{
@@ -355,7 +355,7 @@
"if": "{{dep.type === 'plugin'}}",
"props": {
"name": "puzzle-piece",
"className": "w-3.5 h-3.5 text-gray-500 dark:text-gray-400"
"className": "text-sm text-gray-500 dark:text-gray-400"
}
},
{
@@ -428,7 +428,7 @@
"name": "Icon",
"props": {
"name": "code",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -470,7 +470,7 @@
"name": "Icon",
"props": {
"name": "edit",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -520,7 +520,7 @@
"name": "Icon",
"props": {
"name": "download",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -554,7 +554,8 @@
"templateLayoutStrategy": "overwrite",
"hasModifiedTemplateLayouts": false,
"modifiedTemplateLayoutsCount": 0,
"modifiedTemplateLayouts": []
"modifiedTemplateLayouts": [],
"modifiedTemplateLayoutsCheckFailed": false
}
},
{
@@ -571,7 +572,17 @@
"target": "global",
"hasModifiedTemplateLayouts": "{{response.data?.has_modified_layouts ?? false}}",
"modifiedTemplateLayoutsCount": "{{response.data?.modified_count ?? 0}}",
"modifiedTemplateLayouts": "{{response.data?.modified_layouts ?? []}}"
"modifiedTemplateLayouts": "{{response.data?.modified_layouts ?? []}}",
"modifiedTemplateLayoutsCheckFailed": false
}
}
],
"onError": [
{
"handler": "setState",
"params": {
"target": "global",
"modifiedTemplateLayoutsCheckFailed": true
}
}
]
@@ -627,7 +638,7 @@
"name": "Icon",
"props": {
"name": "refresh",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -872,7 +883,7 @@
{
"type": "basic",
"name": "Span",
"text": "$t:admin.templates.pagination_info|total={{templates?.data?.total ?? 0}}|from={{((templates?.data?.current_page ?? 1) - 1) * (templates?.data?.per_page ?? 12) + 1}}|to={{Math.min((templates?.data?.current_page ?? 1) * (templates?.data?.per_page ?? 12), templates?.data?.total ?? 0)}}"
"text": "$t:admin.templates.pagination_info|total={{templates?.data?.pagination?.total ?? 0}}|from={{((templates?.data?.pagination?.current_page ?? 1) - 1) * (templates?.data?.pagination?.per_page ?? 12) + 1}}|to={{Math.min((templates?.data?.pagination?.current_page ?? 1) * (templates?.data?.pagination?.per_page ?? 12), templates?.data?.pagination?.total ?? 0)}}"
}
]
}
@@ -898,7 +909,7 @@
"name": "Icon",
"props": {
"name": "info-circle",
"className": "w-5 h-5 text-blue-600 dark:text-blue-400 flex-shrink-0 mt-0.5"
"className": "text-xl text-blue-600 dark:text-blue-400 flex-shrink-0 mt-0.5"
}
},
{
@@ -104,8 +104,8 @@
"pagination": true,
"alwaysShowPagination": true,
"serverSidePagination": true,
"serverCurrentPage": "{{templates?.data?.current_page ?? 1}}",
"serverTotalPages": "{{templates?.data?.last_page ?? 1}}",
"serverCurrentPage": "{{templates?.data?.pagination?.current_page ?? 1}}",
"serverTotalPages": "{{templates?.data?.pagination?.last_page ?? 1}}",
"cardClassName": "border border-gray-200 dark:border-gray-700 rounded-lg p-4 relative",
"cardColumns": [
{
@@ -122,7 +122,7 @@
"type": "basic",
"name": "Div",
"props": {
"className": "flex-shrink-0 w-12 h-12 bg-gray-100 dark:bg-gray-700 rounded-lg flex items-center justify-center"
"className": "flex-shrink-0 text-5xl bg-gray-100 dark:bg-gray-700 rounded-lg flex items-center justify-center"
},
"children": [
{
@@ -272,7 +272,7 @@
"name": "Icon",
"props": {
"name": "exclamation-triangle",
"className": "w-3 h-3"
"className": "text-xs"
}
},
{
@@ -346,7 +346,7 @@
"if": "{{dep.type === 'module'}}",
"props": {
"name": "cube",
"className": "w-3.5 h-3.5 text-gray-500 dark:text-gray-400"
"className": "text-sm text-gray-500 dark:text-gray-400"
}
},
{
@@ -355,7 +355,7 @@
"if": "{{dep.type === 'plugin'}}",
"props": {
"name": "puzzle-piece",
"className": "w-3.5 h-3.5 text-gray-500 dark:text-gray-400"
"className": "text-sm text-gray-500 dark:text-gray-400"
}
},
{
@@ -428,7 +428,7 @@
"name": "Icon",
"props": {
"name": "code",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -470,7 +470,7 @@
"name": "Icon",
"props": {
"name": "edit",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -520,7 +520,7 @@
"name": "Icon",
"props": {
"name": "download",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -583,7 +583,8 @@
"templateLayoutStrategy": "overwrite",
"hasModifiedTemplateLayouts": false,
"modifiedTemplateLayoutsCount": 0,
"modifiedTemplateLayouts": []
"modifiedTemplateLayouts": [],
"modifiedTemplateLayoutsCheckFailed": false
}
},
{
@@ -600,7 +601,17 @@
"target": "global",
"hasModifiedTemplateLayouts": "{{response.data?.has_modified_layouts ?? false}}",
"modifiedTemplateLayoutsCount": "{{response.data?.modified_count ?? 0}}",
"modifiedTemplateLayouts": "{{response.data?.modified_layouts ?? []}}"
"modifiedTemplateLayouts": "{{response.data?.modified_layouts ?? []}}",
"modifiedTemplateLayoutsCheckFailed": false
}
}
],
"onError": [
{
"handler": "setState",
"params": {
"target": "global",
"modifiedTemplateLayoutsCheckFailed": true
}
}
]
@@ -656,7 +667,7 @@
"name": "Icon",
"props": {
"name": "refresh",
"className": "w-4 h-4"
"className": "text-base"
}
},
{
@@ -864,7 +875,7 @@
{
"type": "basic",
"name": "Span",
"text": "$t:admin.templates.pagination_info|total={{templates?.data?.total ?? 0}}|from={{((templates?.data?.current_page ?? 1) - 1) * (templates?.data?.per_page ?? 12) + 1}}|to={{Math.min((templates?.data?.current_page ?? 1) * (templates?.data?.per_page ?? 12), templates?.data?.total ?? 0)}}"
"text": "$t:admin.templates.pagination_info|total={{templates?.data?.pagination?.total ?? 0}}|from={{((templates?.data?.pagination?.current_page ?? 1) - 1) * (templates?.data?.pagination?.per_page ?? 12) + 1}}|to={{Math.min((templates?.data?.pagination?.current_page ?? 1) * (templates?.data?.pagination?.per_page ?? 12), templates?.data?.pagination?.total ?? 0)}}"
}
]
}
@@ -890,7 +901,7 @@
"name": "Icon",
"props": {
"name": "info-circle",
"className": "w-5 h-5 text-blue-600 dark:text-blue-400 flex-shrink-0 mt-0.5"
"className": "text-xl text-blue-600 dark:text-blue-400 flex-shrink-0 mt-0.5"
}
},
{