Skip to content

This application is used for appointment booking among buyers and sellers

License

Notifications You must be signed in to change notification settings

Sruthi-Ganesh/buyer-seller-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Appointment Booking - buyer-seller-app

This application is used for appointment booking among buyers and sellers. To help buyers save their time, we decided to implement appointment booking system that will allow them to book their appointment ahead of time before going to the service provider. Hence, it is required to design and develop a solution that will allow the users to perform the action smoothly.

Product Server - product-server

This is the nodejs express server application. This connects with mongodb database.

  1. The server uses token based authentication to authenticate users.
  2. Token is retrieved when the user logs in to the app
  3. Token needs to be added to header x-access-token for every API call except signin and signup (obviously ;)
  4. Token is session based, not stored on the browser due to security concerns, if you refresh the page you need to login again (sorry!)
  5. Each user can have roles (buyer, seller or admin).
  6. Only users having buyer role can login using mobile app.
  7. Only users have seller role can login using web app.
  8. If no role is present, the user cannot login. Based on the signup on either mobile or web app, the role is assigned automatically.
  9. Single user can have mutiple roles. Multiple role configuration is supported from API standpoint, can be utilised from Postman.
  10. There is no forgot password option as of now, so try to remember the username and password.

Prerequisites

Installing mongo-db

If you do not have mongodb service running locally, follow this here.

  1. Mac - https://zellwk.com/blog/install-mongodb/
  2. Windows - https://treehouse.github.io/installation-guides/windows/mongo-windows.html

The API exposes the following end points

  1. /api/auth/signin - For signing in with a username and password
  2. /api/auth/signup - For signing up with username, email and password
  3. /api/appointment/schedule - For a buyer scheduling an appointment to seller
  4. /api/appointment/pending - For a seller retrieving all pending appointments
  5. /api/appointment/:id/approve - For a seller, approving an appointment request
  6. /api/appointment/:id/cancel - For a seller, cancelling an appointment request
  7. /api/seller/all - Get all sellers
  8. /api/seller - Get the current seller information

Start the application

cd product-server
npm install
npm start

React Native Buyer Mobile App - react-buyer-app

This is a vanilla react native application which is used by buyers to schedule appointments with sellers. A buyer can login with username and password, view all sellers, search for seller and book appointment with a seller.

The appointment can only be booked within the time range the seller is available.

Todo

  1. Change the API_URL in react-buyer-app/src/helpers/constants.js to 'http://:/api/'

Start the application

cd react-buyer-app
npm install
npm start
npm run ios # or npm run android

You can also run ios command from xcode by opening the react-buyer-app/ios/SimpleLoginTemplate.xcworkspace in xcode and hitting the run icon on top left.

screenshots

Screenshot 2021-03-18 at 11 52 15 AM

Screenshot 2021-03-18 at 11 52 41 AM

Screenshot 2021-03-18 at 11 52 52 AM

Screenshot 2021-03-18 at 11 53 10 AM

Screenshot 2021-03-18 at 11 53 37 AM

Screenshot 2021-03-18 at 11 53 48 AM

Screenshot 2021-03-18 at 11 54 38 AM

Screenshot 2021-03-18 at 11 54 45 AM

React Seller Web App - seller-web-app

This is a react web application which is used by sellers to view the appointments requested by the buyers. The sellers have an option to accept or cancel the appointment request. The seller can also change their available from/to time based on their convenience

Start the application

cd seller-web-app
npm install
npm start

Screenshots

Screenshot 2021-03-18 at 12 01 45 PM

Screenshot 2021-03-18 at 12 02 03 PM

Screenshot 2021-03-18 at 12 02 50 PM

Screenshot 2021-03-18 at 12 03 07 PM

Screenshot 2021-03-18 at 12 03 26 PM

Screenshot 2021-03-18 at 12 04 06 PM

Screenshot 2021-03-18 at 12 04 15 PM

About

This application is used for appointment booking among buyers and sellers

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published