Compare commits

..

3 Commits

4 changed files with 25 additions and 10 deletions

13
dev.ecosystem.config.js Normal file
View File

@ -0,0 +1,13 @@
module.exports = {
apps: [
{
name: 'qcast-front-development',
script: 'node_modules/next/dist/bin/next',
instances: 1,
exec_mode: 'fork',
env: {
NODE_ENV: 'development',
},
},
],
}

View File

@ -2,9 +2,12 @@ module.exports = {
apps: [
{
name: 'qcast-front-production',
script: 'npm run start:dev',
instance: 2,
script: 'node_modules/next/dist/bin/next',
instances: 2,
exec_mode: 'cluster',
env: {
NODE_ENV: 'production',
},
},
],
}

View File

@ -452,7 +452,7 @@ const Trestle = forwardRef((props, ref) => {
}),
new Promise((resolve) => {
const roofConstruction = newAddedRoofs.map((roof, index) => ({
const roofConstructions = newAddedRoofs.map((roof, index) => ({
roofIndex: newRoofs[index].index,
addRoof: newRoofs[index],
trestle: {
@ -468,9 +468,9 @@ const Trestle = forwardRef((props, ref) => {
trestleDetail: roof.trestleDetail,
}))
trestleTrigger({
roofConstruction,
roofConstructions,
})
setRoofsStore(roofConstruction)
setRoofsStore(roofConstructions)
resolve()
}),
]

View File

@ -76,16 +76,15 @@ export function useCanvasPopupStatusController(param = 1) {
roofSurfaceList.forEach((surface) => {
surface.modules = modules.filter((module) => module.surfaceId === surface.id)
})
if (data.roofConstruction) {
setRoofs(data.roofConstruction)
setManagementState({ ...managementState, roofs: data.roofConstruction.map((roof) => roof.construction.managementState) })
if (data.roofConstructions) {
setRoofs(data.roofConstructions)
setManagementState({ ...managementState, roofs: data.roofConstructions.map((roof) => roof.construction.managementState) })
// setModuleSelectionDataStore({ ...moduleSelectionDataStore, roofConstructions: data.roofConstruction })
resultData = { ...resultData, ...data }
resultData = { ...resultData, roofConstructions: data.roofConstructions }
}
// if (data?.module) setManagementState(data.common.managementState)
}
}
console.log('resultData', resultData)
setModuleSelectionDataStore(resultData)
}