Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several changes to the backend API integration, the addition of new pantry-related features, and updates to the frontend components to support these changes. The most significant changes involve modifying API endpoints, adding new pantry-related functionalities, and updating the frontend to handle the new data.
Backend API Integration:
API Endpoint Modifications:
getAllItems
function to includepantryId
as a query parameter insrc/api/itemApis.ts
.userid
from multiple meal-related API functions insrc/api/mealApis.ts
. [1] [2] [3] [4] [5] [6] [7] [8] [9]New Pantry API Functions:
src/api/pantryApis.ts
.Frontend Components:
State Management Updates:
SET_CURRENT_PANTRY_TYPE
andsetCurrentPantry
action insrc/action/Action.ts
. [1] [2]Component Updates:
ChooseFoodComponent
to usecurrentPantry
instead ofcurrentUser
insrc/component/ChooseFoodComponent.tsx
. [1] [2]currentUser
fromCompleteFoodConsumptionComponent
insrc/component/CompleteFoodConsumptionComponent.tsx
. [1] [2] [3]New Pantry Components:
PantryDataComponent
for handling pantry data input insrc/component/PantryDataComponent.tsx
.PantrySelectionDialogComponent
for selecting a pantry insrc/component/PantrySelectionDialogComponent.tsx
.PantryShareDialogComponent
for sharing a pantry via QR code insrc/component/PantryShareDialogComponent.tsx
.Configuration:
Firebase Configuration:
firebase.json
to include a new route for pantry API infirebase.json
.Nginx Configuration:
nginx.conf
.Dependencies:
react-qr-code
topackage.json
.