Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
hdastageeri
hft_awado_app
Commits
da0ae85b
Commit
da0ae85b
authored
5 years ago
by
Ratnadeep Rajendra Kharade
Browse files
Options
Download
Email Patches
Plain Diff
added loading page on login api call
parent
221d2907
master
18-design-feedback-page-2
20-ride-history-2
42-add-log-in-button-on-registration-page-add-extra-messages-for-email-and-password-validation
42-add-log-in-button-on-registration-page-add-extra-messages-for-email-and-password-validation-2
47-show-alternate-routes-for-bike-to-destination
51-while-navigating-between-pages-map-doesn-t-load-properly
52-page-loader-is-getting-displayed-everywhere
53-scrollining-in-ride-history
53-scrollining-in-ride-history-2
55-change-password
56-create-dummy-page-or-menu-for-hotline-contact
57-registration-not-working-from-app
58-add-flow-on-navigate-button-to-route-from-user-to-bike
60-create-common-theming-styles-and-colors
61-chnage-styles-for-bike-list-and-bug-fixes
62-change-in-feedback-workflow
63-password-reset-api-integration
64-close-button-on-home-page-to-redirect-to-bike-list
66-highlight-selected-route-from-list-of-different-routes
67-deactivate-user-api-integration
68-display-no-go-areas-on-map
69-add-launcher-icon-for-application-on-android
70-add-validation-for-feedback-should-not-be-empty
71-prediction-ui-implementation-send-location-of-bike-to-backend
72-feedback-toast-message
73-removal-here-maps-api-key
Show-Bike-details-when-bike-icon-is-clicked
search_functionality
1 merge request
!34
Resolve "While navigating between pages, map doesn't load properly."
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/app/auth/login/login.page.ts
+12
-4
src/app/auth/login/login.page.ts
with
12 additions
and
4 deletions
+12
-4
src/app/auth/login/login.page.ts
+
12
-
4
View file @
da0ae85b
import
{
Component
,
OnInit
}
from
'
@angular/core
'
;
import
{
Router
}
from
'
@angular/router
'
;
import
{
Router
,
LoadChildrenCallback
}
from
'
@angular/router
'
;
import
{
Observable
}
from
'
rxjs
'
;
import
{
HttpClient
}
from
'
@angular/common/http
'
;
import
{
RestService
}
from
'
../../rest.service
'
;
import
{
UserService
}
from
'
src/app/services/user.service
'
;
import
{
LocationService
}
from
'
src/app/services/location.service
'
;
import
{
LoadingService
}
from
'
src/app/services/loading.service
'
;
@
Component
({
selector
:
'
app-login
'
,
...
...
@@ -15,12 +17,15 @@ import { UserService } from 'src/app/services/user.service';
export
class
LoginPage
implements
OnInit
{
username
=
""
;
password
=
""
;
//username = "";
//password = "";
correctCredentials
=
false
;
loginApi
:
Observable
<
any
>
;
constructor
(
private
router
:
Router
,
public
httpClient
:
HttpClient
,
public
restService
:
RestService
,
public
userService
:
UserService
)
{
constructor
(
private
router
:
Router
,
public
httpClient
:
HttpClient
,
public
restService
:
RestService
,
public
userService
:
UserService
,
public
locationService
:
LocationService
,
public
loadingService
:
LoadingService
)
{
}
...
...
@@ -37,6 +42,7 @@ export class LoginPage implements OnInit {
"
email
"
:
this
.
username
,
"
password
"
:
this
.
password
});
this
.
loadingService
.
showLoader
();
this
.
loginApi
.
subscribe
((
data
)
=>
{
//console.log('my data: ', data);
...
...
@@ -44,9 +50,11 @@ export class LoginPage implements OnInit {
this
.
restService
.
isLoginPage
=
false
;
this
.
userService
.
setUsername
(
this
.
username
);
this
.
router
.
navigateByUrl
(
'
/home
'
);
this
.
loadingService
.
hideLoader
();
},
(
error
)
=>
{
console
.
log
(
JSON
.
stringify
(
error
));
this
.
correctCredentials
=
true
;
this
.
loadingService
.
hideLoader
();
});
}
register
()
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets