cannot run migrate:fresh after setup
rasyidialwee opened this issue · 4 comments
hello i manage to install and use laravel-setting package. however when i try to run php artisan migrate:fresh
it show error
Base table or view not found: 1146 Table 'reacx.settings' doesn't exist (SQL: select
name,
payloadfrom
settingswhere
group = system)
Hi @rasyidialwee,
You should first publish the settings migration that was supplied with the package(https://github.com/spatie/laravel-settings/blob/master/database/migrations/create_settings_table.php.stub). Be sure to add this migration before any settings migration since this one will create the settings
table, the other settings migrations will only add items to this table.
got same problem and just wanna say thanks to dropping the fix !
If anyone come across this problem, checkout your backtrace from laravel.log to see which class is using the class and use class_exists(Setting::class)
to ensure the class exist before you call it !