Fehlerkorrekturen
This commit is contained in:
1 parent
92df2a9156
commit
6089b5cbd9
9 files changed
+28
-22
No files matched your search
@@ -191,6 +191,8 @@ class _AssignedJobsPageState extends State<AssignedJobsPage> {
|
||||
}
|
||||
|
||||
_sendAnswer(Job job, int item) async {
|
||||
var currentPosition = MyApp.currentPosition;
|
||||
|
||||
var message = AcceptJobMessage();
|
||||
message.reaction = Reaction();
|
||||
message.reaction.id = job.id.toString();
|
||||
@@ -198,10 +200,12 @@ class _AssignedJobsPageState extends State<AssignedJobsPage> {
|
||||
message.reaction.item = item;
|
||||
message.reaction.track = Track();
|
||||
message.reaction.track.time = DateTime.now().toUtc().toIso8601String();
|
||||
message.reaction.track.pos = FinTaskPos();
|
||||
message.reaction.track.pos.lat = 0;
|
||||
message.reaction.track.pos.long = 0;
|
||||
message.reaction.track.pos.acc = 1;
|
||||
if (currentPosition != null) {
|
||||
message.reaction.track.pos = FinTaskPos();
|
||||
message.reaction.track.pos!.lat = 0;
|
||||
message.reaction.track.pos!.long = 0;
|
||||
message.reaction.track.pos!.acc = 1;
|
||||
}
|
||||
|
||||
MqttCore.instance.publishPayloadMessage("job", message.toJson());
|
||||
|
||||
|
||||
Reference in new issue
Block a user