Frontend first draft

This commit is contained in:
Arseni
2025-11-13 15:06:15 +03:00
parent e47f343afb
commit ddb54ddfdc
504 changed files with 25498 additions and 1 deletions

View File

@@ -0,0 +1,42 @@
import 'package:pshared/models/payment/methods/type.dart';
import 'package:pshared/models/payment/type.dart';
abstract class PaymentMethodsService {
Future<List<PaymentMethod>> fetchMethods();
}
class MockPaymentMethodsService implements PaymentMethodsService {
@override
Future<List<PaymentMethod>> fetchMethods() async {
await Future.delayed(const Duration(milliseconds: 200));
return [
PaymentMethod(
id: '1',
label: 'My account',
details: '•••4567',
type: PaymentType.bankAccount,
isMain: true,
),
PaymentMethod(
id: '2',
label: 'Euro IBAN',
details: 'DE•• •••8901',
type: PaymentType.iban,
),
PaymentMethod(
id: '3',
label: 'Wallet',
details: 'WA12345667',
type: PaymentType.wallet,
),
PaymentMethod(
id: '4',
label: 'Credit Card',
details: '21•• •••• •••• 8901',
type: PaymentType.card,
),
];
}
}

View File

@@ -0,0 +1,20 @@
import 'package:pshared/models/payment/upload_history_item.dart';
abstract class UploadHistoryService {
Future<List<UploadHistoryItem>> fetchHistory();
}
class MockUploadHistoryService implements UploadHistoryService {
@override
Future<List<UploadHistoryItem>> fetchHistory() async {
await Future.delayed(const Duration(milliseconds: 300));
return [
UploadHistoryItem(name: "cards_payout_single.csv", status: "Valid", time: "5 hours ago"),
UploadHistoryItem(name: "rfba_norm.csv", status: "Valid", time: "Yesterday"),
UploadHistoryItem(name: "iban (4).csv", status: "Valid", time: "Yesterday"),
UploadHistoryItem(name: "rfba_wrong.csv", status: "Error", time: "2 days ago"),
];
}
}