Skip to content

Commit 592e81b

Browse files
committed
Added --requests -R flag to the related make:model command
1 parent 4f58e18 commit 592e81b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Illuminate/Foundation/Console/ModelMakeCommand.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ protected function createController()
133133
'name' => "{$controller}Controller",
134134
'--model' => $this->option('resource') || $this->option('api') ? $modelName : null,
135135
'--api' => $this->option('api'),
136+
'--requests' => $this->option('requests'),
136137
]));
137138
}
138139

@@ -205,6 +206,7 @@ protected function getOptions()
205206
['pivot', 'p', InputOption::VALUE_NONE, 'Indicates if the generated model should be a custom intermediate table model'],
206207
['resource', 'r', InputOption::VALUE_NONE, 'Indicates if the generated controller should be a resource controller'],
207208
['api', null, InputOption::VALUE_NONE, 'Indicates if the generated controller should be an API controller'],
209+
['requests', 'R', InputOption::VALUE_NONE, 'Create a new FormRequest class and use it in resource controller'],
208210
];
209211
}
210212
}

0 commit comments

Comments
 (0)