lenBase -> length 로 수정

This commit is contained in:
김민식 2025-04-10 13:54:05 +09:00
parent 14aa4227f4
commit cf900c3e92
2 changed files with 6 additions and 4 deletions

View File

@ -240,13 +240,14 @@ const Trestle = forwardRef((props, ref) => {
return { return {
...selectedRoof, ...selectedRoof,
hajebichi, hajebichi,
lenBase: lengthBase,
eavesMargin, eavesMargin,
ridgeMargin, ridgeMargin,
kerabaMargin, kerabaMargin,
roofIndex: selectedRoof.index, roofIndex: selectedRoof.index,
trestle: { trestle: {
hajebichi: hajebichi, hajebichi: hajebichi,
lengthBase: lengthBase, length: lengthBase,
...selectedRaftBase, ...selectedRaftBase,
...selectedTrestle, ...selectedTrestle,
...selectedConstMthd, ...selectedConstMthd,
@ -273,12 +274,13 @@ const Trestle = forwardRef((props, ref) => {
if (i === selectedRoof?.index) { if (i === selectedRoof?.index) {
return { return {
...selectedRoof, ...selectedRoof,
length: lengthBase,
eavesMargin, eavesMargin,
ridgeMargin, ridgeMargin,
kerabaMargin, kerabaMargin,
roofIndex: roof.index, roofIndex: roof.index,
trestle: { trestle: {
lengthBase: lengthBase, length: lengthBase,
hajebichi: hajebichi, hajebichi: hajebichi,
...selectedRaftBase, ...selectedRaftBase,
...selectedTrestle, ...selectedTrestle,
@ -309,7 +311,7 @@ const Trestle = forwardRef((props, ref) => {
if (!roof.construction?.constTp) result = false if (!roof.construction?.constTp) result = false
if (roof.lenAuth === 'C') { if (roof.lenAuth === 'C') {
if (!roof.trestle?.lengthBase) result = false if (!roof.trestle?.length) result = false
} }
if (['C', 'R'].includes(roof.raftAuth)) { if (['C', 'R'].includes(roof.raftAuth)) {
if (!roof?.raftBaseCd) result = false if (!roof?.raftBaseCd) result = false

View File

@ -85,7 +85,7 @@ export function useModuleTrestle(props) {
setEavesMargin(selectedRoof?.eavesMargin ?? 0) setEavesMargin(selectedRoof?.eavesMargin ?? 0)
setRidgeMargin(selectedRoof?.ridgeMargin ?? 0) setRidgeMargin(selectedRoof?.ridgeMargin ?? 0)
setKerabaMargin(selectedRoof?.kerabaMargin ?? 0) setKerabaMargin(selectedRoof?.kerabaMargin ?? 0)
setLengthBase(Math.round(selectedRoof?.trestle?.lengthBase ?? 0)) setLengthBase(Math.round(selectedRoof?.length ?? 0))
setCvrYn(selectedRoof?.construction?.cvrYn ?? 'N') setCvrYn(selectedRoof?.construction?.cvrYn ?? 'N')
setCvrChecked(selectedRoof?.construction?.cvrChecked ?? false) setCvrChecked(selectedRoof?.construction?.cvrChecked ?? false)
setSnowGdPossYn(selectedRoof?.construction?.snowGdPossYn ?? 'N') setSnowGdPossYn(selectedRoof?.construction?.snowGdPossYn ?? 'N')