Developer Guide
SimplePOS v5 is developed using Laravel, Inertiajs & Vuejs. The main page contents can be changed by editing app/Http/Controllers/HomeController.php
Code Modifications
You can modify the PHP (Laravel) code as you need. If you modify the front-end code (Vuejs), Javascript resources/js/ you will need to rebuild the app using npm run build after installing the dependencies with npm i
For development, you can use npm run dev and once all modifications done build the production version with npm run build before deploying to your server.
Laravel
You can find the Laravel docs at https://laravel.com/docs
Inertiajs
You can find the Inertia docs at https://inertiajs.com/
Vuejs
You can find the Vuejs docs at https://vuejs.org/guide
The vuejs app code is in the resources/js/ folder. The page views are in the resources/js/Pages/ folder while the layout files are in the 'resources/js/Layouts/'
The helping file/functions are in the resources/js/Core/ folder while the side bar menus are defined in the resources/js/Core/menu.js file.
Adding Language
You can add language by following these steps.
- Duplicate
lang/en.jsonandlang/en/to your language then translate - Edit
lang/languages.jsonand add your language entry - Build the application
npm i && npm run build
Setup CRON Job
As you know that SimplePOS is developer using Laravel. So, when using Laravel's scheduler, we only need to add a single cron configuration entry to our server that runs the schedule:run command every minute.
* * * * * php /path/to/upload/folder/artisan schedule:run >> /dev/null 2>&1Running locally
The command below will run in the foreground and invoke the scheduler every minute until you terminate the command:
php artisan schedule:workQueue Configuration
Laravel allows you to easily create queued jobs that may be processed in the background. By moving time intensive tasks to a queue, your application can respond to web requests with blazing speed and provide a better user experience for you and your customers.
Laravel's queue configuration options are stored in your application's config/queue.php configuration file. You can set QUEUE_CONNECTION in the .env file. You can setup one of the following drivers:
sync, database, beanstalkd, sqs, redis
On cPanel you can add QUEUE_ENABLE=false in your .env file and setup the cron job as following
php /path/to/upload/folder/artisan queue:work --stop-when-emptyRunning locally
The command below will start a queue worker and process new jobs as they are pushed onto the queue.
php artisan queue:workNote that once the queue:work command has started, it will continue to run until it is manually stopped or you close your terminal.
Modify item code at your own risk
We don't offer support for modifications and modified versions. You are allowed to modify the item code as per license at your own risk.