I have two controllers (Workflow and Stage), I need to route to Stage.store function from the Workflow.store function using a request object I have been created :
Workflow controller:
public function store(WorkflowRequest $request)
{
$oWorkflow = new WfWorkflow();
$oWorkflow->name = $request->get('workflow_name');
if($oWorkflow->save()){
$aStages = $request->get('wf_stage');
$params = [
'_token' => $request->get('_token'),
'wf_id' => $oWorkflow->id,
'stages' => $aStages
];
$oStageRequestObject = Request::create(url('stage'), 'POST', $params);
}
}
Now, how can i use the Request object $oStageRequestObject to route to stage.store using POST method ?
- In
stage.storei need to use form request validation.