Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
Lamarts mobile app angular
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Arko Dey Bhowmick
Lamarts mobile app angular
Commits
bd2ffcb0
Commit
bd2ffcb0
authored
Apr 25, 2025
by
achinta
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wip: change-password
parent
a5877609
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
83 additions
and
15 deletions
+83
-15
package-lock.json
package-lock.json
+2
-2
src/app/component-library/toaster/toaster.service.ts
src/app/component-library/toaster/toaster.service.ts
+1
-1
src/app/mappers/transmission-mapper.service.ts
src/app/mappers/transmission-mapper.service.ts
+3
-0
src/app/portal/assignment/assignment/assignment.component.ts
src/app/portal/assignment/assignment/assignment.component.ts
+4
-1
src/app/portal/navigation/sidebar/sidebar.component.html
src/app/portal/navigation/sidebar/sidebar.component.html
+1
-1
src/app/portal/navigation/sidebar/sidebar.component.scss
src/app/portal/navigation/sidebar/sidebar.component.scss
+4
-2
src/app/portal/navigation/sidebar/sidebar.component.ts
src/app/portal/navigation/sidebar/sidebar.component.ts
+2
-2
src/app/portal/navigation/topbar/topbar.component.ts
src/app/portal/navigation/topbar/topbar.component.ts
+1
-0
src/app/portal/portal-dashboard/portal-dashboard.component.ts
...app/portal/portal-dashboard/portal-dashboard.component.ts
+4
-1
src/app/portal/portal/portal.component.scss
src/app/portal/portal/portal.component.scss
+3
-1
src/app/portal/profile/change-password/change-password.component.ts
...rtal/profile/change-password/change-password.component.ts
+31
-4
src/app/raintree/transmission/auth-transmission.service.ts
src/app/raintree/transmission/auth-transmission.service.ts
+22
-0
src/app/raintree/transmission/jwt.service.ts
src/app/raintree/transmission/jwt.service.ts
+1
-0
src/styles.scss
src/styles.scss
+4
-0
No files found.
package-lock.json
View file @
bd2ffcb0
{
{
"name"
:
"
nkda
"
,
"name"
:
"
lamarts
"
,
"version"
:
"0.0.0"
,
"version"
:
"0.0.0"
,
"lockfileVersion"
:
3
,
"lockfileVersion"
:
3
,
"requires"
:
true
,
"requires"
:
true
,
"packages"
:
{
"packages"
:
{
""
:
{
""
:
{
"name"
:
"
nkda
"
,
"name"
:
"
lamarts
"
,
"version"
:
"0.0.0"
,
"version"
:
"0.0.0"
,
"dependencies"
:
{
"dependencies"
:
{
"@angular/cdk"
:
"^19.1.3"
,
"@angular/cdk"
:
"^19.1.3"
,
...
...
src/app/component-library/toaster/toaster.service.ts
View file @
bd2ffcb0
...
@@ -25,7 +25,7 @@ export class ToasterService {
...
@@ -25,7 +25,7 @@ export class ToasterService {
private
_openSnackBar
(
custom_class
:
string
,
message
:
string
,
action
?:
string
):
void
{
private
_openSnackBar
(
custom_class
:
string
,
message
:
string
,
action
?:
string
):
void
{
this
.
_snackBar
.
open
(
message
,
action
,{
this
.
_snackBar
.
open
(
message
,
action
,{
panelClass
:
[
custom_class
]
,
panelClass
:
custom_class
?
'
snack_custom_class
'
:
''
,
duration
:
2000
,
duration
:
2000
,
verticalPosition
:
"
top
"
,
// Allowed values are 'top' | 'bottom'
verticalPosition
:
"
top
"
,
// Allowed values are 'top' | 'bottom'
horizontalPosition
:
"
right
"
// Allowed values are 'start' | 'center' | 'end' | 'left' | 'right'
horizontalPosition
:
"
right
"
// Allowed values are 'start' | 'center' | 'end' | 'left' | 'right'
...
...
src/app/mappers/transmission-mapper.service.ts
View file @
bd2ffcb0
...
@@ -17,6 +17,9 @@ export class TransmissionMapperService {
...
@@ -17,6 +17,9 @@ export class TransmissionMapperService {
public
static
readonly
USER_PROFILE_TRANSMISSION_URL
:
string
=
public
static
readonly
USER_PROFILE_TRANSMISSION_URL
:
string
=
TransmissionMapperService
.
DEV_TRANSMISSION_URL
+
'
/user/get-profile
'
;
TransmissionMapperService
.
DEV_TRANSMISSION_URL
+
'
/user/get-profile
'
;
public
static
readonly
CHANGE_PASSWORD_TRANSMISSION_URL
:
string
=
TransmissionMapperService
.
DEV_TRANSMISSION_URL
+
'
/webomagic-user/v1/user/change-password
'
;
public
static
readonly
GET_TRANSMISSION_URL
:
string
=
public
static
readonly
GET_TRANSMISSION_URL
:
string
=
TransmissionMapperService
.
DEV_TRANSMISSION_URL
+
'
/webomagic/getWebDataSourceByWebsiteDataSourceForFilter?
'
;
TransmissionMapperService
.
DEV_TRANSMISSION_URL
+
'
/webomagic/getWebDataSourceByWebsiteDataSourceForFilter?
'
;
...
...
src/app/portal/assignment/assignment/assignment.component.ts
View file @
bd2ffcb0
...
@@ -33,7 +33,10 @@ import { provideNativeDateAdapter } from '@angular/material/core';
...
@@ -33,7 +33,10 @@ import { provideNativeDateAdapter } from '@angular/material/core';
],
],
standalone
:
true
,
standalone
:
true
,
templateUrl
:
'
./assignment.component.html
'
,
templateUrl
:
'
./assignment.component.html
'
,
styleUrl
:
'
./assignment.component.scss
'
,
styleUrls
:
[
'
./assignment.component.scss
'
,
'
../../../style-guide/css/theme.scss
'
],
providers
:
[
provideNativeDateAdapter
(),
provideNativeDateAdapter
(),
DatePipe
],
providers
:
[
provideNativeDateAdapter
(),
provideNativeDateAdapter
(),
DatePipe
],
})
})
...
...
src/app/portal/navigation/sidebar/sidebar.component.html
View file @
bd2ffcb0
...
@@ -65,6 +65,6 @@
...
@@ -65,6 +65,6 @@
</div>
</div>
<div
class=
"theme_mode_changer"
>
<div
class=
"theme_mode_changer"
>
<
app-theme-mode-changer
/
>
<
!-- <app-theme-mode-changer /> --
>
</div>
</div>
</div>
</div>
\ No newline at end of file
src/app/portal/navigation/sidebar/sidebar.component.scss
View file @
bd2ffcb0
...
@@ -5,7 +5,9 @@
...
@@ -5,7 +5,9 @@
justify-content
:
space-between
;
justify-content
:
space-between
;
// position: relative;
// position: relative;
}
}
.sidebar_navigation_container
{
margin-left
:
30px
;
}
.sidebar_navigation_container
a
{
.sidebar_navigation_container
a
{
color
:
var
(
--
secondary-color
);
color
:
var
(
--
secondary-color
);
}
}
...
@@ -22,7 +24,7 @@
...
@@ -22,7 +24,7 @@
flex-direction
:
row
;
flex-direction
:
row
;
// margin-top: 20px;
// margin-top: 20px;
padding
:
10px
0px
;
padding
:
10px
0px
;
font-size
:
1
4
px
;
font-size
:
1
8
px
;
justify-content
:
space-between
;
justify-content
:
space-between
;
a
{
a
{
...
...
src/app/portal/navigation/sidebar/sidebar.component.ts
View file @
bd2ffcb0
...
@@ -2,7 +2,7 @@ import { Component, effect, inject, OnInit } from '@angular/core';
...
@@ -2,7 +2,7 @@ import { Component, effect, inject, OnInit } from '@angular/core';
import
{
Router
,
RouterModule
}
from
'
@angular/router
'
;
import
{
Router
,
RouterModule
}
from
'
@angular/router
'
;
import
{
Menu
}
from
'
../model/sidebar/menu
'
;
import
{
Menu
}
from
'
../model/sidebar/menu
'
;
import
{
Sidebar
}
from
'
../interface/sidebar
'
;
import
{
Sidebar
}
from
'
../interface/sidebar
'
;
import
{
ThemeModeChangerComponent
}
from
'
../../../component-library/theme-mode-changer/theme-mode-changer.component
'
;
//
import { ThemeModeChangerComponent } from '../../../component-library/theme-mode-changer/theme-mode-changer.component';
import
{
CommonModule
}
from
'
@angular/common
'
;
import
{
CommonModule
}
from
'
@angular/common
'
;
import
{
InitThemeService
}
from
'
../../../style-guide/service/initialize-theme.service
'
;
import
{
InitThemeService
}
from
'
../../../style-guide/service/initialize-theme.service
'
;
// import { InitThemeService } from '../../../style-guide/service/initialize-theme.service';
// import { InitThemeService } from '../../../style-guide/service/initialize-theme.service';
...
@@ -12,7 +12,7 @@ import { InitThemeService } from '../../../style-guide/service/initialize-theme.
...
@@ -12,7 +12,7 @@ import { InitThemeService } from '../../../style-guide/service/initialize-theme.
imports
:
[
imports
:
[
CommonModule
,
CommonModule
,
RouterModule
,
RouterModule
,
ThemeModeChangerComponent
//
ThemeModeChangerComponent
],
],
templateUrl
:
'
./sidebar.component.html
'
,
templateUrl
:
'
./sidebar.component.html
'
,
styleUrl
:
'
./sidebar.component.scss
'
styleUrl
:
'
./sidebar.component.scss
'
...
...
src/app/portal/navigation/topbar/topbar.component.ts
View file @
bd2ffcb0
...
@@ -34,6 +34,7 @@ export class TopBarComponent {
...
@@ -34,6 +34,7 @@ export class TopBarComponent {
}
}
public
logout
():
void
{
public
logout
():
void
{
if
(
!
confirm
(
"
Are you sure you want to log out?
"
))
return
;
this
.
_logoutService
.
logout
();
this
.
_logoutService
.
logout
();
}
}
...
...
src/app/portal/portal-dashboard/portal-dashboard.component.ts
View file @
bd2ffcb0
...
@@ -25,7 +25,10 @@ import { TeacherTransmissionService } from '../../raintree/transmission/teacher-
...
@@ -25,7 +25,10 @@ import { TeacherTransmissionService } from '../../raintree/transmission/teacher-
],
],
standalone
:
true
,
standalone
:
true
,
templateUrl
:
'
./portal-dashboard.component.html
'
,
templateUrl
:
'
./portal-dashboard.component.html
'
,
styleUrl
:
'
./portal-dashboard.component.scss
'
styleUrls
:
[
'
./portal-dashboard.component.scss
'
,
'
../../style-guide/css/theme.scss
'
]
})
})
export
class
PortalDashboardComponent
implements
OnInit
{
export
class
PortalDashboardComponent
implements
OnInit
{
...
...
src/app/portal/portal/portal.component.scss
View file @
bd2ffcb0
...
@@ -2,6 +2,7 @@
...
@@ -2,6 +2,7 @@
display
:
flex
;
display
:
flex
;
flex-wrap
:
wrap
;
flex-wrap
:
wrap
;
height
:
100%
;
height
:
100%
;
// margin-top: 30px;
.sidebar
{
.sidebar
{
width
:
250px
;
width
:
250px
;
background-color
:
var
(
--
secondary-bg-color
);
background-color
:
var
(
--
secondary-bg-color
);
...
@@ -27,12 +28,13 @@
...
@@ -27,12 +28,13 @@
.top_bar
{
.top_bar
{
width
:
100%
;
width
:
100%
;
background-color
:
var
(
--
secondary-bg-color
);
background-color
:
var
(
--
secondary-bg-color
);
margin-top
:
30px
;
}
}
@media
only
screen
and
(
max-width
:
999px
)
and
(
min-width
:
300px
)
{
@media
only
screen
and
(
max-width
:
999px
)
and
(
min-width
:
300px
)
{
.sidebar
{
.sidebar
{
width
:
25
0px
;
width
:
30
0px
;
background-color
:
var
(
--
secondary-bg-color
);
background-color
:
var
(
--
secondary-bg-color
);
padding-left
:
20px
;
padding-left
:
20px
;
height
:
100%
;
height
:
100%
;
...
...
src/app/portal/profile/change-password/change-password.component.ts
View file @
bd2ffcb0
...
@@ -6,6 +6,9 @@ import { MatInputModule } from '@angular/material/input';
...
@@ -6,6 +6,9 @@ import { MatInputModule } from '@angular/material/input';
import
{
MatSelectModule
}
from
'
@angular/material/select
'
;
import
{
MatSelectModule
}
from
'
@angular/material/select
'
;
import
{
SquareButtonComponent
}
from
"
../../../component-library/square-button/square-button.component
"
;
import
{
SquareButtonComponent
}
from
"
../../../component-library/square-button/square-button.component
"
;
import
{
ToasterService
}
from
'
../../../component-library/toaster/toaster.service
'
;
import
{
ToasterService
}
from
'
../../../component-library/toaster/toaster.service
'
;
import
{
AuthTransmissionService
}
from
'
../../../raintree/transmission/auth-transmission.service
'
;
import
{
TransmissionMapperService
}
from
'
../../../mappers/transmission-mapper.service
'
;
import
{
RaintreeResponse
}
from
'
../../../raintree/interface/raintree-response
'
;
@
Component
({
@
Component
({
selector
:
'
app-change-password
'
,
selector
:
'
app-change-password
'
,
...
@@ -16,13 +19,14 @@ import { ToasterService } from '../../../component-library/toaster/toaster.servi
...
@@ -16,13 +19,14 @@ import { ToasterService } from '../../../component-library/toaster/toaster.servi
ReactiveFormsModule
,
ReactiveFormsModule
,
MatInputModule
,
MatInputModule
,
SquareButtonComponent
SquareButtonComponent
],
],
templateUrl
:
'
./change-password.component.html
'
,
templateUrl
:
'
./change-password.component.html
'
,
styleUrl
:
'
./change-password.component.scss
'
styleUrl
:
'
./change-password.component.scss
'
})
})
export
class
ChangePasswordComponent
{
export
class
ChangePasswordComponent
{
public
toaster
=
inject
(
ToasterService
)
public
toaster
=
inject
(
ToasterService
);
private
_auth
=
inject
(
AuthTransmissionService
);
public
updatePasswordForm
=
new
FormGroup
({
public
updatePasswordForm
=
new
FormGroup
({
currentPassword
:
new
FormControl
(
""
,
[
Validators
.
required
]),
currentPassword
:
new
FormControl
(
""
,
[
Validators
.
required
]),
...
@@ -31,13 +35,36 @@ export class ChangePasswordComponent {
...
@@ -31,13 +35,36 @@ export class ChangePasswordComponent {
});
});
public
changePassword
():
void
{
public
changePassword
():
void
{
if
(
this
.
updatePasswordForm
.
invalid
)
return
;
if
(
this
.
updatePasswordForm
.
invalid
)
return
;
if
(
this
.
updatePasswordForm
.
value
.
confirmPassword
!==
this
.
updatePasswordForm
.
value
.
newPassword
)
{
if
(
this
.
updatePasswordForm
.
value
.
confirmPassword
!==
this
.
updatePasswordForm
.
value
.
newPassword
)
{
this
.
toaster
.
error
(
"
Confirm password does not match new password
"
,
'
Ok
'
);
this
.
toaster
.
error
(
"
Confirm password does not match new password
"
,
'
Ok
'
);
return
;
return
;
}
}
console
.
log
(
this
.
updatePasswordForm
.
value
);
console
.
log
(
this
.
updatePasswordForm
.
value
);
// call API for change password
// call API for change password
this
.
_auth
.
changePassword
(
TransmissionMapperService
.
CHANGE_PASSWORD_TRANSMISSION_URL
,
{
"
old_password
"
:
`
${
this
.
updatePasswordForm
.
value
.
currentPassword
}
`
,
"
new_password
"
:
`
${
this
.
updatePasswordForm
.
value
.
newPassword
}
`
},
()
=>
{
},
()
=>
{
},
(
response
:
RaintreeResponse
)
=>
{
console
.
log
(
response
);
},
(
error
)
=>
{
console
.
log
(
error
);
},
()
=>
{
}
);
}
}
// {
// {
...
...
src/app/raintree/transmission/auth-transmission.service.ts
View file @
bd2ffcb0
...
@@ -57,4 +57,26 @@ export class AuthTransmissionService extends TransmissionService {
...
@@ -57,4 +57,26 @@ export class AuthTransmissionService extends TransmissionService {
)
)
}
}
public
changePassword
(
url
:
string
,
payload
:
any
,
onPreExecute
:
()
=>
void
,
onPostExecute
:
(
response
:
any
)
=>
void
,
onSuccess
:
(
response
:
any
)
=>
void
,
onFailure
:
(
error
:
string
)
=>
void
,
onComplete
:
()
=>
void
):
void
{
this
.
executePostPayload
(
url
,
payload
,
onPreExecute
,
onPostExecute
,
onSuccess
,
onFailure
,
onComplete
,
true
)
}
}
}
src/app/raintree/transmission/jwt.service.ts
View file @
bd2ffcb0
...
@@ -21,6 +21,7 @@ export class JWTService {
...
@@ -21,6 +21,7 @@ export class JWTService {
"
user-id
"
:
userId
,
"
user-id
"
:
userId
,
"
apikey
"
:
authorizationToken
,
"
apikey
"
:
authorizationToken
,
'
Content-Type
'
:
'
application/json
'
,
'
Content-Type
'
:
'
application/json
'
,
// 'Project-Id': 278,
});
});
}
}
...
...
src/styles.scss
View file @
bd2ffcb0
...
@@ -54,3 +54,7 @@ body {
...
@@ -54,3 +54,7 @@ body {
fill
:
var
(
--
primary-color
)
!
important
;
fill
:
var
(
--
primary-color
)
!
important
;
}
}
}
}
.snack_custom_class
{
margin-top
:
30px
!
important
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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