17 lines
583 B
Dart
17 lines
583 B
Dart
/// 记录列表的数据范围。
|
|
///
|
|
/// [device] 仅查询本机数据;[merchant] 按当前终端权限(所属商户)查询全部设备数据,
|
|
/// 需要网络可用,服务端负责解析设备归属,客户端不指定商户范围。
|
|
enum TerminalDataScope {
|
|
device('本机数据'),
|
|
merchant('全部数据');
|
|
|
|
final String title;
|
|
|
|
const TerminalDataScope(this.title);
|
|
|
|
/// 服务端接口的 scope 协议值;本机范围沿用接口默认值,不额外传参。
|
|
String? get requestCode =>
|
|
this == TerminalDataScope.merchant ? 'MERCHANT' : null;
|
|
}
|