mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-11-26 08:04:53 +00:00
task: update getOneSpace API to match revamp structure
This commit is contained in:
@ -271,7 +271,6 @@ export class SpaceService {
|
||||
}
|
||||
}
|
||||
|
||||
// todo refactor this method to eliminate wrong use of tags
|
||||
async findOne(params: GetSpaceParam): Promise<BaseResponseDto> {
|
||||
const { communityUuid, spaceUuid, projectUuid } = params;
|
||||
try {
|
||||
@ -282,19 +281,6 @@ export class SpaceService {
|
||||
|
||||
const queryBuilder = this.spaceRepository
|
||||
.createQueryBuilder('space')
|
||||
.leftJoinAndSelect('space.parent', 'parent')
|
||||
.leftJoinAndSelect(
|
||||
'space.children',
|
||||
'children',
|
||||
'children.disabled = :disabled',
|
||||
{ disabled: false },
|
||||
)
|
||||
.leftJoinAndSelect(
|
||||
'space.incomingConnections',
|
||||
'incomingConnections',
|
||||
'incomingConnections.disabled = :incomingConnectionDisabled',
|
||||
{ incomingConnectionDisabled: false },
|
||||
)
|
||||
.leftJoinAndSelect('space.productAllocations', 'productAllocations')
|
||||
.leftJoinAndSelect('productAllocations.tag', 'spaceTag')
|
||||
.leftJoinAndSelect('productAllocations.product', 'spaceProduct')
|
||||
|
||||
Reference in New Issue
Block a user