@extends('layouts.admin') @section('title', 'Create Sub Category') @section('content')

Create Sub Category

Add a new subcategory under "{{ $mainCategory->name }}"

Back to Categories
Creating subcategory for: {{ $mainCategory->name }}
{{ $mainCategory->description ?? 'No description available' }}
Sub Category Information
@csrf
@error('name')
{{ $message }}
@enderror
This will be automatically converted to a URL-friendly slug
@error('description')
{{ $message }}
@enderror
@error('image')
{{ $message }}
@enderror
Upload an image for this sub category (recommended: 300x200px, max 2MB)
Cancel
Guidelines
Example Subcategories:
    @if(stripos($mainCategory->name, 'food') !== false || stripos($mainCategory->name, 'restaurant') !== false)
  • • Burgers & Sandwiches
  • • Pizza & Italian
  • • Asian Cuisine
  • • Healthy & Vegan
  • @elseif(stripos($mainCategory->name, 'service') !== false)
  • • Beauty & Salon
  • • Repair & Maintenance
  • • Consultation
  • • Installation
  • @else
  • • Specific product types
  • • Service variations
  • • Target demographics
  • • Specialty offerings
  • @endif
Best Practices:
  • • Be more specific than the main category
  • • Use customer-friendly language
  • • Consider search behavior
  • • Avoid overlap with other subcategories
Tip: Subcategories help customers find exactly what they're looking for more quickly.
@if($mainCategory->subCategories && $mainCategory->subCategories->count() > 0)
Existing Subcategories
@foreach($mainCategory->subCategories->take(5) as $subCategory)
{{ $subCategory->name }}
@endforeach @if($mainCategory->subCategories->count() > 5)
... and {{ $mainCategory->subCategories->count() - 5 }} more
@endif
@endif
@endsection