Skip to content

Commit 050293f

Browse files
committed
Document Project
1 parent 55b6d83 commit 050293f

File tree

7 files changed

+207
-0
lines changed

7 files changed

+207
-0
lines changed

LICENSE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2024 PlanASlot
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 186 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,186 @@
1+
# PlanASlot
2+
3+
<img src="res/logo.webp" alt="PlanASlot logo" width="45" height="45">
4+
5+
PlanASlot is an easy to use planner, minimalist and efficient. Used to schedule individual slots of time for different events, it's ideal schedule individual meetings, appointments, interviews, etc. Turnkey solution for scheduling for small businesses, freelancers, teachers, students, etc.
6+
7+
---
8+
9+
> PlanASlot was an opportunity for me to try building a shortnotice project from scratch under 10 hours !
10+
11+
---
12+
13+
<img src="res/register.png">
14+
15+
---
16+
17+
## Table of contents
18+
19+
- [Features](#features)
20+
- [Installation](#installation)
21+
- [Docker](#docker)
22+
- [Development](#development)
23+
- [Requirements](#requirements)
24+
- [Server](#server)
25+
- [Client](#client)
26+
- [Database](#database)
27+
- [Future improvements](#future-improvements)
28+
- [License](#license)
29+
30+
---
31+
32+
## Features
33+
34+
- **Minimalist**: Simple and easy to use.
35+
- **Efficient**: Quickly schedule slots of time.
36+
- **Customizable**: Customize the time slots and the number of slots.
37+
- **No subscription**: Free to use, no subscription required.
38+
39+
---
40+
41+
### Easily schedule one or more events
42+
43+
<img src="res/create.png">
44+
45+
You can easily schedule one or more events by selecting the date, time, and duration of each slots for the event. You can also customize the time slots, the number of slots and also a termination date for the event where users will only be able to check in read-only mode their reservations.
46+
47+
---
48+
49+
<img src="res/consult.png">
50+
51+
Have a simple, minimalist and efficient view of your schedule. You can easily see the slots of time for each event.
52+
53+
You can also quickly copy the generated link to share it with your contacts.
54+
55+
### Your user is lost ?
56+
57+
<img src="res/nothere.png">
58+
59+
No problem, the default page helps the user to understand the purpose of the application and how to use it.
60+
61+
---
62+
63+
## Installation
64+
65+
> The server is written in TypeScript and uses the Express.js framework. The client is written in TypeScript and uses the Angular framework with PrimeNG components.
66+
67+
### Docker
68+
69+
**The whole application is dockerized.**
70+
71+
1. Clone the repository
72+
2. Setup the environment variables in the `.env` file
73+
3. Run `docker-compose up -d`
74+
75+
You're good to go !
76+
77+
### Development
78+
79+
#### Requirements
80+
81+
| Requirement | Version |
82+
| ----------- | ------- |
83+
| Node.js | >=18.x |
84+
| npm | >=10.x |
85+
| Angular | >=18.x |
86+
87+
#### Server
88+
89+
```bash
90+
cd server
91+
npm install # Install all the dependencies
92+
npm run dev # Start the server in development mode
93+
94+
# Or if you want to build the server
95+
npm run build
96+
```
97+
98+
#### Client
99+
100+
```bash
101+
cd client
102+
npm install # Install all the dependencies
103+
ng serve # Start the client in development mode
104+
105+
# Or if you want to build the client
106+
ng build
107+
```
108+
109+
#### Database
110+
111+
Database schema:
112+
113+
```sql
114+
CREATE TABLE IF NOT EXISTS Events (
115+
Id_Event VARCHAR(28),
116+
name VARCHAR(100) NOT NULL,
117+
startDatetime TIMESTAMP NOT NULL,
118+
endDatetime TIMESTAMP NOT NULL,
119+
PRIMARY KEY(Id_Event)
120+
);
121+
122+
CREATE TABLE IF NOT EXISTS Registrations (
123+
Id_Registration SERIAL,
124+
email VARCHAR(320) NOT NULL,
125+
firstname VARCHAR(50) NOT NULL,
126+
lastname VARCHAR(50) NOT NULL,
127+
registerDatetime TIMESTAMP NOT NULL,
128+
PRIMARY KEY(Id_Registration)
129+
);
130+
131+
CREATE TABLE IF NOT EXISTS Slots (
132+
Id_Booking SERIAL,
133+
startDatetime TIMESTAMP NOT NULL,
134+
endDatetime TIMESTAMP NOT NULL,
135+
Id_Event VARCHAR(28) NOT NULL,
136+
Id_Registration INTEGER,
137+
PRIMARY KEY(Id_Booking),
138+
FOREIGN KEY (Id_Event) REFERENCES Events(Id_Event),
139+
FOREIGN KEY (Id_Registration) REFERENCES Registrations(Id_Registration)
140+
);
141+
142+
CREATE VIEW IF NOT EXISTS view_event_registrations AS
143+
SELECT
144+
e.Id_Event,
145+
e.startDatetime,
146+
e.endDatetime,
147+
r.Id_Registration,
148+
r.email,
149+
r.firstname,
150+
r.lastname,
151+
r.registerDatetime,
152+
s.Id_Booking,
153+
s.startDatetime as slotStartDatetime,
154+
s.endDatetime as slotEndDatetime
155+
FROM Events e
156+
JOIN Slots s ON e.Id_Event = s.Id_Event
157+
JOIN Registrations r ON s.Id_Registration = r.Id_Registration
158+
```
159+
160+
The database is a PostgreSQL database. You can use the `docker-compose.yml` file to start a PostgreSQL database.
161+
162+
```bash
163+
docker-compose up -d
164+
165+
# Stop the other services except the database
166+
docker-compose stop server client
167+
```
168+
169+
---
170+
171+
## Future improvements
172+
173+
- [ ] Add a notification/confirmation system
174+
- [ ] Export the schedule to a CSV file
175+
176+
...
177+
178+
Feel free to contribute to the project by opening a pull request, or ask for a feature by opening an issue, I'd be glad to take this project further if there is interest.
179+
180+
> Also feel free to ask if you need any help to setup the project.
181+
182+
---
183+
184+
## License
185+
186+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

res/consult.png

49.8 KB
Loading

res/create.png

32.5 KB
Loading

res/logo.webp

99.5 KB
Loading

res/nothere.png

32.1 KB
Loading

res/register.png

57 KB
Loading

0 commit comments

Comments
 (0)