Remove Filters changes modals

This commit is contained in:
fhkhd
2024-01-11 18:25:13 +03:30
parent 85eb90a850
commit 4cb3a921f1
7 changed files with 124 additions and 115 deletions
+22 -19
View File
@@ -359,25 +359,28 @@ class _TestFilterScreenState extends State<TestFilterScreen> {
fDateCTRL.text, fDateCTRL.text,
uDateCTRL.text, uDateCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
// Navigator.of(context).pop(); // // Navigator.of(context).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then( // ).then(
(_) => // (_) =>
Navigator.of(context).popAndPushNamed( // Navigator.of(context).popAndPushNamed(
Routes.testResultScreen, // Routes.testResultScreen,
), // ),
// );
Navigator.of(context).popAndPushNamed(
Routes.testResultScreen,
); );
}, },
child: Container( child: Container(
@@ -45,22 +45,23 @@ class CycleFilterSaveButton extends StatelessWidget {
hospitalID, hospitalID,
dateCTRL.text, dateCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(Routes.cycleResultScreen); // Navigator.of(context).popAndPushNamed(Routes.cycleResultScreen);
}); // });
Navigator.of(context).popAndPushNamed(Routes.cycleResultScreen);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
@@ -51,22 +51,23 @@ class ItemFilterSaveButton extends StatelessWidget {
sizeCTRL.text, sizeCTRL.text,
specificCTRL.text, specificCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(push); // Navigator.of(context).popAndPushNamed(push);
}); // });
Navigator.of(context).popAndPushNamed(push);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
@@ -42,22 +42,23 @@ class LabelFilterSaveButton extends StatelessWidget {
striizerIdCTRL.text, striizerIdCTRL.text,
hospitalID, hospitalID,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(Routes.labelResultScreen); // Navigator.of(context).popAndPushNamed(Routes.labelResultScreen);
}); // });
Navigator.of(context).popAndPushNamed(Routes.labelResultScreen);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
@@ -38,22 +38,23 @@ class MyItemFilterSaveButton extends StatelessWidget {
sizeCTRL.text, sizeCTRL.text,
specificCTRL.text, specificCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(push); // Navigator.of(context).popAndPushNamed(push);
}); // });
Navigator.of(context).popAndPushNamed(push);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
@@ -32,22 +32,23 @@ class MyPackagesFilterSaveButton extends StatelessWidget {
nameCTRL.text, nameCTRL.text,
// udiCTRL.text, // udiCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(push); // Navigator.of(context).popAndPushNamed(push);
}); // });
Navigator.of(context).popAndPushNamed(push);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
@@ -42,22 +42,23 @@ class PackageFilterSaveButton extends StatelessWidget {
hospitalID, hospitalID,
// udiCTRL.text, // udiCTRL.text,
); );
showDialog( // showDialog(
context: context, // context: context,
builder: (ctx) => AlertDialog( // builder: (ctx) => AlertDialog(
content: Text('Filters changed.'), // content: Text('Filters changed.'),
actions: <Widget>[ // actions: <Widget>[
TextButton( // TextButton(
onPressed: () { // onPressed: () {
Navigator.of(ctx).pop(); // Navigator.of(ctx).pop();
}, // },
child: Text('Ok'), // child: Text('Ok'),
) // )
], // ],
), // ),
).then((_) { // ).then((_) {
Navigator.of(context).popAndPushNamed(Routes.packageResultScreen); // Navigator.of(context).popAndPushNamed(Routes.packageResultScreen);
}); // });
Navigator.of(context).popAndPushNamed(Routes.packageResultScreen);
}, },
child: Container( child: Container(
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(