Skip to content

A Hair Salon webapp built in java, using the spark framework and velocity to render html, junit to test, and postgres to store data.

Notifications You must be signed in to change notification settings

thejensen/java_hair-salon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fLawless | Hair Salon

An app for hair salon employees to schedule clients, Sept 23, 2016

By Sara Jensen

Description

The owner of the hair salon may add a list of stylists, and for each stylist, add clients who see that stylist. The stylists work independently, so each client only belongs to a single stylist.

Setup/Installation Requirements

To run app locally:

Next, recreate the hair-salon database in PSQL:

  • Make sure postgres is running by executing $postgres, then...
  • $psql
  • CREATE DATABASE hair_salon;
  • \c hair_salon
  • CREATE TABLE stylists (id serial PRIMARY KEY, name varchar, description varchar);
  • CREATE TABLE clients (id serial PRIMARY KEY, name varchar, description varchar, stylist_id int);
  • _CREATE DATABASE hair_salon_test WITH TEMPLATE hair_salon;

Finally, we can run the app by...

  • In a new terminal tab (or "ctrl c" out of psql) execute $gradle run
  • In your browser (preferably latest version of Chrome), go to localhost:4567.

User Stories

  • As a salon employee, I need to be able to see a list of all our stylists.
  • As an employee, I need to be able to select a stylist, see their details, and see a list of all clients that belong to that stylist.
  • As an employee, I need to add new stylists to our system when they are hired.
  • As an employee, I need to be able to add new clients to a specific stylist.
  • As an employee, I need to be able to update a stylist's details.
  • As an employee, I need to be able to update a client's details.
  • As an employee, I need to be able to delete a stylist if they're no longer employed here.
  • As an employee, I need to be able to delete a client if they no longer visit our salon.

Specifications

Behavior Input Output
Program returns a list of stylists Dana, Marilyn, Javier Dana, Marilyn, Javier
Program returns the details and client list of a particular stylist Dana Dana; Specializes in braids and curly hair; Kahlief Adams, Jill Adams, Megan O'Leary
Program stores/returns new stylists Trevor Dana, Marilyn, Javier, Trevor
Program stores/returns new clients added to the stylist client list Dana; Ero Gray Dana; Kahlief Adams, Jill Adams, Megan O'Leary, Ero Gray
Program updates existing details for a stylist Specializes in updos Dana; Specializes in updos
Program stores client details Kahlief Adams; Male prefers short and faded cut Kahlief Adams; male prefers short and faded cut
Program edits client details Male growing out cut Kahlief Adams; Male growing out cut
Program deletes stylist from database -Dana Marilyn, Javier, Trevor
Program deletes client from stylist list -Kahlief Adams Jill Adams, Megan O'Leary, Ero Gray

Known Bugs

  • Navbar content not available in mobile sizing.
  • hair gallery photos misaligned in mobile sizing.

Support and contact details

If you run into any issues, have questions, ideas or concerns, or want to make a contribution to the code, contact me at [email protected].

Technologies Used

Java, Spark, Velocity, jUnit, Postgres/PSQL.

Future Development

  • Include a form where users may search for a stylist by name. Use a SQL query to perform the database search, then display a list of all results.
  • Include a form where users may also search for a client by name. Use a SQL query to perform the database search, then display a list of all results.
  • Add a drop down field that allows a user to select which Stylist a Client belongs to. Add a detail view page for each Client. Include additional properties to record additional notes and details the salon may want to record about each Client. Delete and update confirmation messages. License Copyright (c) 2016 MIT License

About

A Hair Salon webapp built in java, using the spark framework and velocity to render html, junit to test, and postgres to store data.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published