Backend for the BetterPoll mobile app. Created using node js and mysql.

Overview

BetterPoll-Backend

This is the backend repository for the BetterPoll android application currently under development.

The APIs are being created using node js, express js and mySQL as the database and will be deployed on heroku for testing.

The frontend repo : https://github.com/adityabisht02/Betterpoll

How to Setup:

  1. Install Node js

  2. Clone this repository using git clone https://github.com/adityabisht02/BetterPoll-Backend

  3. change directory to the folder containing the index.js file using cd BetterPoll-Backend

  4. Run npm i to install dependencies.

  5. Create a mySQL database called "betterpoll". Check here to install mySQL

  6. Run npm run initialise-db function to create tables for users and admins.

  7. Run npm start to start the server.

Backend workflow:

image

image

image

Comments
  • Create the user signUp api

    Create the user signUp api

    You can find the login.js file under apis and work on the signup api. Write the sql query and import the sqlpool to write the query.

    You can refer to the initialiseDB function for reference on how to create queries using mysql.pool.

    hacktoberfest hacktoberfest-accepted 
    opened by adityabisht02 10
  • Create admin sign in

    Create admin sign in

    If the admin username and password are present in the table ,send a positive response. U can take the username and password from request body. Use only the username and password to log in , other fields like email and id are not required here.

    good first issue hacktoberfest 
    opened by adityabisht02 9
  • [Feat]: Created the Admin Login API

    [Feat]: Created the Admin Login API

    PR Title

    The purpose of this Pull Request is to fix #44 >

    Postman Screenshots

    Checklist

    • [ ] I have tested in local Environment.
    • [ ] I have made the fix as per issue converstaion
    opened by harpreet0102 5
  • Create an admin sign up api

    Create an admin sign up api

    Find the admin/login.js file. Take the sign up information from request body and use it to create an admin. You can look at the admin table for the fields you need to sign up an admin.

    help wanted hacktoberfest 
    opened by adityabisht02 5
  • Edit menu endpoint

    Edit menu endpoint

    Edit menu endpoint This feature adds an api endpoint at /edit-menu which allows users to create and update menus. Issue #23

    MessManagementTests

    Checklist

    • [✔] I have tested in local Environment.
    • [✔] I have made the fix as per issue conversation
    opened by Jothebanner 5
  • How to log user mess attendance and view mess details

    How to log user mess attendance and view mess details

    1. For the mess details I need to return the menu for the day and the messcodes for the particular user.
    2. For the mess attendance I need to log the attendance of the user who enters the code on the admin device.

    Possible ways of achieving this:

    1. I need to use the user id and not the user name for this so that duplicacy in names can be avoided.
    2. I need a way to have access to the id of the current user at all times.
    help wanted question 
    opened by adityabisht02 3
  • Hashing password

    Hashing password

    PR Title

    The purpose of this Pull Request is to fix #

    Postman Screenshots

    Checklist

    • [ ] I have tested in local Environment.
    • [ ] I have made the fix as per issue converstaion
    opened by Hares27 3
  • Create a messattendance table

    Create a messattendance table

    1. Refer to the messcodes table inside inititaliseDB.js, and create a messattendance table.
    2. The table should have the users' name, breakfast , lunch and dinner attendance as columns.
    3. The attendance will be marked as P for present and A for absent.
    good first issue hacktoberfest 
    opened by adityabisht02 2
  • added data

    added data

    PR Title

    The purpose of this Pull Request is to fix #

    Postman Screenshots

    Checklist

    • [x] I have tested in local Environment.
    • [x] I have made the fix as per issue converstaion
    opened by kuldeepmangla 2
  • Mess attendance roadmap

    Mess attendance roadmap

    1. The user id which is stored in android device's local storage will be used as a code for logging attendance.
    2. There will be no entry in the mess attendance table, instead the admin side will display a positive message if the user id exists (something like user can have the meal).
    3. I am currently not keeping track of meals.(breakfast , lunch , dinner all have the same code and same basic response)
    ANNOUNCEMENT 
    opened by adityabisht02 0
  • How to manage shuttle booking

    How to manage shuttle booking

    1. There are multiple shuttles which will be running from campus and I need to manage booking for each of them.
    2. Do I make separate tables for every shuttle and mark attendance there or is there a better way of managing this.
    help wanted question 
    opened by adityabisht02 1
Owner
Aditya Bisht
Aspiring software developer.
Aditya Bisht
Grupprojekt för kurserna 'Javascript med Ramverk' och 'Agil Utveckling'

JavaScript-med-Ramverk-Laboration-3 Grupprojektet för kurserna Javascript med Ramverk och Agil Utveckling. Utvecklingsguide För information om hur utv

Svante Jonsson IT-Högskolan 3 May 18, 2022
Hemsida för personer i Sverige som kan och vill erbjuda boende till människor på flykt

Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

null 4 May 3, 2022
Kurs-repo för kursen Webbserver och Databaser

Webbserver och databaser This repository is meant for CME students to access exercises and codealongs that happen throughout the course. I hope you wi

null 14 Jan 3, 2023
Smooth mobile touch slider for Mobile WebApp, HTML5 App, Hybrid App

iSlider iSlider is a lightweight, high-performant, no library dependencies cross-platform slide controller. It can help handling most sliding effects,

Baidu BEFE 1.7k Nov 25, 2022
Venni backend - The backend of the Venni client apps implementing the credit card payments, matching algorithms, bank transfers, trip rating system, and more.

Cloud Functions Description This repository contains the cloud functions used in the Firebase backend of the Venni apps. Local Development Setup For t

Abrantes 1 Jan 3, 2022
Gatsby-Formik-contact-form-with-backend-panel - Full working contact form with backend GUI panel.

Gatsby minimal starter ?? Quick start Create a Gatsby site. Use the Gatsby CLI to create a new site, specifying the minimal starter. # create a new Ga

Bart 1 Jan 2, 2022
Pim 4 Jun 21, 2022
This is a vanilla Node.js rest API created to show that it is possible to create a rest API using only vanilla Node.js

This is a vanilla Node.js rest API created to show that it is possible to create a rest API using only vanilla Node.js. But in most cases, I would recommend you to use something like Express in a production project for productivity purposes.

Eduardo Dantas 7 Jul 19, 2022
practice site to utilize node.js, Express, and mySQL

fishing_site practice site to utilize node.js, Express, and mySQL Run Locally create local instance of MySQL database. Run DB/fishing_Schema.sql to cr

Ryan Graue 1 Jan 22, 2022
Blog application api in Node.js express.js sequelize ORM and MYSQL Database

Node Express Mysql Sequelise Blog System Api Node api with express mysql sequelise Usage To get started with this api follow the steps below $ git clo

Kaddu Livingstone 6 Nov 9, 2022
A Restaurant (Table) Reservation API built with Node, TypeScript, Express, TypeORM, a MySQL DB, all running on Docker containers

Restaurant (Table) Reservation API A simple API for reserving tables at a restaurant. The API is based on the REST architectural style and uses Node.j

null 14 Oct 5, 2022
A Restaurant (Table) Reservation API built with Node, TypeScript, Express, TypeORM, a MySQL DB, all running on Docker containers

Restaurant (Table) Reservation API A simple API for reserving tables at a restaurant. The API is based on the REST architectural style and uses Node.j

null 14 Oct 5, 2022
Node.js Express + MySQL vulnerable boilerplate project

Node.js Express + MySQL vulnerable boilerplate project

null 13 Sep 16, 2022
A CRUD implementation using sequelize, mySQL, NODEJS, Express, JWT and other technologies.

A ideia do projeto é simular o funcionamento do backend de um blog através da implementação de uma aplicação em Node.js usando o pacote sequelize para

Vinicius Savordelli 6 May 11, 2022
Simple REST API using Express with TypeScript, PostgreSQL, and MySQL to practice the Clean Architecture by Uncle Bob.

Clean-Architecture Simple REST API using Express with TypeScript, PostgreSQL, and MySQL to practice the Clean Architecture by Uncle Bob. About This RE

Abdullah Adel 10 Oct 16, 2022
The app's backend is written in Python (Flask) and for search it uses Elasticsearch. I used this app as candidate application for learning out how to build, run and deploy a multi-container environment (docker-compose).

foodtrucks-app-docker-compose The app's backend is written in Python (Flask) and for search it uses Elasticsearch. I used this app as candidate applic

Selçuk Şan 3 Oct 24, 2022
A dockerized express mysql starter using typescript which iclude user management

A dockerized express mysql starter using typescript which iclude user management

Nimatullah Razmjo 2 Jan 26, 2022
This repository demonstrates how to integrate your Dialogflow agent with 3rd-party services services using a Node.JS backend service

This repository demonstrates how to integrate your Dialogflow agent with 3rd-party services services using a Node.JS backend service. Integrating your service allows you to take actions based on end-user expressions and send dynamic responses back to the end-user.

ddayto 10 Jul 21, 2022