Skip to content

Latest commit

 

History

History
62 lines (42 loc) · 2.15 KB

README.md

File metadata and controls

62 lines (42 loc) · 2.15 KB

Booking

Component to select calendar dates and number of guests for booking. It also displays prices per night and total number of reviews.

Related Projects

Table of Contents

  1. Usage
  2. API
  3. Requirements
  4. Development

Usage

Some usage instructions

API

Listings

HTTP Method Endpoint Description
GET /api/rooms/:listingid Return details about a specific listing
POST /api/rooms/ Create a new listing
PUT /api/rooms/:listingid Update and replace details for a specific listing
DELETE /api/rooms/:listingid Delete a specific listing

Bookings

HTTP Method Endpoint Description
GET /api/bookings/:listing_id Returns all booked dates for a specific listing
POST /api/bookings/:listing_id Add a booked date for a specific listing
PUT /api/bookings/?id Update and replace details of a specific booked date for a specific listing
DELETE /api/bookings/?id Remove a booked date for a specific listing

Requirements

An nvmrc file is included if using nvm.

  • Node 6.13.0
  • etc

Development

Installing Dependencies

From within the root directory:

npm install -g webpack
npm install
npm run build
mysql -uroot < ./server/db/schema.sql
npm run seed