forked from Nexus/nexus
parent
3a33bf7bfe
commit
8fda43ccf8
6 changed files with 159 additions and 87 deletions
14
lib/controllers/notification_request.dart
Normal file
14
lib/controllers/notification_request.dart
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import "package:flutter_riverpod/flutter_riverpod.dart";
|
||||
|
||||
class NotificationRequestController extends Notifier<int?> {
|
||||
@override
|
||||
int? build() => null;
|
||||
|
||||
void request(int rowId) => state = rowId;
|
||||
|
||||
void consume() => state = null;
|
||||
|
||||
static final provider = NotifierProvider<NotificationRequestController, int?>(
|
||||
NotificationRequestController.new,
|
||||
);
|
||||
}
|
||||
Loading…
Reference in a new issue