Erweiterungen
This commit is contained in:
1 parent
955d7b3cb4
commit
e9811da904
25 files changed
+1505
-128
No files matched your search
@@ -1,6 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:stadtbote/model/task_info.dart';
|
||||
import 'package:stadtbote/model/tour_task.dart';
|
||||
import 'package:stadtbote/tools/app_localizations.dart';
|
||||
import 'package:stadtbote/tools/util.dart';
|
||||
|
||||
showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(TourEntry?, String? remark) onFinished) async {
|
||||
@@ -58,7 +59,7 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
DropdownMenu<TourEntry>(
|
||||
expandedInsets: const EdgeInsets.all(0),
|
||||
controller: controller,
|
||||
hintText: 'Status',
|
||||
hintText: 'status'.tr,
|
||||
onSelected: (TourEntry? value) {
|
||||
selectedTourEntry = value;
|
||||
|
||||
@@ -68,9 +69,9 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
dropdownMenuEntries: entries,
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
Visibility(visible: selectedTourEntry != null ? selectedTourEntry!.queryRemark : false, child: Util.getDefaultTextField(controller: remController, "Bemerkung")),
|
||||
Visibility(visible: selectedTourEntry != null ? selectedTourEntry!.queryRemark : false, child: Util.getDefaultTextField(controller: remController, 'remark'.tr)),
|
||||
const SizedBox(height: 20),
|
||||
getDefaultButton('Übernehmen', buttonHeight: 50, () => {
|
||||
getDefaultButton('apply'.tr, buttonHeight: 50, () => {
|
||||
if (selectedTourEntry!.queryRemark) {
|
||||
if (remController.text.isNotEmpty) {
|
||||
Navigator.of(context).pop(),
|
||||
@@ -80,7 +81,7 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
|
||||
onFinished(selectedTourEntry, remController.text)
|
||||
} else {
|
||||
showAlertDialog("Fehler", "Bitte geben Sie eine Bemerkung ein")
|
||||
showAlertDialog('error'.tr, 'enter_remark'.tr)
|
||||
}
|
||||
} else {
|
||||
Navigator.of(context).pop(),
|
||||
|
||||
Reference in new issue
Block a user