Coder Social home page Coder Social logo

vladdovgal / transportation-system Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 1.0 21.07 MB

Simple CRUD application for accounting of postal traffic (personal project for Epam University)

Home Page: https://transportation-system-project.herokuapp.com/ParcelServlet.do?action=listParcels

Java 95.16% CSS 3.72% JavaScript 1.12%
parcels epam-university crud-application java postal-network student-project servlet-jsp

transportation-system's Introduction

Transportation system

It is simple CRUD application designed to store data on parcels, as well as on cities that are part of the postal network.

Application is being deployed on Heroku : https://transportation-system-project.herokuapp.com/ParcelServlet.do?action=listParcels

Application features:

  • Read information about all parcels, add new parcels;
  • Edit and Delete existing parsels;
  • Change status of parcel (Arrived, Departed, In the way);
  • View additional information (as time when parcel was created or updated last time);
  • Add / Edit / Delete cities of thhe postal network;
  • Read event logs (on separate page) and clear logs;
  • Order parcels by parameters: - ID, CitySender, CityRecipient, Weight, Status;
  • Logs are written to database, console and file.

Personal project task for Epam University.

Technologies stack

  • Java
  • MySQL 8.5, JDBC
  • Log4j 2
  • Servlet API 3.0
  • Stream API
  • Bootstrap 4

Pattern: MVC (View layer is represented by Java Server Pages).

How it looks:

image image

How to run

  1. Run SQL queries from 'transportation-system/src/main/resources/sql/queries.sql' file: :
CREATE DATABASE transportation;
USE transportation ;
CREATE TABLE parcels (
	parcelId VARCHAR (15) NOT NULL,
    	senderName VARCHAR(25) DEFAULT NULL,
    	recipientName VARCHAR(25) DEFAULT NULL,
    	startCity VARCHAR(20) DEFAULT NULL,
	endCity VARCHAR(20) DEFAULT NULL,
    	weight FLOAT(5) DEFAULT 1,
    	status varchar(20) default NULL,
    	timeCreated timestamp default CURRENT_TIMESTAMP,
    	timeUpdated timestamp ON UPDATE CURRENT_TIMESTAMP,
    	PRIMARY KEY(parcelID)
);


CREATE TABLE cities(
	cityId int(8) not null auto_increment,
    	cityName varchar(25) DEFAULT NULL,
    	cityAlias varchar(25) DEFAULT NULL,
    	PRIMARY KEY(cityId)
);

CREATE TABLE LOGS(
    	DATED   VARCHAR(40)    NOT NULL,
    	LOGGER  VARCHAR(50)    NOT NULL,
    	LEVEL   VARCHAR(10)    NOT NULL,
    	MESSAGE VARCHAR(1000)  NOT NULL
);


Run code in 'resources/sql/test-data.sql' to fill database with test data;

Connect to DB using username and password.

  1. Add new (or use existing) Tomcat Server Run Configuration.

Built artifact: trasportation-system:war exploded.

Set URL target: http://localhost:8080/transportation_system_war_exploded/ParcelServlet.do?action=listParcels.

  1. Run Tomcat Server.

  2. Open next link if target URL is not set:

http://localhost:8080/transportation_system_war_exploded/ParcelServlet.do?action=listParcels

transportation-system's People

Contributors

vladdovgal avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.