Modify create button to do more than create
Am I doing this right?
I want to create the record, but also go to the checkout page.
4 Replies
Oh yeah, smart
protected function getRedirectUrl(): string
{
return redirect()->route('create.checkout.session', ['amount' => $amount]); } how do i reference the amount though? i tried $amount = $this->amount but it didn't work
return redirect()->route('create.checkout.session', ['amount' => $amount]); } how do i reference the amount though? i tried $amount = $this->amount but it didn't work
$this->record
or $this->data
i assume π€$this->record->amount