mirror of
https://github.com/koloideal/Casha.git
synced 2026-08-08 17:51:14 +03:00
step
This commit is contained in:
@@ -4,7 +4,7 @@ import '../dashboard/provider.dart';
|
||||
|
||||
final categoryExpenseProvider = Provider<Map<String, double>>((ref) {
|
||||
final txsAsync = ref.watch(transactionsProvider);
|
||||
final txs = txsAsync.valueOrNull ?? [];
|
||||
final txs = txsAsync.value ?? [];
|
||||
final filtered = txs.where((t) => t.type == TransactionType.expense);
|
||||
|
||||
final map = <String, double>{};
|
||||
@@ -16,7 +16,7 @@ final categoryExpenseProvider = Provider<Map<String, double>>((ref) {
|
||||
|
||||
final categoryIncomeProvider = Provider<Map<String, double>>((ref) {
|
||||
final txsAsync = ref.watch(transactionsProvider);
|
||||
final txs = txsAsync.valueOrNull ?? [];
|
||||
final txs = txsAsync.value ?? [];
|
||||
final filtered = txs.where((t) => t.type == TransactionType.income);
|
||||
|
||||
final map = <String, double>{};
|
||||
@@ -28,7 +28,7 @@ final categoryIncomeProvider = Provider<Map<String, double>>((ref) {
|
||||
|
||||
final monthlyBreakdownProvider = Provider<List<MonthlyData>>((ref) {
|
||||
final txsAsync = ref.watch(transactionsProvider);
|
||||
final txs = txsAsync.valueOrNull ?? [];
|
||||
final txs = txsAsync.value ?? [];
|
||||
final filtered = txs.where((t) => t.type == TransactionType.expense);
|
||||
|
||||
final now = DateTime.now();
|
||||
|
||||
Reference in New Issue
Block a user