From a5c572770bfc8dd667d9f797a1068f2b6aa9ceef Mon Sep 17 00:00:00 2001 From: Sven Carstensen Date: Tue, 19 Mar 2024 16:08:32 +0100 Subject: [PATCH] Logging --- lib/content_views/accepted_jobs_page.dart | 6 ++++++ lib/tools/mqtt_core.dart | 2 +- pubspec.yaml | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/content_views/accepted_jobs_page.dart b/lib/content_views/accepted_jobs_page.dart index fc77322..22328f6 100644 --- a/lib/content_views/accepted_jobs_page.dart +++ b/lib/content_views/accepted_jobs_page.dart @@ -45,6 +45,12 @@ class _AcceptedJobsPageState extends State { void initState() { Future.delayed(const Duration(seconds: 0), () async { _jobs = await MyApp.isarInstance.jobs.filter().stateEqualTo(Constants.stateAccepted).findAll(); + _jobs.sort((job1, job2) { + var date1 = DateTime.parse(job1.ordertime).millisecondsSinceEpoch; + var date2 = DateTime.parse(job2.ordertime).millisecondsSinceEpoch; + + return date2 - date1; + }); _initCompleted = true; diff --git a/lib/tools/mqtt_core.dart b/lib/tools/mqtt_core.dart index cacd027..05ba0b0 100644 --- a/lib/tools/mqtt_core.dart +++ b/lib/tools/mqtt_core.dart @@ -152,7 +152,7 @@ class MqttCore { _mqttClient.publishMessage(topic, MqttQos.exactlyOnce, buffer); - //Util.logInfo("message\n$text\nsend to $topic"); + Util.logInfo("message\n$text\nsend to $topic"); } publishPayloadMessage(String topic, Map payload) { diff --git a/pubspec.yaml b/pubspec.yaml index 06c6dc1..9e9a6e4 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html # In Windows, build-name is used as the major, minor, and patch parts # of the product and file versions while build-number is used as the build suffix. -version: 218.0.0+9 +version: 219.0.0+10 environment: sdk: '>=2.19.6 <3.0.0'