open-developer-ext / config
Config extension for open-developer, thanks to z-song
v1.0.4
2023-08-14 13:25 UTC
Requires
- php: >=7.0.0
- laravel/framework: >=7.0
- open-developer/open-developer: >=1.0.4
Requires (Dev)
- laravel/laravel: ~7.0
- phpunit/phpunit: ~6.0
README
Config manager for open-developer
Screenshot
Installation
composer require open-developer-ext/config
php artisan migrate
Open app/Providers/AppServiceProvider.php
, and call the Config::load()
method within the boot
method:
<?php namespace App\Providers; use OpenDeveloper\Developer\Config\Config; use Illuminate\Support\Facades\Schema; use Illuminate\Support\ServiceProvider; class AppServiceProvider extends ServiceProvider { public function boot() { $table = config('developer.extensions.config.table', 'developer_config'); if (Schema::hasTable($table)) { Config::load(); } } }
Then run:
php artisan developer:import config
Open http://your-host/developer/config
Usage
After add config in the panel, use config($key)
to get value you configured.