feat: 实现日历提醒 in-app fallback 机制及通知服务重构
This commit is contained in:
@@ -59,6 +59,14 @@ class TodoApi {
|
||||
return TodoResponse.fromJson(response.data);
|
||||
}
|
||||
|
||||
Future<void> updateTodoPriority(String id, int priority) async {
|
||||
try {
|
||||
await _client.patch('$_prefix/$id', data: {'priority': priority});
|
||||
} catch (_) {
|
||||
// Ignore response parsing errors, just need to know if request succeeded
|
||||
}
|
||||
}
|
||||
|
||||
Future<TodoResponse> completeTodo(String id) async {
|
||||
final response = await _client.post('$_prefix/$id/complete', data: {});
|
||||
return TodoResponse.fromJson(response.data);
|
||||
|
||||
Reference in New Issue
Block a user