feat: Implement copy functionality for item inspection information

- Added a modal for copying inspection information from a selected item to multiple target items.
- Implemented search and selection logic for target items to facilitate the copying process.
- Included validation to ensure a source item is selected and that target items are valid before proceeding with the copy operation.
- Enhanced user feedback with toast notifications for successful and error states during the copy process.
- Updated BOM management to include unit label handling for better clarity in item representation.
This commit is contained in:
kjs
2026-04-17 13:11:01 +09:00
parent b158b0aa77
commit 173b85b476
37 changed files with 2944 additions and 459 deletions

View File

@@ -223,13 +223,14 @@ class CategoryTreeService {
const query = `
INSERT INTO category_values (
table_name, column_name, value_code, value_label, value_order,
value_id, table_name, column_name, value_code, value_label, value_order,
parent_value_id, depth, path, description, color, icon,
is_active, is_default, company_code, created_by, updated_by
) VALUES (
(SELECT COALESCE(MAX(value_id), 0) + 1 FROM category_values),
$1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $15
)
RETURNING
RETURNING
value_id AS "valueId",
table_name AS "tableName",
column_name AS "columnName",

View File

@@ -167,7 +167,8 @@ class TableCategoryValueService {
columnName: string,
companyCode: string,
includeInactive: boolean = false,
menuObjid?: number
menuObjid?: number,
topLevelOnly: boolean = false
): Promise<TableCategoryValue[]> {
try {
logger.info("카테고리 값 목록 조회 (메뉴 스코프)", {
@@ -235,6 +236,10 @@ class TableCategoryValueService {
query += ` AND is_active = true`;
}
if (topLevelOnly) {
query += ` AND (depth = 1 OR depth IS NULL OR parent_value_id IS NULL)`;
}
query += ` ORDER BY value_order, value_label`;
const result = await pool.query(query, params);