외벽선 그린 후, 지붕형상 수동 설정 시 오류
This commit is contained in:
parent
01b045c5ac
commit
d923b8acff
@ -445,9 +445,9 @@ export function useRoofAllocationSetting(id) {
|
|||||||
setCurrentRoofList(newRoofList)
|
setCurrentRoofList(newRoofList)
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleChangeInput = (e, type, index) => {
|
const handleChangeInput = (e, type = '', index) => {
|
||||||
const value = e.target.value
|
const value = e.target.value
|
||||||
if (type === 'pitch') {
|
/*if (type === 'pitch') {
|
||||||
// type이 pitch인 경우 소수점 1자리까지만 입력 가능
|
// type이 pitch인 경우 소수점 1자리까지만 입력 가능
|
||||||
const reg = /^[0-9]+(\.[0-9]{0,1})?$/
|
const reg = /^[0-9]+(\.[0-9]{0,1})?$/
|
||||||
|
|
||||||
@ -481,7 +481,7 @@ export function useRoofAllocationSetting(id) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}*/
|
||||||
|
|
||||||
const newRoofList = currentRoofList.map((roof, idx) => {
|
const newRoofList = currentRoofList.map((roof, idx) => {
|
||||||
if (idx === index) {
|
if (idx === index) {
|
||||||
|
|||||||
@ -203,6 +203,20 @@ export function useRoofShapePassivitySetting(id) {
|
|||||||
const roofBases = canvas.getObjects().filter((obj) => obj.name === POLYGON_TYPE.ROOF)
|
const roofBases = canvas.getObjects().filter((obj) => obj.name === POLYGON_TYPE.ROOF)
|
||||||
const exceptObjs = canvas.getObjects().filter((obj) => obj.name !== 'outerLine' && obj.parent?.name !== 'outerLine')
|
const exceptObjs = canvas.getObjects().filter((obj) => obj.name !== 'outerLine' && obj.parent?.name !== 'outerLine')
|
||||||
const lines = canvas.getObjects().filter((obj) => obj.name === 'outerLine')
|
const lines = canvas.getObjects().filter((obj) => obj.name === 'outerLine')
|
||||||
|
|
||||||
|
let checkedAllSetting = true
|
||||||
|
|
||||||
|
lines.forEach((line) => {
|
||||||
|
if (!line.attributes) {
|
||||||
|
checkedAllSetting = false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
if (!checkedAllSetting) {
|
||||||
|
swalFire({ text: '설정이 완료되지 않은 외벽선이 있습니다.', icon: 'warning' })
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
exceptObjs.forEach((obj) => {
|
exceptObjs.forEach((obj) => {
|
||||||
canvas.remove(obj)
|
canvas.remove(obj)
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user