Closed almasaeed2010 closed 3 years ago
You should be able to change the location by updating the namespace
variable under model. path
is mostly for file without namespace.
Thanks for the response @crynobone
I tried your suggestion as shown below. However, the model generated still goes to src/
and not src/Models
even though the namespace generated in the new model is correct (namespace Acme\Package\Models;
).
model:
namespace: Acme\Package\Models
can you share the full canvas.yaml
file
Here is the file
preset: package
namespace: Acme\Package
user-auth-provider: App\User
paths:
src: src
resource: resources
factory:
path: src/Factories
migration:
path: src/Migrations
prefix: ''
console:
namespace: Acme\Package\Console
model:
namespace: Acme\Package\Models
provider:
namespace: Acme\Package
testing:
namespace: Acme\Package\Tests
middleware:
namespace: Acme\Package\Http\Middleware
Can you check whether the latest commit fixed the problem?
This should have been fixed.
Hello!
Quick question. Is there a way to specify where models should be placed when running
canvas make:model
? I tried addingpath: src/Models
to the yaml file but no luck there.Thanks in advance for the help!