feat: add rematch functionality for recipe ingredients and enhance inventory management
Test Suite / test (24.15.0) (push) Has been cancelled
Test Suite / test (24.15.0) (push) Has been cancelled
- Added a new API path for rematching recipe ingredients in `api_paths.dart`. - Implemented a manual product creation dialog in `inventory_screen.dart` to allow users to create new products directly. - Integrated the rematch functionality in `recipe_repository.dart` to handle rematching of recipe ingredients. - Updated the recipe detail screen to include a button for triggering the rematch process. - Introduced a new `RecipeMatchingService` in the backend to handle ingredient matching logic. - Added database migration to include `aiEngineEnabled` column in the User table. Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
+22
-22
@@ -7,13 +7,13 @@ export declare class InventoryController {
|
||||
constructor(inventoryService: InventoryService);
|
||||
consume(id: number, body: ConsumeInventoryDto): Promise<{
|
||||
product: {
|
||||
name: string;
|
||||
category: string | null;
|
||||
status: string;
|
||||
name: string;
|
||||
categoryId: number | null;
|
||||
canonicalName: string | null;
|
||||
id: number;
|
||||
categoryId: number | null;
|
||||
normalizedName: string;
|
||||
canonicalName: string | null;
|
||||
isActive: boolean;
|
||||
deletedAt: Date | null;
|
||||
createdAt: Date;
|
||||
@@ -22,6 +22,7 @@ export declare class InventoryController {
|
||||
isPrivate: boolean;
|
||||
};
|
||||
} & {
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -29,7 +30,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
@@ -45,18 +45,18 @@ export declare class InventoryController {
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
comment: string | null;
|
||||
amountUsed: import("@prisma/client/runtime/library").Decimal;
|
||||
inventoryItemId: number;
|
||||
amountUsed: import("@prisma/client/runtime/library").Decimal;
|
||||
}[]>;
|
||||
findAll(location?: string, sort?: string): Promise<({
|
||||
product: {
|
||||
name: string;
|
||||
category: string | null;
|
||||
status: string;
|
||||
name: string;
|
||||
categoryId: number | null;
|
||||
canonicalName: string | null;
|
||||
id: number;
|
||||
categoryId: number | null;
|
||||
normalizedName: string;
|
||||
canonicalName: string | null;
|
||||
isActive: boolean;
|
||||
deletedAt: Date | null;
|
||||
createdAt: Date;
|
||||
@@ -65,6 +65,7 @@ export declare class InventoryController {
|
||||
isPrivate: boolean;
|
||||
};
|
||||
} & {
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -72,7 +73,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
@@ -83,13 +83,13 @@ export declare class InventoryController {
|
||||
})[]>;
|
||||
findExpiring(): Promise<({
|
||||
product: {
|
||||
name: string;
|
||||
category: string | null;
|
||||
status: string;
|
||||
name: string;
|
||||
categoryId: number | null;
|
||||
canonicalName: string | null;
|
||||
id: number;
|
||||
categoryId: number | null;
|
||||
normalizedName: string;
|
||||
canonicalName: string | null;
|
||||
isActive: boolean;
|
||||
deletedAt: Date | null;
|
||||
createdAt: Date;
|
||||
@@ -98,6 +98,7 @@ export declare class InventoryController {
|
||||
isPrivate: boolean;
|
||||
};
|
||||
} & {
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -105,7 +106,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
@@ -116,13 +116,13 @@ export declare class InventoryController {
|
||||
})[]>;
|
||||
create(body: CreateInventoryDto): Promise<{
|
||||
product: {
|
||||
name: string;
|
||||
category: string | null;
|
||||
status: string;
|
||||
name: string;
|
||||
categoryId: number | null;
|
||||
canonicalName: string | null;
|
||||
id: number;
|
||||
categoryId: number | null;
|
||||
normalizedName: string;
|
||||
canonicalName: string | null;
|
||||
isActive: boolean;
|
||||
deletedAt: Date | null;
|
||||
createdAt: Date;
|
||||
@@ -131,6 +131,7 @@ export declare class InventoryController {
|
||||
isPrivate: boolean;
|
||||
};
|
||||
} & {
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -138,7 +139,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
@@ -149,13 +149,13 @@ export declare class InventoryController {
|
||||
}>;
|
||||
update(id: number, body: UpdateInventoryDto): Promise<{
|
||||
product: {
|
||||
name: string;
|
||||
category: string | null;
|
||||
status: string;
|
||||
name: string;
|
||||
categoryId: number | null;
|
||||
canonicalName: string | null;
|
||||
id: number;
|
||||
categoryId: number | null;
|
||||
normalizedName: string;
|
||||
canonicalName: string | null;
|
||||
isActive: boolean;
|
||||
deletedAt: Date | null;
|
||||
createdAt: Date;
|
||||
@@ -164,6 +164,7 @@ export declare class InventoryController {
|
||||
isPrivate: boolean;
|
||||
};
|
||||
} & {
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -171,7 +172,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
@@ -181,6 +181,7 @@ export declare class InventoryController {
|
||||
comment: string | null;
|
||||
}>;
|
||||
remove(id: number): Promise<{
|
||||
origin: string | null;
|
||||
id: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
@@ -188,7 +189,6 @@ export declare class InventoryController {
|
||||
quantity: import("@prisma/client/runtime/library").Decimal;
|
||||
unit: string;
|
||||
brand: string | null;
|
||||
origin: string | null;
|
||||
receiptName: string | null;
|
||||
location: string | null;
|
||||
purchaseDate: Date | null;
|
||||
|
||||
Reference in New Issue
Block a user