feat: Implement comprehensive product management, including categories, pricing, and integration into the order system.
This commit is contained in:
@@ -40,8 +40,8 @@ class ProductController extends Controller
|
||||
{
|
||||
$step = $request->get('step') ?? 1;
|
||||
$title = 'Add new product';
|
||||
// Fetch Product Categories instead of generic groups
|
||||
$group = \App\Models\ProductCategories::where('is_active', \App\Enums\Status::ACTIVE->value)->get();
|
||||
// Fetch Product Categories (Roots only, children via relation)
|
||||
$group = \App\Models\ProductCategories::where('is_active', \App\Enums\Status::ACTIVE->value)->whereNull('parent_id')->get();
|
||||
$type = null;
|
||||
|
||||
// Fetch OS versions with their group for the OS selector component
|
||||
@@ -91,7 +91,7 @@ class ProductController extends Controller
|
||||
$product->load(['pricings', 'osVersions', 'category']);
|
||||
|
||||
$title = 'Edit product: ' . $product->name;
|
||||
$group = \App\Models\ProductCategories::where('is_active', \App\Enums\Status::ACTIVE->value)->get();
|
||||
$group = \App\Models\ProductCategories::where('is_active', \App\Enums\Status::ACTIVE->value)->whereNull('parent_id')->get();
|
||||
$type = null;
|
||||
|
||||
// Fetch OS versions for select
|
||||
|
||||
Reference in New Issue
Block a user