1.测试和修改了无人机在线实时信息的展示数据集的展示。使其能够全面展示。
2.添加了在无人机设备摄像头的为空时候,通过新增的接口获取无人机的摄像头的列表。 3.替换原先依照tcp推送消息绘制机器运动作业的轨迹过程,先用订阅mqtt特定话题推送的信息做动画过程的绘制。
This commit is contained in:
@@ -3,25 +3,26 @@ import 'package:equatable/equatable.dart';
|
||||
class TaskArriveEntity extends Equatable {
|
||||
final String type;
|
||||
final String deviceId;
|
||||
final int taskId;
|
||||
final int? taskId;
|
||||
final dynamic status;
|
||||
final ArriveLocation entity;
|
||||
final ArriveLocation? entity;
|
||||
|
||||
const TaskArriveEntity({
|
||||
required this.type,
|
||||
required this.deviceId,
|
||||
required this.taskId,
|
||||
this.taskId,
|
||||
this.status,
|
||||
required this.entity,
|
||||
this.entity,
|
||||
});
|
||||
|
||||
factory TaskArriveEntity.fromJson(Map<String, dynamic> json) {
|
||||
final entityJson = json['entity'] as Map<String, dynamic>?;
|
||||
return TaskArriveEntity(
|
||||
type: json['type'] as String? ?? '',
|
||||
deviceId: json['deviceId'] as String? ?? '',
|
||||
taskId: json['taskId'] as int? ?? 0,
|
||||
taskId: json['taskId'] as int?,
|
||||
status: json['status'],
|
||||
entity: ArriveLocation.fromJson(json['entity'] as Map<String, dynamic>? ?? {}),
|
||||
entity: entityJson != null ? ArriveLocation.fromJson(entityJson) : null,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -31,7 +32,7 @@ class TaskArriveEntity extends Equatable {
|
||||
'deviceId': deviceId,
|
||||
'taskId': taskId,
|
||||
'status': status,
|
||||
'entity': entity.toJson(),
|
||||
'entity': entity?.toJson(),
|
||||
};
|
||||
}
|
||||
|
||||
@@ -43,10 +44,7 @@ class ArriveLocation extends Equatable {
|
||||
final double lat;
|
||||
final double lng;
|
||||
|
||||
const ArriveLocation({
|
||||
required this.lat,
|
||||
required this.lng,
|
||||
});
|
||||
const ArriveLocation({required this.lat, required this.lng});
|
||||
|
||||
factory ArriveLocation.fromJson(Map<String, dynamic> json) {
|
||||
return ArriveLocation(
|
||||
@@ -56,10 +54,7 @@ class ArriveLocation extends Equatable {
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
return {
|
||||
'lat': lat,
|
||||
'lng': lng,
|
||||
};
|
||||
return {'lat': lat, 'lng': lng};
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user