Send invoices by email.
This commit is contained in:
@@ -3,14 +3,14 @@
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Invoice;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Contracts\View\View;
|
||||
|
||||
class InvoiceController extends Controller
|
||||
{
|
||||
/**
|
||||
* Display a listing of the resource.
|
||||
*/
|
||||
public function index()
|
||||
public function index(): View
|
||||
{
|
||||
return view('invoice.index');
|
||||
}
|
||||
@@ -18,7 +18,7 @@ class InvoiceController extends Controller
|
||||
/**
|
||||
* Show the form for creating a new resource.
|
||||
*/
|
||||
public function create()
|
||||
public function create(): View
|
||||
{
|
||||
return view('invoice.create');
|
||||
}
|
||||
@@ -26,7 +26,7 @@ class InvoiceController extends Controller
|
||||
/**
|
||||
* Display the specified resource.
|
||||
*/
|
||||
public function show(Invoice $invoice)
|
||||
public function show(Invoice $invoice): View
|
||||
{
|
||||
return view('invoice.show', ['invoice' => $invoice]);
|
||||
}
|
||||
@@ -38,4 +38,14 @@ class InvoiceController extends Controller
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Show the form for sending the specified invoice.
|
||||
*/
|
||||
public function mail(int $id): View
|
||||
{
|
||||
$invoice = Invoice::find($id);
|
||||
|
||||
return view('invoice.mail', ['invoice' => $invoice]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user