Skip to content

Travel Blog that allows users to keep track of their trips and see other users trips. It also allows you to keep a daily log while on vacation and upload images.

License

Notifications You must be signed in to change notification settings

TMortara/Travel-Blog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wanderlust Travel Blog

Deployed Application

https://quiet-everglades-33653.herokuapp.com/

1. Table of Contents

2. Description

The Wanderlust Travel Blog allows users to add and edit trips to ensure all their memories are kept in one place. On the site users can add new trips, edit existing trips, and delete trips that may not have happened or that you want to forget. Within the trips, users can also upload images for their trip and create a daily log within each of their trips.

3. Installation

Please make sure to have following programs installed on your computer to use this application:

To use this application, git clone the repo down to your local. Then, run npm install in order to install the dependencies as specified in the package.json (bcrypt, body-parser, connect-session, dotenv, express, express-handlebars, express-session, multer, mysql2, nodemon, sequelize) will be installed. Now, you are ready to go!

4. Usage

To use this application, follow the instruction below:

  • First, run npm install on your terminal, then it will install the required npm packages.
  • Second, let's create the database - travel_db:
    • mysql -u root -p: login to MySQL then type the following commends:
    • source ./db/schema.sql;: this will create travel_db
    • show databases;: Now, you will see travel_db in the Database list
    • use travel_db;: it is empty now.
    • show tables: there is no tables yet.
    • exit: exit the mysql terminal
  • Third, let's include tables in the database we just created, travel_db:
    • node ./seeds/seed.js or npm run seed: these will insert the following tables in the travel_db:
      • comment
      • daily
      • image
      • trip
      • user
  • Now, let's run the program:
    • Set an Environmental Variable in ./.env file:
      • touch .env: this will create ./.env file
      • Now, add the following lines in ./.env
        • DB_NAME="travel_db"
        • DB_USER="root"
        • DB_PASSWORD="your_mysql_password"
        • DB_HOST='localhost' OR '127.0.0.1'
    • Then, run the program with one of the following approaches:
      • node server.js or npm run start: these will start node program in normal way.
      • npm run nodemon: this will start node program with nodemon, which monitors the project directory and automatically restarts your node application when it detects any changes.
    • Now, check the results in your localhost:
      • localhost:3003/

5. File Structure

The directory for this application is as follows:

  • ./assets: project workthrough video & supporting materials
  • ./config: this will allow you to connect to the mysql database
  • ./controllers: these javascript files will create (or define) each route's behavior
  • ./db: this will create a database, travel_db, with empty tables.
  • ./models: these javascript files will create Sequelize models for each table in travel_db
  • ./Public: css style files and additional javascript files
  • ./seeds: these javascript files will create (seed) tables in travel_db
  • ./utils: helper files to use handlebars
  • ./views: Express-Handlebars related files
  • ./env: Environmental variable definitions
  • ./.gitignore: specifies intentionally untracked files that Git should ginore
  • ./LICENSE: MIT License
  • ./package.json: specifics of npm's package.json handling
  • ./server.js: main node.js program Javascript file
  • ./README.md: readme file

6. Built With:

CSS JavaScript Node.js Sequelize MySQL npm Express Handlebars

Also used to build this application:

  • bcrypt
  • multer
  • Bulma

7. License

License: MIT

9. Screenshots

Homepage of Application

quiet-everglades-33653 herokuapp com_

Login Page - User will have to login to view Dashboard, create/edit/delete trips, or comment on trips

quiet-everglades-33653 herokuapp com_login

Register Page - User will have to register an account before accessing the Dashboard

quiet-everglades-33653 herokuapp com_#

Dashboard - Users will only see their trips and be able to create new trips, view trip details, edit their trip, or comment on the trip

quiet-everglades-33653 herokuapp com_dashboard

Edit or Delete Trip - From the Home or Dashboard page, Users can edit or delete an exisiting trip

Screen Shot 2023-02-16 at 10 36 39 PM

Comments - Users can view comments and comments on trips after logging in or registering

quiet-everglades-33653 herokuapp com_trip_5

View Trip Details - Users can view trip details once logged in

Screen Shot 2023-02-16 at 10 33 55 PM

Add Daily Trip Notes - Users can add daily trip notes and upload photos to their daily trip notes

quiet-everglades-33653 herokuapp com_api_trip-details_1_add-daily

Screen Shot 2023-02-16 at 10 36 11 PM

10. Credits

  • Torre for all the support in getting our application running.
  • Jason, Awais, Bradley, and Walter for answering all of our questions and letting us stay late to finish things up for the night.

11. Questions?:

If you have any questions, feel free to contact one of our team members via information below:

About

Travel Blog that allows users to keep track of their trips and see other users trips. It also allows you to keep a daily log while on vacation and upload images.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published