part of 'chart_bloc.dart'; final class ChartState extends Equatable { final List transactions; final List transactionsLines; final double globalTotal; final Map accountsTotals; final DateTime? firstDate; final DateTime? lastDate; final num currentYear; final Map categoriesTotals; final List monthlyTotals; final Map> categoriesMonthlyTotals; final List scopedCategoriesPositiveTotals; final List scopedCategoriesPositiveTotalsPercents; final List scopedCategoriesNegativeTotals; final List scopedCategoriesNegativeTotalsPercents; final List scopedSimplifiedCategoriesPositiveTotals; final List scopedSimplifiedCategoriesPositiveTotalsPercents; final List scopedSimplifiedCategoriesNegativeTotals; final List scopedSimplifiedCategoriesNegativeTotalsPercents; final List scopedMonthlyTotals; final Map> scopedCategoriesMonthlyTotals; final double scoppedProfit; const ChartState({ this.transactions = const [], this.transactionsLines = const [], this.globalTotal = 0, this.accountsTotals = const {}, this.firstDate, this.lastDate, this.currentYear = 2000, this.categoriesTotals = const {}, this.monthlyTotals = const [], this.categoriesMonthlyTotals = const {}, this.scopedCategoriesPositiveTotals = const [], this.scopedCategoriesPositiveTotalsPercents = const [], this.scopedCategoriesNegativeTotals = const [], this.scopedCategoriesNegativeTotalsPercents = const [], this.scopedSimplifiedCategoriesPositiveTotals = const [], this.scopedSimplifiedCategoriesPositiveTotalsPercents = const [], this.scopedSimplifiedCategoriesNegativeTotals = const [], this.scopedSimplifiedCategoriesNegativeTotalsPercents = const [], this.scopedMonthlyTotals = const [], this.scopedCategoriesMonthlyTotals = const {}, this.scoppedProfit = 0, }); ChartState copyWith({ List? transactions, List? transactionsLines, double? globalTotal, Map? accountsTotals, DateTime? firstDate, DateTime? lastDate, num? currentYear, Map? categoriesTotals, List? monthlyTotals, Map>? categoriesMonthlyTotals, List? scopedCategoriesPositiveTotals, List? scopedCategoriesPositiveTotalsPercents, List? scopedCategoriesNegativeTotals, List? scopedCategoriesNegativeTotalsPercents, List? scopedSimplifiedCategoriesPositiveTotals, List? scopedSimplifiedCategoriesPositiveTotalsPercents, List? scopedSimplifiedCategoriesNegativeTotals, List? scopedSimplifiedCategoriesNegativeTotalsPercents, List? scopedMonthlyTotals, Map>? scopedCategoriesMonthlyTotals, double? scoppedProfit, }) { return ChartState( transactions: transactions ?? this.transactions, transactionsLines: transactionsLines ?? this.transactionsLines, globalTotal: globalTotal ?? this.globalTotal, accountsTotals: accountsTotals ?? this.accountsTotals, firstDate: firstDate ?? this.firstDate, lastDate: lastDate ?? this.lastDate, currentYear: currentYear ?? this.currentYear, categoriesTotals: categoriesTotals ?? this.categoriesTotals, monthlyTotals: monthlyTotals ?? this.monthlyTotals, categoriesMonthlyTotals: categoriesMonthlyTotals ?? this.categoriesMonthlyTotals, scopedCategoriesPositiveTotals: scopedCategoriesPositiveTotals ?? this.scopedCategoriesPositiveTotals, scopedCategoriesPositiveTotalsPercents: scopedCategoriesPositiveTotalsPercents ?? this.scopedCategoriesPositiveTotalsPercents, scopedCategoriesNegativeTotals: scopedCategoriesNegativeTotals ?? this.scopedCategoriesNegativeTotals, scopedCategoriesNegativeTotalsPercents: scopedCategoriesNegativeTotalsPercents ?? this.scopedCategoriesNegativeTotalsPercents, scopedSimplifiedCategoriesPositiveTotals: scopedSimplifiedCategoriesPositiveTotals ?? this.scopedSimplifiedCategoriesPositiveTotals, scopedSimplifiedCategoriesPositiveTotalsPercents: scopedSimplifiedCategoriesPositiveTotalsPercents ?? this.scopedSimplifiedCategoriesPositiveTotalsPercents, scopedSimplifiedCategoriesNegativeTotals: scopedSimplifiedCategoriesNegativeTotals ?? this.scopedSimplifiedCategoriesNegativeTotals, scopedSimplifiedCategoriesNegativeTotalsPercents: scopedSimplifiedCategoriesNegativeTotalsPercents ?? this.scopedSimplifiedCategoriesNegativeTotalsPercents, scopedMonthlyTotals: scopedMonthlyTotals ?? this.scopedMonthlyTotals, scopedCategoriesMonthlyTotals: scopedCategoriesMonthlyTotals ?? this.scopedCategoriesMonthlyTotals, scoppedProfit: scoppedProfit ?? this.scoppedProfit, ); } @override List get props => [ transactions, transactionsLines, globalTotal, accountsTotals, currentYear, categoriesTotals, monthlyTotals, categoriesMonthlyTotals, scopedCategoriesPositiveTotals, scopedCategoriesPositiveTotalsPercents, scopedCategoriesNegativeTotals, scopedCategoriesNegativeTotalsPercents, scopedSimplifiedCategoriesPositiveTotals, scopedSimplifiedCategoriesPositiveTotalsPercents, scopedSimplifiedCategoriesNegativeTotals, scopedSimplifiedCategoriesNegativeTotalsPercents, scopedMonthlyTotals, scopedCategoriesMonthlyTotals, scoppedProfit, ]; }