@extends('layouts.app') @section('title', 'Edit Sale Post Category') @section('description', 'Update sale post category details') @section('content')

Edit Category

Update sale post category details

@csrf @method('PUT')
@error('name')

{{ $message }}

@enderror

Leave blank to auto-generate from category name

@error('slug')

{{ $message }}

@enderror
@error('description')

{{ $message }}

@enderror
@if($salePostCategory->icon)
{!! $salePostCategory->icon !!}
@endif

Enter an emoji (📱) or HTML for an icon

@error('icon')

{{ $message }}

@enderror

Select a parent to make this a subcategory

@error('parent_id')

{{ $message }}

@enderror
@error('status')

{{ $message }}

@enderror
@if($salePostCategory->children->count() > 0)

This category has {{ $salePostCategory->children->count() }} subcategories:

    @foreach($salePostCategory->children as $child)
  • {{ $child->name }}
  • @endforeach
@endif
Cancel

Danger Zone

Once you delete this category, there is no going back. @if($salePostCategory->children->count() > 0) Warning: This will also affect {{ $salePostCategory->children->count() }} subcategories. @endif

@csrf @method('DELETE')
@endsection