diff --git a/src/donation-order/donation-order.service.ts b/src/donation-order/donation-order.service.ts index 73f93a4..6be7542 100644 --- a/src/donation-order/donation-order.service.ts +++ b/src/donation-order/donation-order.service.ts @@ -87,30 +87,7 @@ export class DonationOrderService { async show(id: string, userId: string) { const data = await this.prismaService.donationOrder.findUnique({ where: { id, userId }, - select: { - id: true, - status: true, - userId: true, - shelter: { - select: { - id: true, - name: true, - }, - }, - donationOrderSupplies: { - select: { - quantity: true, - supply: { - select: { - name: true, - measure: true, - }, - }, - }, - }, - createdAt: true, - updatedAt: true, - }, + select: this.donationOrderVisibleFields, }); return data; } diff --git a/src/shelter/shelter.service.ts b/src/shelter/shelter.service.ts index 757acdb..9aee0f0 100644 --- a/src/shelter/shelter.service.ts +++ b/src/shelter/shelter.service.ts @@ -316,7 +316,7 @@ export class ShelterService implements OnModuleInit { shelterSupplies .map(this.parseShelterSupply) .filter((f) => - this.canDecayShelterSupply(f, [SupplyPriority.Urgent], 12), + this.canDecayShelterSupply(f, [SupplyPriority.Urgent], 48), ), SupplyPriority.Needing, @@ -329,7 +329,7 @@ export class ShelterService implements OnModuleInit { this.canDecayShelterSupply( f, [SupplyPriority.Needing, SupplyPriority.Remaining], - 48, + 72, ), ), SupplyPriority.UnderControl,