@if (isLoading) {
}
Brand Management
@if (brands$ | async; as brands) { @if (brands.length > 0 || selectedBrand) {
Brand ID
Name
Branch ID
Branch Name
Image
Created By
Actions
@if (selectedBrand && !selectedBrand.id) {
Auto-generated
New Brand
-
-
-
Auto
} @for (brand of brands; track trackByFn($index, brand)) {
{{ brand.brand_id }}
{{ brand.name }}
{{ brand.branch_id }}
{{ brand.branch_name }}
@if (brand.image) { } @else {
}
{{ brand.created_by_username || 'N/A' }}
@if (selectedBrand?.id === brand.id) {
} }
} @else {

### No brands found

Get started by creating your first brand

} }

## {{ brand.id ? 'Edit Brand' : 'Create New Brand' }}

@if (brand.brand_id) {

Brand ID: {{ brand.brand_id }}

} @else {

Brand ID will be auto-generated from name (first 3 letters + 4-digit sequence)

}
Brand Name Name is required Minimum 2 characters required ID will be: {{ previewBrandId }} Branch {{ branch.name }} ({{ branch.branch_id }}) Branch is required Branch will be auto-filled Branch ID Auto-filled from branch selection Branch Name Auto-filled from branch selection @if (brand.id && brand.created_by_username) { Created By }
Brand Image (Optional)
@if (imagePreview || brand.image) { } @else {
}
Upload Image

PNG, JPG, GIF up to 5MB

@if (imagePreview || brand.image) {
}
@if (brand.id) {
Created: {{ brand.created_at | date:'medium' }}
@if (brand.updated_at && brand.updated_at !== brand.created_at) {
Last Updated: {{ brand.updated_at | date:'medium' }}
}
}
@if (flashMessage) {
@if (flashMessage === 'success') { {{ brand.id ? 'Updated' : 'Created' }} successfully } @if (flashMessage === 'error') { Error occurred }
}