mamdouhkhaled/tenancy-modules

Connect Laravel Tenancy with Laravel Modules

Installs: 120

Dependents: 0

Suggesters: 0

Security: 0

Stars: 5

Watchers: 1

Forks: 2

Open Issues: 0

pkg:composer/mamdouhkhaled/tenancy-modules

v2.0.0 2025-11-29 19:18 UTC

This package is auto-updated.

Last update: 2025-11-29 19:21:05 UTC


README

composer require mamdouhkhaled/tenancy-modules

Create Table for manage Modules with Tenancy

php artisan tenancy:install // fresh install only
php artisan migrate

Published Configuration

php artisan vendor:publish --tag=tenancymodules

Enable / Disable modules Commands

php artisan module:tenant-enable --tenant={{tenant-id}} // enable all modules for this tenant
php artisan module:tenant-enable {{module_name}} --tenant={{tenant-id}} // enable `module_name` modules for this tenant

php artisan module:tenant-disable --tenant={{tenant-id}} // enable all modules for this tenant
php artisan module:tenant-disable {{module_name}} --tenant={{tenant-id}} // enable `module_name` modules for this tenant

Migration / rollback Commands

php artisan module:tenant-migrate --tenants={{tenant-id}}// tenant is comma separated
php artisan module:tenant-migrate --tenants={{tenant-id}} {{module}}

php artisan module:tenant-migrate-rollback --tenants={{tenant-id}}
php artisan module:tenant-migrate-rollback --tenants={{tenant-id}} {{module}}

Seed Commands

this Command Run {module}TenantDatabaseSeeder

php artisan module:tenant-seed --tenants={{tenant-id}}// tenant is comma separated
php artisan module:tenant-seed --tenants={{tenant-id}} {{module}}

Route

as tenant way

Contributing

Thank you for considering contributing to the Laravel Tenancy Modules Package!

License

The Laravel framework is open-sourced software licensed under the MIT license.