From f6e9464f5c207d8b672dd3605b707d8431a254b5 Mon Sep 17 00:00:00 2001 From: Abby Date: Mon, 21 Mar 2022 00:13:10 -0700 Subject: [PATCH 1/2] Fix location for where model is generated With new backpack versions using newer Laravel version and they have the different location should be adjusted to that. Perhaps could add in an option to use the old location but Backpack:Crud-Model puts it in the 'App\Models' folder. --- src/Console/Commands/ModelBackpackCommand.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Console/Commands/ModelBackpackCommand.php b/src/Console/Commands/ModelBackpackCommand.php index a94f6b9..8bc404b 100644 --- a/src/Console/Commands/ModelBackpackCommand.php +++ b/src/Console/Commands/ModelBackpackCommand.php @@ -57,7 +57,7 @@ protected function getStub() */ protected function getDefaultNamespace($rootNamespace) { - return $rootNamespace; + return $rootNamespace.'\Test'; } /** From 4dd4962def6af102dae651c06c1572e96b94a60d Mon Sep 17 00:00:00 2001 From: Abby Date: Wed, 23 Mar 2022 14:14:23 -0700 Subject: [PATCH 2/2] Update src/Console/Commands/ModelBackpackCommand.php my bad. Co-authored-by: Cristian Tabacitu --- src/Console/Commands/ModelBackpackCommand.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Console/Commands/ModelBackpackCommand.php b/src/Console/Commands/ModelBackpackCommand.php index 8bc404b..2ca7cca 100644 --- a/src/Console/Commands/ModelBackpackCommand.php +++ b/src/Console/Commands/ModelBackpackCommand.php @@ -57,7 +57,7 @@ protected function getStub() */ protected function getDefaultNamespace($rootNamespace) { - return $rootNamespace.'\Test'; + return $rootNamespace.'\Models'; } /**