Refactor code structure for improved readability and maintainability
Test Suite / test (24.15.0) (push) Has been cancelled

This commit is contained in:
Nils-Johan Gynther
2026-05-06 07:37:59 +02:00
parent e4f201ea36
commit 969dafdbc6
273 changed files with 11357 additions and 39 deletions
+65
View File
@@ -0,0 +1,65 @@
import { PantryService } from './pantry.service';
import { CreatePantryItemDto } from './dto/create-pantry-item.dto';
export declare class PantryController {
private readonly pantryService;
constructor(pantryService: PantryService);
findAll(user: {
userId: number;
}): import(".prisma/client").Prisma.PrismaPromise<({
product: {
category: string | null;
status: string;
name: string;
categoryId: number | null;
canonicalName: string | null;
id: number;
normalizedName: string;
isActive: boolean;
deletedAt: Date | null;
createdAt: Date;
updatedAt: Date;
ownerId: number;
isPrivate: boolean;
};
} & {
id: number;
createdAt: Date;
updatedAt: Date;
productId: number;
userId: number;
})[]>;
create(user: {
userId: number;
}, body: CreatePantryItemDto): Promise<{
product: {
category: string | null;
status: string;
name: string;
categoryId: number | null;
canonicalName: string | null;
id: number;
normalizedName: string;
isActive: boolean;
deletedAt: Date | null;
createdAt: Date;
updatedAt: Date;
ownerId: number;
isPrivate: boolean;
};
} & {
id: number;
createdAt: Date;
updatedAt: Date;
productId: number;
userId: number;
}>;
remove(user: {
userId: number;
}, id: number): Promise<{
id: number;
createdAt: Date;
updatedAt: Date;
productId: number;
userId: number;
}>;
}