PHP code example of kz370 / krayin-multi-tenancy
1. Go to this page and download the library: Download kz370/krayin-multi-tenancy library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
kz370 / krayin-multi-tenancy example snippets
bash
php artisan vendor:publish --tag=krayin-multi-tenancy-config
php artisan vendor:publish --tag=krayin-multi-tenancy-migrations
bash
php artisan migrate
php artisan krayin-crm:install
sql
GRANT ALL PRIVILEGES ON `krayin_%`.* TO 'krayin_tenant_user'@'%';
FLUSH PRIVILEGES;
bash
php artisan tenants:migrate