Erweiterungen
This commit is contained in:
1 parent
ba1f7d5440
commit
bb3dc9e856
28 files changed
+1672
-1291
No files matched your search
@@ -50,7 +50,12 @@ showComissionNumberPopup(BuildContext context, TaskInfo taskInfo, Function(Strin
|
||||
controller: textEditingController,
|
||||
autofocus: true),
|
||||
const SizedBox(height: 20),
|
||||
getDefaultButton('Übernehmen', () => {Navigator.of(context).pop(), onFinished(textEditingController.text)})
|
||||
getDefaultButton('Übernehmen', () {
|
||||
final result = textEditingController.text;
|
||||
textEditingController.dispose();
|
||||
Navigator.of(context).pop();
|
||||
onFinished(result);
|
||||
})
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
@@ -24,6 +24,8 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
if (!didPop) {
|
||||
final shouldPop = await taskDialogSecurityException(context);
|
||||
if (shouldPop && context.mounted) {
|
||||
controller.dispose();
|
||||
remController.dispose();
|
||||
Navigator.of(context).pop();
|
||||
}
|
||||
}
|
||||
@@ -73,6 +75,9 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
if (remController.text.isNotEmpty) {
|
||||
Navigator.of(context).pop(),
|
||||
|
||||
controller.dispose(),
|
||||
remController.dispose(),
|
||||
|
||||
onFinished(selectedTourEntry, remController.text)
|
||||
} else {
|
||||
showAlertDialog("Fehler", "Bitte geben Sie eine Bemerkung ein")
|
||||
@@ -80,6 +85,9 @@ showPickupDeliveryStatusPopup(BuildContext context, TaskInfo taskInfo, Function(
|
||||
} else {
|
||||
Navigator.of(context).pop(),
|
||||
|
||||
controller.dispose(),
|
||||
remController.dispose(),
|
||||
|
||||
onFinished(selectedTourEntry, null)
|
||||
}
|
||||
})
|
||||
|
||||
@@ -77,7 +77,11 @@ showReceiptGiverPopup(BuildContext context, TaskInfo taskInfo, Function(String,
|
||||
if (textEditingController.text.isNotEmpty && selectedTourEntry != null) {
|
||||
Navigator.of(context).pop();
|
||||
|
||||
onFinished(textEditingController.text, selectedTourEntry!);
|
||||
final result = textEditingController.text;
|
||||
textEditingController.dispose();
|
||||
controller.dispose();
|
||||
|
||||
onFinished(result, selectedTourEntry!);
|
||||
} else {
|
||||
showAlertDialog("Fehler", "Sie müssen einen Text eingeben und ein Geschlecht auswählen");
|
||||
}
|
||||
|
||||
@@ -54,10 +54,12 @@ showStationNoticePopup(BuildContext context, TaskInfo taskInfo, Function(String)
|
||||
autofocus: true),
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
getDefaultButton('Übernehmen', buttonHeight: 50, () => {
|
||||
Navigator.of(context).pop(),
|
||||
|
||||
onFinished(textEditingController.text)})
|
||||
getDefaultButton('Übernehmen', buttonHeight: 50, () {
|
||||
final result = textEditingController.text;
|
||||
textEditingController.dispose();
|
||||
Navigator.of(context).pop();
|
||||
onFinished(result);
|
||||
})
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
@@ -67,15 +67,16 @@ showZipPopup(BuildContext context, String text, String buttonText,
|
||||
const SizedBox(height: 20),
|
||||
getDefaultButton(
|
||||
buttonText,
|
||||
() => {
|
||||
if (_checkInput(context,
|
||||
textEditingController.text))
|
||||
{
|
||||
Navigator.of(context).pop(),
|
||||
onFinished(
|
||||
textEditingController.text)
|
||||
},
|
||||
}),
|
||||
() {
|
||||
if (_checkInput(context,
|
||||
textEditingController.text)) {
|
||||
final result = textEditingController.text;
|
||||
textEditingController.dispose();
|
||||
focusNode.dispose();
|
||||
Navigator.of(context).pop();
|
||||
onFinished(result);
|
||||
}
|
||||
}),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Reference in new issue
Block a user