fix: update file handling and improve query logging
- Added mes-architecture-guide.md to .gitignore to prevent unnecessary tracking. - Enhanced NodeFlowExecutionService to merge context data for WHERE clause, improving query accuracy. - Updated logging to include values in SQL query logs for better debugging. - Removed redundant event dispatches in V2Repeater to streamline save operations. - Adjusted DynamicComponentRenderer to conditionally refresh keys based on component type. - Improved FileUploadComponent to clear localStorage only for modal components, preventing unintended resets in non-modal contexts. These changes aim to enhance the overall functionality and maintainability of the application, ensuring better data handling and user experience.
This commit is contained in:
@@ -105,6 +105,7 @@ const FileUploadComponent: React.FC<FileUploadComponentProps> = ({
|
||||
const [forceUpdate, setForceUpdate] = useState(0);
|
||||
const [representativeImageUrl, setRepresentativeImageUrl] = useState<string | null>(null);
|
||||
const fileInputRef = useRef<HTMLInputElement>(null);
|
||||
const containerRef = useRef<HTMLDivElement>(null);
|
||||
// objid 기반으로 파일이 로드되었는지 추적 (다른 이펙트가 덮어쓰지 않도록 방지)
|
||||
const filesLoadedFromObjidRef = useRef(false);
|
||||
|
||||
@@ -197,7 +198,9 @@ const FileUploadComponent: React.FC<FileUploadComponentProps> = ({
|
||||
useEffect(() => {
|
||||
if (!imageObjidFromFormData) {
|
||||
// formData에서 값이 사라지면 파일 목록도 초기화 (새 등록 시)
|
||||
if (uploadedFiles.length > 0 && !isRecordMode) {
|
||||
// 단, 모달 내부의 컴포넌트만 초기화 - 일반 화면에서는 저장 후 리셋으로 인한 초기화 방지
|
||||
const isInModal = containerRef.current ? !!containerRef.current.closest('[role="dialog"]') : false;
|
||||
if (uploadedFiles.length > 0 && !isRecordMode && isInModal) {
|
||||
setUploadedFiles([]);
|
||||
filesLoadedFromObjidRef.current = false;
|
||||
}
|
||||
@@ -1058,11 +1061,11 @@ const FileUploadComponent: React.FC<FileUploadComponentProps> = ({
|
||||
|
||||
return (
|
||||
<div
|
||||
ref={containerRef}
|
||||
style={{
|
||||
...componentStyle,
|
||||
width: "100%",
|
||||
height: "100%",
|
||||
// 🔧 !important 제거 - 커스텀 스타일이 없을 때만 기본값 적용
|
||||
border: hasCustomBorder ? undefined : "none",
|
||||
boxShadow: "none",
|
||||
outline: "none",
|
||||
|
||||
Reference in New Issue
Block a user