dev #708

Merged
ysCha merged 3 commits from dev into dev-deploy 2026-03-12 17:12:35 +09:00
2 changed files with 6 additions and 4 deletions
Showing only changes of commit 64ba5ad36e - Show all commits

View File

@ -128,9 +128,9 @@ export default function CanvasFrame() {
if (currentCanvasPlan.planNo) {
/* 약간의 지연을 줘서 roofMaterials가 로드될 시간을 확보 */
setTimeout(() => {
// canvasSetting
// canvasSetting roofSizeSet API
if (!canvasSetting?.roofSizeSet) {
// roofSizeSet fetch
const isPlanChanged = canvasSetting?.planNo !== undefined && Number(canvasSetting.planNo) !== Number(currentCanvasPlan.planNo)
if (!canvasSetting?.roofSizeSet || isPlanChanged) {
fetchBasicSettings(Number(currentCanvasPlan.planNo), null, currentCanvasPlan.objectNo)
}
}, 100)

View File

@ -457,7 +457,9 @@ export function useCanvasSetting(executeEffect = true) {
if (openPoint !== 'basicSettingSave') {
// canvasSetting은 현재 값을 유지하고 basicSetting만 업데이트
// 새로고침 시 canvasSetting이 바뀌는 문제 방지
if (!canvasSetting?.roofSizeSet) {
// 단, 플랜이 변경된 경우에는 항상 업데이트
const isPlanChanged = canvasSetting?.planNo !== undefined && Number(canvasSetting.planNo) !== Number(roofsRow[0].planNo)
if (!canvasSetting?.roofSizeSet || isPlanChanged) {
setCanvasSetting({
...basicSetting,
roofMaterials: addRoofs[0],