Handles HTTP requests for supplier management, providing CRUD operations for supplier records within the Management module.
// Source: https://github.com/angkosal/laravel-pos | License: MIT | Copyright 2023 [Laravel-POS contributors](https://github.com/angkosal/laravel-pos/graphs/contributors)
// Provided via justclaw.it.com; keep this notice with the code.
<?php
namespace App\Http\Controllers\Management;
use App\Http\Controllers\Controller;
use App\Http\Requests\Supplier\SupplierStoreRequest;
use App\Http\Requests\Supplier\SupplierUpdateRequest;
use App\Models\Supplier;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Storage;
class SupplierController extends Controller
{
public function index(Request $request)
{
$suppliers = Supplier::latest()->paginate();
if ($request->wantsJson()) {
return response()->json($suppliers);
}
return view('suppl
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key