MVC application (PHP/MySQL)
A client deals with lots of physical documents. The application should store
digital copies of that documents as well as the following information for
each document:
The application should provide the possibility to create, read, update,
delete, and search for document records, as well as to upload and download
digital copies of the documents.
New users should be able to sign up. Registered users should be able to
access the application using their usernames and passwords.
Authenticated users should be able to upload and download files, create, read,
and search for document records. They should be authorized to update and
delete only the records they created.
The original implementation of this project dates back to 2018 - it happened to be my very first PHP project.
Since then, my skills and preferences naturally evolved, so I decided to make a rebuild, changing a lot but preserving the original spirit:
Here are some of the changes that come with the rebuild:
For “then and now” kind of thing, the old code is still available in the xampp branch.
ddev start
ddev import-db --file=_db/dump.sql
ddev storage-link
# Start containers (will also trigger the composer install)
ddev start
# If you make changes to the .ddev/config.yaml
ddev restart
# Import the database from the dump file
ddev import-db --file=<filename>.sql
# Open the application in the browser
ddev launch
# Open the database GUI in the browser
ddev phpmyadmin
# Symlink the storage directory to the public directory
ddev storage-link
# Lint the code
ddev exec './vendor/bin/php-cs-fixer fix'
# Stop containers
ddev stop