getPendingTasks method
Gets a list of pending tasks with registration dates
Returns a list of PendingTask with task IDs and their registration dates
Implementation
@override
Future<List<Map<String, dynamic>>> getPendingTasks() async {
try {
final result =
await methodChannel.invokeMethod<List<Object?>>('getPendingTasks');
if (result == null) {
return [];
}
return result
.map((item) =>
Map<String, dynamic>.from(item as Map<Object?, Object?>))
.toList();
} on PlatformException catch (e) {
throw PlatformException(
code: e.code,
message: e.message,
details: e.details,
);
}
}