Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connected mealist to backend #25

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

connected mealist to backend #25

wants to merge 1 commit into from

Conversation

pc1400
Copy link
Contributor

@pc1400 pc1400 commented Dec 3, 2022

Connected front end recipe page to backend data base

@crc1200
Copy link
Contributor

crc1200 commented Dec 3, 2022

Have we found solutions to dealing with the different IP addresses as well as connecting to the Mongo DB server? Otherwise looks good.

@crc1200 crc1200 marked this pull request as ready for review December 3, 2022 21:21
@crc1200
Copy link
Contributor

crc1200 commented Dec 3, 2022

fetch('http://192.168.1.68:3001/scan', {

With lines like this, are we able to find a way to get the ip address of the user automatically instead of hard coding it into the program?

@crc1200 crc1200 self-requested a review December 7, 2022 23:34
Copy link
Contributor

@crc1200 crc1200 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks pretty good besides those IP changes

try {
let response = fetch(
'http://192.168.1.93:3001/recipes'
).then((response) => response.json())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what I wanted to talk about with the IP address. Do we keep track of all the files that need to be updated? Could we automate this at all

goodRecipes.sort(function(a, b){return b[1] - a[1]});
User.updateOne(
{ _id: ObjectId("6379434e41121f9226ba1e13") },
{ $set: { title: "Patrick Cunningham", recipes: goodRecipes } }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Title of Patrick Cunningham? Will this cause any exporting issues

User.updateOne(
{ _id: ObjectId('6379434e41121f9226ba1e13') },
{ $set: { ingredients: userIngredients } }
).then(result => {
res.json({ message: "APPLE" });
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apple?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants