fix route call post eign in or reg
This commit is contained in:
@@ -38,6 +38,7 @@ class _MihloadingcircleState extends State<Mihloadingcircle> {
|
|||||||
void initState() {
|
void initState() {
|
||||||
//_controller.animateTo(26);
|
//_controller.animateTo(26);
|
||||||
super.initState();
|
super.initState();
|
||||||
|
checkScreenSize();
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@@ -48,7 +49,6 @@ class _MihloadingcircleState extends State<Mihloadingcircle> {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
checkScreenSize();
|
|
||||||
return Dialog(
|
return Dialog(
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.all(popUpPaddingSize),
|
padding: EdgeInsets.all(popUpPaddingSize),
|
||||||
|
|||||||
@@ -15,13 +15,13 @@ abstract class AppEnviroment {
|
|||||||
case Enviroment.dev:
|
case Enviroment.dev:
|
||||||
{
|
{
|
||||||
//================= Android Dev Urls =================
|
//================= Android Dev Urls =================
|
||||||
// baseApiUrl = "http://10.0.2.2:8080";
|
baseApiUrl = "http://10.0.2.2:8080";
|
||||||
// baseFileUrl = "http://10.0.2.2:9000";
|
baseFileUrl = "http://10.0.2.2:9000";
|
||||||
// baseAiUrl = "http://10.0.2.2:11434";
|
baseAiUrl = "http://10.0.2.2:11434";
|
||||||
//================= Web Dev Urls =================
|
//================= Web Dev Urls =================
|
||||||
baseApiUrl = "http://localhost:8080";
|
// baseApiUrl = "http://localhost:8080";
|
||||||
baseFileUrl = "http://localhost:9000";
|
// baseFileUrl = "http://localhost:9000";
|
||||||
baseAiUrl = "http://localhost:11434";
|
// baseAiUrl = "http://localhost:11434";
|
||||||
whatsappAccessToken =
|
whatsappAccessToken =
|
||||||
"EAAPINXuNFdYBOzBjTcvZA2iPXEHbHRF9uNXyP3ihkPRUcBqKNru5g9NKRRKkFaiaITEzO3BMo6CjdUmlDH4qYTW2mzDrZB4Q21ZCEZBgECZCu27vfaOXJZCYQLNxwoXkrZBRYv8ZAP37f69r3z9JxLQxdxn9gwqA3oNZAlBBRapJQzxOr6pZBTdI3bbjbu17ZBIwRcF4JCqPDCNLEZCI3bmHwEd2i2niNMYZD";
|
"EAAPINXuNFdYBOzBjTcvZA2iPXEHbHRF9uNXyP3ihkPRUcBqKNru5g9NKRRKkFaiaITEzO3BMo6CjdUmlDH4qYTW2mzDrZB4Q21ZCEZBgECZCu27vfaOXJZCYQLNxwoXkrZBRYv8ZAP37f69r3z9JxLQxdxn9gwqA3oNZAlBBRapJQzxOr6pZBTdI3bbjbu17ZBIwRcF4JCqPDCNLEZCI3bmHwEd2i2niNMYZD";
|
||||||
//fingerPrintPluginKey = 'h5X7a5j14iUZCobI1ZeX';
|
//fingerPrintPluginKey = 'h5X7a5j14iUZCobI1ZeX';
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
|
|
||||||
|
import 'package:Mzansi_Innovation_Hub/mih_objects/arguments.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter/services.dart';
|
import 'package:flutter/services.dart';
|
||||||
import '../../main.dart';
|
import '../../main.dart';
|
||||||
@@ -53,8 +54,15 @@ class _RegisterState extends State<Register> {
|
|||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
if (response.statusCode == 201) {
|
if (response.statusCode == 201) {
|
||||||
Navigator.of(context).pushNamedAndRemoveUntil('/', (route) => false);
|
Navigator.of(context).pushNamedAndRemoveUntil(
|
||||||
signUpSuccess();
|
'/',
|
||||||
|
(route) => false,
|
||||||
|
arguments: AuthArguments(
|
||||||
|
true,
|
||||||
|
true,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
// signUpSuccess();
|
||||||
// setState(() {
|
// setState(() {
|
||||||
// successfulSignUp = true;
|
// successfulSignUp = true;
|
||||||
// });
|
// });
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
|
|
||||||
|
import 'package:Mzansi_Innovation_Hub/mih_objects/arguments.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter/services.dart';
|
import 'package:flutter/services.dart';
|
||||||
import '../../main.dart';
|
import '../../main.dart';
|
||||||
@@ -186,7 +187,14 @@ class _SignInState extends State<SignIn> {
|
|||||||
await signUserIn();
|
await signUserIn();
|
||||||
if (successfulSignIn) {
|
if (successfulSignIn) {
|
||||||
// TextInput.finishAutofillContext();
|
// TextInput.finishAutofillContext();
|
||||||
Navigator.of(context).pushNamedAndRemoveUntil('/', (route) => false);
|
Navigator.of(context).pushNamedAndRemoveUntil(
|
||||||
|
'/',
|
||||||
|
(route) => false,
|
||||||
|
arguments: AuthArguments(
|
||||||
|
true,
|
||||||
|
true,
|
||||||
|
),
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user