Merge branch 'sultan' into 'diplomatic-quarter-live'

Sultan

See merge request Cloud_Solution/diplomatic-quarter!127
merge-update-with-lab-changes
Mohammad Aljammal 5 years ago
commit 2731c5b1d4

@ -7,8 +7,8 @@ import 'package:diplomaticquarterapp/widgets/mobile-no/mobile_no.dart';
const MAX_SMALL_SCREEN = 660;
const BASE_URL = 'https://uat.hmgwebservices.com/';
//const BASE_URL = 'https://hmgwebservices.com/';
//const BASE_URL = 'https://uat.hmgwebservices.com/';
const BASE_URL = 'https://hmgwebservices.com/';
const GET_PROJECT = 'Services/Lists.svc/REST/GetProject';
///Doctor

@ -147,7 +147,7 @@ class _LandingPageState extends State<LandingPage> with WidgetsBindingObserver {
_firebaseMessaging.getToken().then((String token) {
sharedPref.setString(PUSH_TOKEN, token);
if (token != null && DEVICE_TOKEN == "") {
if (token != null) {
DEVICE_TOKEN = token;
checkUserStatus(token);
}
@ -410,9 +410,7 @@ class _LandingPageState extends State<LandingPage> with WidgetsBindingObserver {
SETTINGS,
);
else
Navigator.of(context).pushNamed(
WELCOME_LOGIN,
);
login();
}, //do something,
)
],
@ -553,4 +551,15 @@ class _LandingPageState extends State<LandingPage> with WidgetsBindingObserver {
_changeCurrentTab(2);
}
}
login() async {
var data = await sharedPref.getObject(IMEI_USER_DATA);
sharedPref.remove(REGISTER_DATA_FOR_LOGIIN);
if (data != null) {
Navigator.of(context).pushNamed(CONFIRM_LOGIN);
} else {
Navigator.of(context).pushNamed(
WELCOME_LOGIN,
);
}
}
}

@ -370,7 +370,7 @@ class _ConfirmLogin extends State<ConfirmLogin> {
if (authenticated == true) {
if(user.logInType==2 || user.logInType ==3){
if(user !=null && (user.logInType==2 || user.logInType ==3)){
this.checkActivationCode();
}else{
var request = this.getCommonRequest(type: type);

Loading…
Cancel
Save