You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
topnotch_website/app/Http/Controllers/PackingSlipController.php

39 lines
952 B
PHTML

3 months ago
<?php
namespace App\Http\Controllers;
use App\Http\Requests\PackingSlipRequest;
use App\Models\Customer;
use App\Models\PackingSlip;
2 months ago
use Illuminate\Http\RedirectResponse;
3 months ago
use Illuminate\Http\Request;
class PackingSlipController extends Controller
{
2 months ago
public function index(): void {}
3 months ago
2 months ago
public function create(): void {}
3 months ago
2 months ago
public function store(PackingSlipRequest $request): RedirectResponse
3 months ago
{
PackingSlip::create($request->validated());
3 months ago
if ($request->get('from_customer')) {
3 months ago
return redirect()->route('customers.show', [
Customer::find($request->get('customer_id')),
3 months ago
'tab' => 'packing',
3 months ago
]);
}
return redirect()->back(); //todo: change to packing slips page
}
2 months ago
public function show($id): void {}
3 months ago
2 months ago
public function edit($id): void {}
3 months ago
2 months ago
public function update(Request $request, $id): void {}
3 months ago
2 months ago
public function destroy($id): void {}
3 months ago
}