Skip to content

Commit 101cf08

Browse files
wip
1 parent a1ff95e commit 101cf08

File tree

1 file changed

+1
-28
lines changed

1 file changed

+1
-28
lines changed

services/property/src/adapters/facility-adapter.ts

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -131,36 +131,11 @@ export const getFacilitiesByPropertyCode = async (propertyCode: string) => {
131131
}
132132

133133
export const getFacilitiesByBuildingCode = async (buildingCode: string) => {
134-
const facilities = await prisma.facility.findMany({
135-
where: {
136-
propertyObject: {
137-
building: {
138-
buildingCode,
139-
},
140-
},
141-
},
142-
include: {
143-
propertyObject: {
144-
select: {
145-
id: true,
146-
building: {
147-
select: {
148-
id: true,
149-
buildingCode: true,
150-
name: true,
151-
},
152-
},
153-
},
154-
},
155-
},
156-
})
157-
console.log(facilities)
158-
159134
try {
160135
const result = await prisma.propertyStructure.findMany({
161136
where: {
162137
buildingCode,
163-
propertyObject: { objectTypeId: 'babyg' },
138+
propertyObject: { objectTypeId: 'balok' },
164139
},
165140
select: {
166141
buildingCode: true,
@@ -185,8 +160,6 @@ export const getFacilitiesByBuildingCode = async (buildingCode: string) => {
185160
},
186161
},
187162
})
188-
// console.log(result)
189-
return result
190163

191164
assert(result, 'property-structure-not-found')
192165

0 commit comments

Comments
 (0)