diff --git a/WebContent/WEB-INF/view/productionplanning/mBomHeaderPopup.jsp b/WebContent/WEB-INF/view/productionplanning/mBomHeaderPopup.jsp index a543f83..156659f 100644 --- a/WebContent/WEB-INF/view/productionplanning/mBomHeaderPopup.jsp +++ b/WebContent/WEB-INF/view/productionplanning/mBomHeaderPopup.jsp @@ -292,6 +292,7 @@ function fn_loadMbomTemplate() { if(leftFrame && leftFrame._tabulGrid) { leftFrame._tabulGrid.setData(templateDetails); + if(leftFrame.fn_syncLastValidData) leftFrame.fn_syncLastValidData(); console.log("템플릿 데이터 로드 완료"); } else { console.error("왼쪽 프레임 또는 그리드를 찾을 수 없습니다."); @@ -1031,6 +1032,7 @@ function buildSubTreeFlatList(subTree, parentObjid, baseLevel) { REVISION: item.REVISION || item.revision || '', SUPPLY_TYPE: '사급', STATUS: 'ACTIVE', + _IS_ADDED: true, _IS_SUB_PART: true }); } @@ -1140,7 +1142,8 @@ function fn_mbomAddPart() { SPEC: rowData.SPEC, REVISION: rowData.REVISION, SUPPLY_TYPE: '사급', - STATUS: 'ACTIVE' + STATUS: 'ACTIVE', + _IS_ADDED: true }; newParts.push(newPart); @@ -1158,6 +1161,13 @@ function fn_mbomAddPart() { } } + // 수준(LEVEL_X) 필드 설정 + for(var i = 0; i < newParts.length; i++) { + if(leftFrame && leftFrame.fn_setLevelFields) { + leftFrame.fn_setLevelFields(newParts[i]); + } + } + // 왼쪽 프레임의 Tabulator에 추가 if(leftFrame && leftFrame._tabulGrid) { if(parentObjid) { @@ -1180,6 +1190,11 @@ function fn_mbomAddPart() { } } + // 드래그 이동용 데이터 동기화 + if(leftFrame && leftFrame.fn_syncLastValidData) { + leftFrame.fn_syncLastValidData(); + } + var message = rightSelectedRows.length + '개 파트가 추가되었습니다.'; if(subPartCount > 0) { message += '\n(반제품 하위 ' + subPartCount + '개 품목 포함)'; @@ -1253,6 +1268,7 @@ function fn_mbomDeletePart() { // 선택한 행 + 하위 품목 일괄 삭제 allData.splice(foundIndex, deleteCount); leftFrame._tabulGrid.setData(allData); + if(leftFrame.fn_syncLastValidData) leftFrame.fn_syncLastValidData(); var message = '파트가 삭제되었습니다.'; if(deleteCount > 1) { @@ -1463,6 +1479,7 @@ function fn_changeTopProduct() { // 왼쪽 트리에 새 데이터 설정 if(leftFrame && leftFrame._tabulGrid) { leftFrame._tabulGrid.setData(newTreeData); + if(leftFrame.fn_syncLastValidData) leftFrame.fn_syncLastValidData(); } // M-BOM 품번을 변경된 최상위 제품의 품번으로 설정 diff --git a/WebContent/WEB-INF/view/productionplanning/mBomPopupLeft.jsp b/WebContent/WEB-INF/view/productionplanning/mBomPopupLeft.jsp index 82c85a1..224b40c 100644 --- a/WebContent/WEB-INF/view/productionplanning/mBomPopupLeft.jsp +++ b/WebContent/WEB-INF/view/productionplanning/mBomPopupLeft.jsp @@ -78,6 +78,7 @@ body {