app-starlock/star_lock/lib/tools/eventBusEventManage.dart

76 lines
2.1 KiB
Dart
Raw Normal View History

2023-09-07 18:36:16 +08:00
import 'package:event_bus/event_bus.dart';
2023-11-01 17:28:59 +08:00
import '../main/lockDetail/lcokSet/lockSet/lockSetInfo_entity.dart';
2023-09-07 18:36:16 +08:00
/// 创建EventBus
EventBus eventBus = EventBus();
/// 刷新锁列表数据
class RefreshLockListInfoDataEvent {
2023-09-07 18:36:16 +08:00
RefreshLockListInfoDataEvent();
}
/// 刷新考勤员工列表
class RefreshCheckInStaffListDataEvent {
RefreshCheckInStaffListDataEvent();
}
2023-09-07 18:36:16 +08:00
/// 传递当前锁信息
class PassCurrentLockInformationEvent {
2023-11-01 17:28:59 +08:00
LockSetInfoData lockSetInfoData;
PassCurrentLockInformationEvent(this.lockSetInfoData);
2023-09-07 18:36:16 +08:00
}
2023-09-19 15:20:58 +08:00
/// 卡、密码、指纹修改之后刷新列表
class OtherTypeRefreshListEvent {
2023-09-19 15:20:58 +08:00
OtherTypeRefreshListEvent();
}
/// 考情添加员工卡、指纹之后回调卡、指纹number
class ChickInAddStaffCardAndFingerprintBlockNumberEvent {
String number;
ChickInAddStaffCardAndFingerprintBlockNumberEvent(this.number);
}
/// Uuid删除当前锁时 有可能锁被初始化了 但后台没被初始化 当打开APP的时候扫描如果未被连接就传uuid过去 判断直接删除数据
class ScanAllDeviceFindCurrentDeviceConnectedEvent {
String uuid;
ScanAllDeviceFindCurrentDeviceConnectedEvent(this.uuid);
2023-10-25 16:18:27 +08:00
}
/// 多语言 切换之后传值到上一级界面
class ChangeLanguageBlockLastLanguageEvent {
2023-10-25 16:18:27 +08:00
String languageTitle;
ChangeLanguageBlockLastLanguageEvent(this.languageTitle);
}
/// 锁分组添加或者删除锁之后刷新首页数据
class LockGroupEditGroupLockRefreshEvent {
LockGroupEditGroupLockRefreshEvent();
}
/// 锁设置里面开启关闭刷新锁详情
class LockSetChangeSetRefreshLockDetailWithType {
int type; // 0 考勤 1开锁时是否需联网
int setResult;
LockSetChangeSetRefreshLockDetailWithType(this.type, this.setResult);
2023-12-18 16:03:05 +08:00
}
/// 获取到视频流数据然后刷新界面
class GetTVDataRefreshUI {
2023-12-18 16:03:05 +08:00
List<int> tvList;
GetTVDataRefreshUI(this.tvList);
2023-12-21 10:21:25 +08:00
}
/// 获取到UDP接收状态然后刷新界面
class GetUDPStatusRefreshUI {
2023-12-21 10:21:25 +08:00
int udpStatus;
GetUDPStatusRefreshUI(this.udpStatus);
}
/// 获取到第一帧图片数据后跳转
class GetFirstFrameGoPush {
bool isFirstFrame;
GetFirstFrameGoPush(this.isFirstFrame);
}