Added qr bloc
This commit is contained in:
parent
bb4cbcabe7
commit
89fdcce613
6 changed files with 56 additions and 0 deletions
14
lib/blocs/qr/qr_bloc.dart
Normal file
14
lib/blocs/qr/qr_bloc.dart
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||
import 'package:ocbo_esign_mobile/blocs/qr/qr_event.dart';
|
||||
import 'package:ocbo_esign_mobile/blocs/qr/qr_state.dart';
|
||||
|
||||
class QrBloc extends Bloc<QrEvent, QrState> {
|
||||
QrBloc() : super(QrState('')) {
|
||||
on<QrSetValue>((event, emit) {
|
||||
emit(QrState(event.value));
|
||||
});
|
||||
on<QrGetValue>((event, emit) {
|
||||
emit(state);
|
||||
});
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue