change pushnamed to popAndPsuhnamed

This commit is contained in:
2024-08-23 12:50:35 +02:00
parent 0469fdd37c
commit 22549c2e02

View File

@@ -46,7 +46,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
"Setup Profie", "Setup Profie",
() { () {
Navigator.of(context) Navigator.of(context)
.pushNamed('/profile', arguments: widget.signedInUser); .popAndPushNamed('/profile', arguments: widget.signedInUser);
// Navigator.popAndPushNamed(context, '/patient-manager', // Navigator.popAndPushNamed(context, '/patient-manager',
// arguments: widget.userEmail); // arguments: widget.userEmail);
} }
@@ -61,7 +61,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.add_business_outlined, Icons.add_business_outlined,
"Setup Business", "Setup Business",
() { () {
Navigator.of(context).pushNamed( Navigator.of(context).popAndPushNamed(
'/business/add', '/business/add',
arguments: widget.signedInUser, arguments: widget.signedInUser,
); );
@@ -77,7 +77,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
"Patient Profile", "Patient Profile",
() { () {
//comeback here //comeback here
Navigator.of(context).pushNamed('/patient-profile', Navigator.of(context).popAndPushNamed('/patient-profile',
arguments: PatientViewArguments( arguments: PatientViewArguments(
widget.signedInUser, null, null, null, "personal")); widget.signedInUser, null, null, null, "personal"));
// Navigator.popAndPushNamed(context, '/patient-manager', // Navigator.popAndPushNamed(context, '/patient-manager',
@@ -90,7 +90,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.check_box_outlined, Icons.check_box_outlined,
"Access Review", "Access Review",
() { () {
Navigator.of(context).pushNamed( Navigator.of(context).popAndPushNamed(
'/patient-access-review', '/patient-access-review',
arguments: widget.signedInUser, arguments: widget.signedInUser,
); );
@@ -108,7 +108,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.business, Icons.business,
"Business Profile", "Business Profile",
() { () {
Navigator.of(context).pushNamed( Navigator.of(context).popAndPushNamed(
'/business-profile', '/business-profile',
arguments: BusinessArguments( arguments: BusinessArguments(
widget.signedInUser, widget.signedInUser,
@@ -128,7 +128,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.medication, Icons.medication,
"Manage Patient", "Manage Patient",
() { () {
Navigator.of(context).pushNamed( Navigator.of(context).popAndPushNamed(
'/patient-manager', '/patient-manager',
arguments: BusinessArguments( arguments: BusinessArguments(
widget.signedInUser, widget.signedInUser,
@@ -165,7 +165,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.add_business_outlined, Icons.add_business_outlined,
"Setup Bus - Dev", "Setup Bus - Dev",
() { () {
Navigator.of(context).pushNamed( Navigator.of(context).popAndPushNamed(
'/business/add', '/business/add',
arguments: widget.signedInUser, arguments: widget.signedInUser,
); );
@@ -176,7 +176,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
Icons.add_circle_outline, Icons.add_circle_outline,
"Add Pat - Dev", "Add Pat - Dev",
() { () {
Navigator.of(context).pushNamed('/patient-manager/add', Navigator.of(context).popAndPushNamed('/patient-manager/add',
arguments: widget.signedInUser); arguments: widget.signedInUser);
} }
]); ]);
@@ -186,7 +186,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
"Upd Prof - Dev", "Upd Prof - Dev",
() { () {
Navigator.of(context) Navigator.of(context)
.pushNamed('/profile', arguments: widget.signedInUser); .popAndPushNamed('/profile', arguments: widget.signedInUser);
// Navigator.popAndPushNamed(context, '/patient-manager', // Navigator.popAndPushNamed(context, '/patient-manager',
// arguments: widget.userEmail); // arguments: widget.userEmail);
} }
@@ -340,7 +340,7 @@ class _HomeTileGridState extends State<HomeTileGrid> {
builder: (ctx, snapshot) { builder: (ctx, snapshot) {
if (snapshot.connectionState == ConnectionState.done) { if (snapshot.connectionState == ConnectionState.done) {
var apps = snapshot.requireData; var apps = snapshot.requireData;
return Container( return SizedBox(
width: width, width: width,
height: height, height: height,
child: GridView.builder( child: GridView.builder(