import 'package:aman_kassa_flutter/core/models/dict_dao.dart';
import 'package:aman_kassa_flutter/core/models/product_dao.dart';
import 'package:meta/meta.dart';

@immutable
class KassaState {
  final List? bottomSheetElements;
  final bool? bottomSheetLoading;
  final List<DictDao>? prevCategories;
  final List<ProductDao>? kassaItems;


  KassaState(
      {this.bottomSheetElements,
      this.bottomSheetLoading,
      this.prevCategories,
      this.kassaItems,
      });

  factory KassaState.initial() => KassaState(
        bottomSheetElements: [],
        bottomSheetLoading: false,
        prevCategories: [],
        kassaItems: [],
      );

  KassaState copyWith({
    @required bottomSheetElements,
    @required bottomSheetLoading,
    @required prevCategories,
    @required kassaItems,
  }) {
    return KassaState(
      bottomSheetElements: bottomSheetElements ?? this.bottomSheetElements,
      bottomSheetLoading: bottomSheetLoading ?? this.bottomSheetLoading,
      prevCategories: prevCategories ?? this.prevCategories,
      kassaItems: kassaItems ?? this.kassaItems,
    );
  }
}
