I'm trying to build a small application on Laravel with modular approach, I am having a controller method which seeds the database as per the module/plugin name:
I have something like this:
Artisan::call('db:seed --class=Nitseditor\\Plugins\\'.$pluginName.'\\Databases\\seeds\\InstallSeeder');
Whenever I am calling this I am getting this error in my console.
Class NitseditorPluginsConfidenceDatabasesseedsInstallSeeder does not exist
I don't know why it remove \ and concatenate the strings.
How can I achieve this?
composer dump-autoload?composer dump-autoload. I created the seeder manually as it belongs to one of the modules in my application."db:seed --class=Nitseditor\Plugins\$pluginName\Databases\seeds\InstallSeeder"(quotes, not apostrophies)--class="Nitseditor\Plugins\XXX\Databases..."instead.Too many arguments, expected arguments "command".