This app allows an administrator to manage employees and clients at a hair salon.
To download and use the source code of this project:
- Clone the project using this link:
https://gitlab.com/lydianlights-epicodus/csharp/hair-salon.git
- Install
.NET Core 1.1
. You can get it here. - An SQL server is required for this project. If you have no SQL server environment on your computer, you can get MAMP here
- Configure your server to listen on port 8889 and start it
- Once logged into your server, run the following SQL commands:
CREATE DATABASE rane_fields;
CREATE TABLE rane_fields.stylists (id INT NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, phone VARCHAR(255) NOT NULL, email VARCHAR(255) NOT NULL, PRIMARY KEY (id));
CREATE TABLE rane_fields.clients (id INT NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, phone VARCHAR(255) NOT NULL, stylist_id INT NOT NULL, PRIMARY KEY (id));
- Open the project directory
HairSalon.Solution/HairSalon
using terminal or powershell - From the directory
HairSalon.Solution/HairSalon
run the commanddotnet restore
to fetch the project dependencies. - The application can now compiled and started by using the command
dotnet run
. It will be hosted atlocalhost:5000
To set up the non-live database to test code against:
- First follow all previous installation instructions
- Login to your SQL server (once again using port 8889) and run the following commands:
CREATE DATABASE rane_fields_test;
CREATE TABLE rane_fields_test.stylists (id INT NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, phone VARCHAR(255) NOT NULL, email VARCHAR(255) NOT NULL, PRIMARY KEY (id));
CREATE TABLE rane_fields_test.clients (id INT NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, phone VARCHAR(255) NOT NULL, stylist_id INT NOT NULL, PRIMARY KEY (id));
- Open the project directory
HairSalon.Solution/HairSalon.Tests
using terminal or powershell - From the directory
HairSalon.Solution/HairSalon.Tests
run the commanddotnet restore
to fetch the project dependencies. - Tests can be run using the command
dotnet test
Project BDD specs can be found here.
This project is powered by the ASP .NET framework and uses the C# MySQL Connector Library for MySQL integration.
- Currently the 'client update' functionality requires unchanged fields to be reentered.
This page is hereby released as public domain. No permission necessary for modification and distribution.
Copyright (c) 2017 Rane Fields