mascam97 / php-school-rollcall

Website for attendance optimization in a generic school.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PHP School Rollcall Status Passing Docker build

Website for attendance optimization in a generic school.

Project goal by mascam97

This was a project developed with vanilla PHP in a subject when I was student. Now I refactored all the project with better practices (MVC, Composer, etc), similar to professional framework.

Due to this project does not have testing, is not deployed anymore and does not have more purposes, is no longer maintained.

Achievements 🌟

  • Configured composer to respect PSR4 standard.
  • Installed third party packages and respect PSR7 standard.
  • Implemented Model-View-Controller pattern and Front Controller.
  • Implemented a basic ORM using OOP and SQL queries.
  • Implemented Twig in order to have better views.
  • Improved the URLs (/rolecall/{class_room_id} instead of /rolecall?class_room_id=*).
  • Implemented libraries for database management (migrations and seeders).
  • Improved the design, palette colors and HTML semantic.
  • Implemented docker compose for a better environment.

Getting Started 🚀

These instructions will get you a copy of the project up and running on your local machine.

Prerequisites 📋

The programs you need are:

Installing 🔧

First duplicate the file .env.example as .env.

cp .env.example .env

Note: You could change some values, anyway docker-compose create the database according to the defined values.

Create the image (php:7.4-composer-npm) and run the services (php, nginx and mysql):

docker-compose up

Note: You can run the last command in the background with docker-compose up -d.

Now you have all the environment ready, for the next commands you need to be inside of the app container with:

docker-compose exec app /bin/bash

Then install the PHP packages.

composer install

Finally generate the database and fill it with testing data:

vendor/bin/phinx migrate
vendor/bin/phinx seed:run

And now you have all the environment in the port 8000.

Note: Use exit command to exit from the container, docker-compose down to delete the containers and docker volume rm php-school-rollcall_mysql to delete the database volume.


Functionality ⚙️

  • In the login there are the ids and password by default to log in.
  • Administrator can watch all the users.
  • Students can watch its class rooms and its attendances.
  • Teachers can watch its class rooms, pass the role and edit an attendance.

Authors

Contributing

You're free to contribute to this project by submitting issues and/or pull requests.

License

This personal project is licensed under the MIT License.

References 📚

About

Website for attendance optimization in a generic school.


Languages

Language:PHP 75.5%Language:Twig 17.7%Language:CSS 5.2%Language:Dockerfile 1.6%