The application also demonstrates how to upload a large Excel file to a database. This feature uses laravel excel package. The package helps us to validate the user input and load the file in a queue. Hence suited to upload a large file into a database.
- Clone this repository.
cd
into it.- Install Composer Dependencies.
composer install
- Install NPM Dependencies.
npm install
- Copy
.env.example
file to.env
- Generate an app encryption key.
php artisan key:generate
- Set up your database credentials then run
php artisan migrate
to create the tables. - Set up queue for file upload: I recommend redis queue driver on
.env
file. - Use the
php artisan queue:work
to start a queue worker and process new jobs as they are pushed onto the queue. php artisan serve
- Visit
localhost:8000
in your browser.