Coder Social home page Coder Social logo

asharanjith / food-recipes-app Goto Github PK

View Code? Open in Web Editor NEW
7.0 1.0 0.0 6.04 MB

The Recipe app keeps track of all your recipes, ingredients, and inventory. It will allow you to save ingredients, keep track of what you have, create recipes, and generate a shopping list based on what you have and what you are missing from a recipe. Also, the app allows to share your recipe to the public if you wish.

Home Page: https://food-recipes-n92f.onrender.com/

License: MIT License

Ruby 66.94% JavaScript 1.20% CSS 1.62% HTML 27.24% Batchfile 2.85% Shell 0.15%
cancancan devise rspec-testing ruby ruby-on-rails

food-recipes-app's Introduction

๐Ÿ“— Table of Contents

๐Ÿ“– Food Recipes App

The Recipe app keeps track of all your recipes, ingredients, and inventory. It will allow you to save ingredients, keep track of what you have, create recipes, and generate a shopping list based on what you have and what you are missing from a recipe. Also, since sharing recipes is an important part of cooking the app should allow you to make them public so anyone can access them.

๐Ÿ›  Built With

Tech Stack

Language

Key Features

  • Add recipes
  • Add foods
  • Generate shopping items

Live Demo

Click here to see the live demo

(back to top)

๐Ÿ’ป Getting Started

To get a local copy up and running follow these simple example steps.

Prerequisites

In order to run this project you need:

  • Install ruby on your computer or run it with docker
  • Have rails installed on your computer

Setup

Clone this repository by using the command line :

  • git clone https://github.com/asharanjith/Food-planner.git

Install

Install this project with:

bundle install

Setup database using

rails db:create rails db: migrate

Usage

To run the project, execute the following command:

rails s

Run tests

To run tests, execute the following command:

bundle exec rspec

NB: You need to create an env file for your database credentials

(back to top)

๐Ÿ‘ฅ Authors

๐Ÿ‘ค Asha S Vijayan

๐Ÿ‘ค Gulalai Ahmadi

(back to top)

๐Ÿ”ญ Future Features

  • Add dates
  • Add weekly meal planner

(back to top)

๐Ÿค Contributing

Contributions, issues, and feature requests are welcome!

Feel free to check the issues page.

(back to top)

โญ๏ธ Show your support

If you like this project by staring it.

(back to top)

๐Ÿ™ Acknowledgments

I would like to thank Microverse for the providing support.

(back to top)

๐Ÿ“ License

This project is MIT licensed.

(back to top)

food-recipes-app's People

Contributors

ahmadigu avatar asharanjith avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

food-recipes-app's Issues

Create Recipe details page 4pt

You should create a recipe details page according to the design
Requirements

  • Should display a toggle button that allows for a recipe to be shown in public or not
  • If the recipe is public or the user is the owner of the recipe, should display the recipe details page
  • Clicking on the Add ingredient button, should lead the user to add a new food to the recipe (if the user is the owner of the recipe)
  • A user can't make a recipe private if he is not the owner of it
  • In the food list, a user can remove food by clicking on the remove button
  • When clicking on generate shopping list button, it should lead to the general_shopping_list page with the ingredients (food list)
  • The path of the recipe details page should be the following: localhost:3000/46378

Integration specs for general shopping list page 1pt

Create Integration specs for General shopping page in specs/views/
Requirements

  • General shopping page should have a title shopping list
  • General shopping page should contain amount of food items to buy
  • General shopping page should contain total value of food needed in dollars
  • General shopping page should contain food name
  • General shopping page should contain quantity of each food
  • General shopping page should contain total price for each food

Fix n+1 queries and write unit test for Food 1pt

Make sure to fix n+1 queries for food. Do unit tests for the Food model.

Requirements

  • Create a folder spec/models
  • Inside that folder create 1 models Food
  • Food model should contain at least 3 tests
  • Make sure that a user can't create wrong data, for example adding a number in the food name.

Create a User model 0.5pt

You should create a User model according to the UML diagram

Requirements

  • A user should have a Model according to the design
  • A User can have many recipes

Integration specs for recipe details page 2pt

Create Integration specs for Recipe details page in specs/views/
Requirements

  • Recipe details page should have public toggle button
  • Recipe details page should contain a title for the recipe
  • Recipe details page should contain preparation time
  • Recipe details page should contain cooking time
  • Recipe details page should have generate shopping list button
  • When clicking on the generate shopping list button, it should redirect user to the general_shopping_list page
  • Recipe details page should have Add ingredient button
  • When clicking on Add ingredient button, it should redirect to a form where user can add a food
  • It should show list of food
  • It should show quantity for each food
  • It should show the value for each food
  • It should allow user to remove specific food

Fix n+1 queries and write unit test for Recipe 1pt

Make sure to fix n+1 queries for Recipe. Do unit tests for Recipe model.
Requirements

  • Create a folder spec/models
  • Inside that folder create Recipe model
  • For the model, it should contain at least 3 tests
  • Make sure that a user can't create wrong data, for example adding a number instead of string in recipe

Create Recipe Model 1pt

You should create Recipe Model according to the UML diagram
Requirements

  • Your model should contain every column mentioned in the diagram
  • Your model should contain a foreign key user_id that links to User model

Integration specs for recipes page 1pt

Create Integration specs for Recipes page in specs/views/
Requirements

  • Recipe page should have Remove button
  • Recipe page should contain a title for each recipe
  • Recipe page should contain a description for each recipe
  • When clicking on recipe, it should redirect to recipe details

Create Login Page + Registration Page 4pt

Add devise gem to create a login page and registration page. Don't forget the password forgot page and email confirmation.
Style pages to have a decent look
Requirements

  • A user should be able to register their account successfully
  • Before logging into the app, the user needs to confirm their email address
  • User should be able to reset theit password using Forgot password option
  • A user should be able to login successfully (if they confirmed their email), otherwise send a message to them to confirm their email account

Fix n+1 queries and write unit test for User 1pt

Make sure to fix n+1 queries for User. Do unit tests for the User model.

Requirements

  • Create a folder spec/models
  • Inside that folder create 1 model User
  • User model should contain at least 3 tests
  • Make sure that a user can't create wrong data, for example adding a number instead of string in username

Create Food list Page 3pt

Create Food list Page according to the design
Requirements

  • Should display a list of food added by logged_in user
  • Should display the quantity of each food (Add a new column called quantity before Actions column)
  • When User click on add food, it should lead to a form.
  • In the add form page, user should be able to enter (food name, measurement unit, unit price and quantity of the food)
  • If no food is found, display a message informing the user that No food found, please click on Add food to add new food
  • Visiting localhost:3000/foods should show up the food page

Integration specs for public recipe page 1pt

Create Integration specs for Public Recipe page in specs/views/
Requirements

  • Public recipe page should contain a title called public recipes
  • Public recipe page should contain title of each public recipe
  • Public recipe page should contain author of the recipe
  • Public recipe page should contain total food items
  • Public recipe page should contain total price

Create Food Model 1 pt

Create Food Model according to the UML diagram

Requirements

  • Your Model should contain all fields mentioned in the diagram
  • Your model should have a foreign key user_id that links to User model

Integration specs for foods page 1pt

Create Integration specs for Food page in specs/views/

Requirements

  • Food page should have Add Food button
  • Food page should show list of food
  • Food page should show Measurement unit for each food
  • Food page should show quantity of each food
  • Food page should have unit price of each food
  • Food page should have delete button for each food
  • When clicking on delete button, it should delete the current food
  • When clicking on add food button, it should redirect to the form of add food

Fix n+1 queries and write unit test for Recipe Food 1pt

Make sure to fix n+1 queries for recipe food. Do unit tests for the Recipe Food model.
Requirements

  • Create a folder spec/models
  • Inside that folder create 1 model Recipe_food
  • Recipe food model should contain at least 3 tests
  • Make sure that a user can't create wrong data, for example adding a number in the Recipe food name.

General shopping list view 3.5pt

Create a general shopping list page according to the design

Requirements

  • Should show the list of food that is missing for all recipes of the logged-in user (hint: compare the list of food for all recipes with the general food list of that user. In practice, it should be food vs recipe food)
  • Should count the total food items and total price of the missing food
  • Should show a table of details, showing each food with its quantity and global price
  • Visiting localhost:3000/general_shopping_list should show up the shopping list page with all missing foods from the currently logged-in user

Create Recipes list page 3pt

Add a recipes list page according to the design
Requirements

  • Should display a list of recipes created by logged-in user according to the design
  • When clicking on each recipe, it should lead to the recipe details page for example localhost:3000/recipes/120
  • Should allow deleting a recipe (When clicking on remove button, it should remove the recipe)
  • Visiting localhost:3000/recipes should show a list of recipes for the current logged-in user

Create Public Recipe List page 2pt

Create a Public Recipe list page according to the design
Requirements

  • Should display a list of public recipes Ordered by newest according to the design
  • When clicking on each recipe, it should lead to the recipe details page
  • When visiting localhost:3000/public_recipes, it should show up the page

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.