Fehlerkorrekturen und Erweiterungen
This commit is contained in:
1 parent
6c4294512e
commit
b3d010b453
29 files changed
+430
-212
No files matched your search
@@ -192,13 +192,10 @@ class _ApproachAreaPageState extends State<ApproachAreaPage> with ProducerMixin,
|
||||
setPosMessage.track!.pos!.acc = position.accuracy.toInt();
|
||||
}
|
||||
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPublishPayload,
|
||||
payload: PublishPayloadMessage(topic: "set_zip", message: setPosMessage.toJson(), acknowledgeRequired: false),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PublishPayloadMessage>(Constants.messageTopicPublishPayload, arguments: PublishPayloadMessage(topic: "set_zip", message: setPosMessage.toJson(), qos: MqttQos.exactlyOnce));
|
||||
}
|
||||
|
||||
_initMessages() {
|
||||
@@ -210,11 +207,6 @@ class _ApproachAreaPageState extends State<ApproachAreaPage> with ProducerMixin,
|
||||
setState(() {});
|
||||
},
|
||||
);
|
||||
/*MessageService().subscribe<RankingUpdated>(Constants.messageTopicRankingUpdated, this, (rankingUpdateMessage) async {
|
||||
_ranking = await MyApp.isarInstance.rankings.where().findFirst();
|
||||
|
||||
setState(() {});
|
||||
});*/
|
||||
}
|
||||
}
|
||||
|
||||
@@ -253,13 +245,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
radius: 10,
|
||||
@@ -282,13 +271,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
backgroundColor: Constants.colorPrimary,
|
||||
|
||||
@@ -66,6 +66,11 @@ class _FinishedJobsPageState extends State<FinishedJobsPage> with ProducerMixin
|
||||
List<Widget> jobWidgets = [];
|
||||
|
||||
for (var job in _jobs) {
|
||||
var bottomText = "${job.id}\n${job.tours[0].comp}\n${job.tours[0].street}\n${job.tours[0].city}";
|
||||
if (job.rem.trim().isNotEmpty) {
|
||||
bottomText += "\n\n${job.rem.trim()}";
|
||||
}
|
||||
|
||||
jobWidgets.add(
|
||||
ListTile(
|
||||
onTap: () {
|
||||
@@ -100,19 +105,7 @@ class _FinishedJobsPageState extends State<FinishedJobsPage> with ProducerMixin
|
||||
],
|
||||
),
|
||||
Text(
|
||||
job.id.toString(),
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
Text(
|
||||
job.tours[0].comp,
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
Text(
|
||||
job.tours[0].street,
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
Text(
|
||||
job.tours[0].city,
|
||||
bottomText,
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
],
|
||||
|
||||
@@ -222,7 +222,7 @@ class _MainPageState extends State<MainPage> with ConsumerMixin, ProducerMixin {
|
||||
),
|
||||
SizedBox(height: _loggedOut == true ? 0 : 20),
|
||||
Visibility(
|
||||
visible: !_loggedOut,
|
||||
visible: !_loggedOut && Util.preferencesGetBool(Constants.prefsBWVEnabled, false),
|
||||
child: getDefaultButton(
|
||||
'Wunschziel für heute',
|
||||
image: Image.asset('assets/wunsch_plz.png', width: 30, height: 30),
|
||||
|
||||
@@ -420,13 +420,10 @@ class _TaskListPageState extends State<TaskListPage> with ProducerMixin {
|
||||
|
||||
_finishTaskProcessing(taskInfo);
|
||||
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 2),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 2));
|
||||
}
|
||||
});
|
||||
});
|
||||
@@ -524,14 +521,11 @@ class _TaskListPageState extends State<TaskListPage> with ProducerMixin {
|
||||
}
|
||||
}
|
||||
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPublishPayload,
|
||||
payload: PublishPayloadMessage(topic: "fin_tour", message: finTourMessage.toJson(), acknowledgeRequired: true),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PublishPayloadMessage>(Constants.messageTopicPublishPayload, arguments: PublishPayloadMessage(topic: "fin_tour", message: finTourMessage.toJson(), qos: MqttQos.exactlyOnce));
|
||||
|
||||
widget.tour.state = Constants.stateFinishedNotConfirmed;
|
||||
|
||||
await MyApp.isarInstance.writeTxn(() async {
|
||||
@@ -555,14 +549,11 @@ class _TaskListPageState extends State<TaskListPage> with ProducerMixin {
|
||||
message.time = DateTime.now().millisecondsSinceEpoch;
|
||||
message.data = picture.data;
|
||||
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPublishPayload,
|
||||
payload: PublishPayloadMessage(topic: "pic", message: message.toJson(), acknowledgeRequired: true),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PublishPayloadMessage>(Constants.messageTopicPublishPayload, arguments: PublishPayloadMessage(topic: "pic", message: message.toJson(), qos: MqttQos.exactlyOnce));
|
||||
|
||||
await MyApp.isarInstance.writeTxn(() async {
|
||||
await MyApp.isarInstance.pictures.delete(picture.id);
|
||||
});
|
||||
@@ -626,13 +617,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
radius: 10,
|
||||
@@ -655,13 +643,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
backgroundColor: Constants.colorPrimary,
|
||||
|
||||
@@ -91,14 +91,14 @@ class _TourListPageState extends State<TourListPage> with ProducerMixin {
|
||||
visible: widget.job.tours[0].pos != null,
|
||||
child: ElevatedButton(
|
||||
style: ButtonStyle(
|
||||
shape: MaterialStateProperty.all<RoundedRectangleBorder>(
|
||||
shape: WidgetStateProperty.all<RoundedRectangleBorder>(
|
||||
RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(8.0),
|
||||
side: const BorderSide(color: Colors.grey),
|
||||
),
|
||||
),
|
||||
backgroundColor: MaterialStateProperty.all<Color>(Colors.lightGreen),
|
||||
foregroundColor: MaterialStateProperty.all<Color>(Colors.black),
|
||||
backgroundColor: WidgetStateProperty.all<Color>(Colors.lightGreen),
|
||||
foregroundColor: WidgetStateProperty.all<Color>(Colors.black),
|
||||
),
|
||||
onPressed: () => {showMapPopup(context, widget.job.tours[0], widget.job.tours)},
|
||||
child: const Text("Karte")),
|
||||
@@ -198,13 +198,10 @@ class _TourListPageState extends State<TourListPage> with ProducerMixin {
|
||||
}
|
||||
|
||||
Future<void> _clicked(JobTour tour, bool readOnly) async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPushContentView,
|
||||
payload: TourDetailsPage(job: widget.job, tour: tour, readOnly: readOnly),
|
||||
);
|
||||
|
||||
//await MessageService().publish<ContentViewWidget>(Constants.messageTopicPushContentView, arguments: TourDetailsPage(job: widget.job, tour: tour, readOnly: readOnly));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -243,13 +240,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
radius: 10,
|
||||
@@ -272,13 +266,10 @@ class _HeaderWidgetState extends State<_HeaderWidget> with ProducerMixin {
|
||||
child: FittedBox(
|
||||
child: GestureDetector(
|
||||
onTap: () async {
|
||||
// TODO MESSAGING
|
||||
sendMessage(
|
||||
routingKey: Constants.messageTopicPopContentView,
|
||||
payload: PopContentViewMessage(count: 1),
|
||||
);
|
||||
|
||||
//await MessageService().publish<PopContentViewMessage>(Constants.messageTopicPopContentView, arguments: PopContentViewMessage(count: 1));
|
||||
},
|
||||
child: const CircleAvatar(
|
||||
backgroundColor: Constants.colorPrimary,
|
||||
|
||||
Reference in new issue
Block a user