Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Trip Data App

A full-stack web application for managing trip records. Users can view, filter, create, update, and delete trip data, including driver name, trip date, miles driven, miles per gallon (MPG), and other related information.

The application uses server-side HTML templating with Nunjucks and stores data in MongoDB using Mongoose.

Features

  • View all trip records
  • Filter trips by various criteria
  • Add new trip entries
  • Edit existing trip information
  • Delete trip records
  • Server-side rendering with Nunjucks
  • Persistent storage with MongoDB

Technologies Used

  • Node.js
  • Express.js
  • BootStrap
  • MongoDB
  • Mongoose
  • Nunjucks
  • HTML
  • CSS
  • JavaScript

Prerequisites

Before running the application, make sure you have installed:

  • Node.js
  • npm (included with Node.js)
  • MongoDB

Installation

  1. Clone the repository:

    git clone https://github.com/yourusername/trip-data-app.git

  2. Navigate to the project folder:

    cd trip-data-app

  3. Install dependencies:

    npm install

  4. Start MongoDB on your computer.

  5. Import the trip data from trips.json into MongoDB:

    mongoimport --db tripdata --collection trips --file trips.json --jsonArray

  6. Start the application:

    node index.js

  7. Open your browser and go to:

    http://localhost:3000

Usage

After starting the application, you can:

  • Browse all trip records
  • Search or filter trips
  • Create new trips
  • Update existing entries
  • Delete trips

Screenshots

Trip List

Trip List

Add Trip Form

Add Trip Form

#Future Improvements

  • User authentication
  • Summary statistics (total miles, average MPG)
  • Data export to CSV
  • Deployment to a cloud hosting service

#Author

Harvey Reid

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages