Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
portal-apps-manage
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Issues
0
Issues
0
List
Board
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
angular
portal-apps-manage
Commits
f56ef00d
Commit
f56ef00d
authored
Jul 23, 2025
by
DESKTOP-E3GSHH7\myhr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
module mylearn
parent
296dc2a1
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
98 additions
and
7 deletions
+98
-7
dashboard.component.css
src/app/DPU/mylearn/dashboard/dashboard.component.css
+0
-0
dashboard.component.html
src/app/DPU/mylearn/dashboard/dashboard.component.html
+3
-0
dashboard.component.spec.ts
src/app/DPU/mylearn/dashboard/dashboard.component.spec.ts
+28
-0
dashboard.component.ts
src/app/DPU/mylearn/dashboard/dashboard.component.ts
+16
-0
mylearn.module.ts
src/app/DPU/mylearn/mylearn.module.ts
+21
-3
header.component.html
src/app/shared/components/header/header.component.html
+1
-1
sidebar.component.html
src/app/shared/components/sidebar/sidebar.component.html
+1
-0
sidebar.component.ts
src/app/shared/components/sidebar/sidebar.component.ts
+11
-2
content.routes.ts
src/app/shared/routes/content.routes.ts
+3
-1
nav.service.ts
src/app/shared/services/nav.service.ts
+14
-0
No files found.
src/app/DPU/mylearn/dashboard/dashboard.component.css
0 → 100644
View file @
f56ef00d
src/app/DPU/mylearn/dashboard/dashboard.component.html
0 → 100644
View file @
f56ef00d
<p>
dashboard works!
</p>
src/app/DPU/mylearn/dashboard/dashboard.component.spec.ts
0 → 100644
View file @
f56ef00d
/* tslint:disable:no-unused-variable */
import
{
async
,
ComponentFixture
,
TestBed
}
from
'@angular/core/testing'
;
import
{
By
}
from
'@angular/platform-browser'
;
import
{
DebugElement
}
from
'@angular/core'
;
import
{
DashboardComponent
}
from
'./dashboard.component'
;
describe
(
'DashboardComponent'
,
()
=>
{
let
component
:
DashboardComponent
;
let
fixture
:
ComponentFixture
<
DashboardComponent
>
;
beforeEach
(
async
(()
=>
{
TestBed
.
configureTestingModule
({
declarations
:
[
DashboardComponent
]
})
.
compileComponents
();
}));
beforeEach
(()
=>
{
fixture
=
TestBed
.
createComponent
(
DashboardComponent
);
component
=
fixture
.
componentInstance
;
fixture
.
detectChanges
();
});
it
(
'should create'
,
()
=>
{
expect
(
component
).
toBeTruthy
();
});
});
src/app/DPU/mylearn/dashboard/dashboard.component.ts
0 → 100644
View file @
f56ef00d
import
{
Component
,
OnInit
}
from
'@angular/core'
;
@
Component
({
selector
:
'app-dashboard'
,
templateUrl
:
'./dashboard.component.html'
,
styleUrls
:
[
'./dashboard.component.css'
],
standalone
:
true
,
})
export
class
DashboardComponent
implements
OnInit
{
constructor
()
{
}
ngOnInit
()
{
}
}
src/app/DPU/mylearn/mylearn.module.ts
View file @
f56ef00d
import
{
NgModule
}
from
'@angular/core'
;
import
{
NgModule
}
from
'@angular/core'
;
import
{
CommonModule
}
from
'@angular/common'
;
import
{
CommonModule
}
from
'@angular/common'
;
import
{
MylearnComponent
}
from
'./mylearn.component'
;
import
{
MylearnComponent
}
from
'./mylearn.component'
;
import
{
RouterModule
,
Routes
}
from
'@angular/router'
;
export
const
mylearn
:
Routes
=
[
{
path
:
"mylearn"
,
children
:[
{
path
:
'dashboard'
,
loadComponent
:
()
=>
import
(
'./dashboard/dashboard.component'
).
then
((
m
)
=>
m
.
DashboardComponent
),
}
]
}
]
@
NgModule
({
@
NgModule
({
imports
:
[
imports
:
[
CommonModule
CommonModule
,
RouterModule
.
forChild
(
mylearn
),
],
],
declarations
:
[
MylearnComponent
]
declarations
:
[
MylearnComponent
],
exports
:
[
RouterModule
],
})
})
export
class
MylearnModule
{
}
export
class
MylearnModule
{
static
routes
=
mylearn
;
}
src/app/shared/components/header/header.component.html
View file @
f56ef00d
...
@@ -343,7 +343,7 @@
...
@@ -343,7 +343,7 @@
</div>
</div>
<div
class=
""
>
<div
class=
""
>
<a
routerLink=
"/
admin
"
<a
routerLink=
"/
mylearn/dashboard
"
class=
"p-4 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"
>
class=
"p-4 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"
>
<img
src=
"./assets/images/logoallHR/mylearn-logo.png"
alt=
"miscrosoft"
<img
src=
"./assets/images/logoallHR/mylearn-logo.png"
alt=
"miscrosoft"
class=
"leading-[1.75] text-2xl !h-[1.75rem] align-middle flex justify-center mx-auto"
>
class=
"leading-[1.75] text-2xl !h-[1.75rem] align-middle flex justify-center mx-auto"
>
...
...
src/app/shared/components/sidebar/sidebar.component.html
View file @
f56ef00d
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
<a
class=
"header-logo"
>
<a
class=
"header-logo"
>
<img
*
ngIf=
"isCommonRoute"
src=
"./assets/images/brand-logos/logo.png"
alt=
"logo"
width=
"100%"
>
<img
*
ngIf=
"isCommonRoute"
src=
"./assets/images/brand-logos/logo.png"
alt=
"logo"
width=
"100%"
>
<img
*
ngIf=
"isMyportalRoute"
src=
"./assets/images/logoallHR/mySkill-x.png"
alt=
"logo"
width=
"100%"
>
<img
*
ngIf=
"isMyportalRoute"
src=
"./assets/images/logoallHR/mySkill-x.png"
alt=
"logo"
width=
"100%"
>
<img
*
ngIf=
"isMylearnRoute"
src=
"./assets/images/logoallHR/mylearn-logo.png"
alt=
"logo"
width=
"100%"
>
</a>
</a>
...
...
src/app/shared/components/sidebar/sidebar.component.ts
View file @
f56ef00d
...
@@ -70,6 +70,7 @@ export class SidebarComponent {
...
@@ -70,6 +70,7 @@ export class SidebarComponent {
isCommonRoute
:
boolean
=
false
;
isCommonRoute
:
boolean
=
false
;
isInstallerRoute
:
boolean
=
false
;
isInstallerRoute
:
boolean
=
false
;
isMyportalRoute
:
boolean
=
false
;
isMyportalRoute
:
boolean
=
false
;
isMylearnRoute
:
boolean
=
false
;
previousUrl
:
string
=
''
;
previousUrl
:
string
=
''
;
currentUrl
:
string
=
''
;
currentUrl
:
string
=
''
;
...
@@ -138,12 +139,15 @@ export class SidebarComponent {
...
@@ -138,12 +139,15 @@ export class SidebarComponent {
this
.
isCommonRoute
=
this
.
currentUrl
.
includes
(
'/admin'
);
this
.
isCommonRoute
=
this
.
currentUrl
.
includes
(
'/admin'
);
this
.
isInstallerRoute
=
this
.
currentUrl
.
includes
(
'/company'
);
this
.
isInstallerRoute
=
this
.
currentUrl
.
includes
(
'/company'
);
this
.
isMyportalRoute
=
this
.
currentUrl
.
includes
(
'/myportal'
);
this
.
isMyportalRoute
=
this
.
currentUrl
.
includes
(
'/myportal'
);
this
.
isMylearnRoute
=
this
.
currentUrl
.
includes
(
'/mylearn'
)
this
.
checkUrlChanges
()
this
.
checkUrlChanges
()
// Log to console for verification
// Log to console for verification
console
.
log
(
'Initial URL:'
,
this
.
currentUrl
);
console
.
log
(
'Initial URL:'
,
this
.
currentUrl
);
console
.
log
(
'Is Common Route:'
,
this
.
isCommonRoute
);
console
.
log
(
'Is Common Route:'
,
this
.
isCommonRoute
);
console
.
log
(
'Is Installer Route:'
,
this
.
isInstallerRoute
);
console
.
log
(
'Is Installer Route:'
,
this
.
isInstallerRoute
);
console
.
log
(
'Is Myportal Route:'
,
this
.
isMyportalRoute
);
console
.
log
(
'Is Myportal Route:'
,
this
.
isMyportalRoute
);
console
.
log
(
'mylearn routes'
,
this
.
isMylearnRoute
);
}
}
checkUrlChanges
():
void
{
checkUrlChanges
():
void
{
...
@@ -160,7 +164,9 @@ export class SidebarComponent {
...
@@ -160,7 +164,9 @@ export class SidebarComponent {
// Check if there's a change between /installer and /admin
// Check if there's a change between /installer and /admin
if
(
if
(
(
this
.
previousUrl
.
includes
(
'/company'
)
&&
this
.
currentUrl
.
includes
(
'/admin'
))
||
(
this
.
previousUrl
.
includes
(
'/company'
)
&&
this
.
currentUrl
.
includes
(
'/admin'
))
||
(
this
.
previousUrl
.
includes
(
'/admin'
)
&&
this
.
currentUrl
.
includes
(
'/company'
))
(
this
.
previousUrl
.
includes
(
'/admin'
)
&&
this
.
currentUrl
.
includes
(
'/company'
))
||
(
this
.
previousUrl
.
includes
(
'/myprotal'
)
&&
this
.
currentUrl
.
includes
(
'/myprotal'
))
||
(
this
.
previousUrl
.
includes
(
'/mylearn'
)
&&
this
.
currentUrl
.
includes
(
'/mylearn'
))
)
{
)
{
console
.
log
(
'URL changed between /installer and /admin.'
);
console
.
log
(
'URL changed between /installer and /admin.'
);
// Implement any logic needed when changing between /installer and /admin
// Implement any logic needed when changing between /installer and /admin
...
@@ -170,6 +176,7 @@ export class SidebarComponent {
...
@@ -170,6 +176,7 @@ export class SidebarComponent {
this
.
isCommonRoute
=
this
.
currentUrl
.
includes
(
'/admin'
);
this
.
isCommonRoute
=
this
.
currentUrl
.
includes
(
'/admin'
);
this
.
isInstallerRoute
=
this
.
currentUrl
.
includes
(
'/company'
);
this
.
isInstallerRoute
=
this
.
currentUrl
.
includes
(
'/company'
);
this
.
isMyportalRoute
=
this
.
currentUrl
.
includes
(
'/myportal'
);
this
.
isMyportalRoute
=
this
.
currentUrl
.
includes
(
'/myportal'
);
this
.
isMylearnRoute
=
this
.
currentUrl
.
includes
(
'/mylearn'
)
// Log to console for verification
// Log to console for verification
console
.
log
(
'Current URL:'
,
this
.
currentUrl
);
console
.
log
(
'Current URL:'
,
this
.
currentUrl
);
...
@@ -196,7 +203,9 @@ export class SidebarComponent {
...
@@ -196,7 +203,9 @@ export class SidebarComponent {
this
.
menuItems
=
this
.
navServices
.
getCompanyMenu
();
this
.
menuItems
=
this
.
navServices
.
getCompanyMenu
();
}
else
if
(
this
.
isMyportalRoute
){
}
else
if
(
this
.
isMyportalRoute
){
this
.
menuItems
=
this
.
navServices
.
getMyportalMenu
();
this
.
menuItems
=
this
.
navServices
.
getMyportalMenu
();
}
else
{
}
else
if
(
this
.
isMylearnRoute
){
this
.
menuItems
=
this
.
navServices
.
getMylearnMenu
();
}
else
{
this
.
menuItems
=
this
.
navServices
.
getCommonMenu
();
this
.
menuItems
=
this
.
navServices
.
getCommonMenu
();
}
}
...
...
src/app/shared/routes/content.routes.ts
View file @
f56ef00d
...
@@ -29,6 +29,7 @@ import { tablesRoutingModule } from '../../components/tables/tables.routes';
...
@@ -29,6 +29,7 @@ import { tablesRoutingModule } from '../../components/tables/tables.routes';
import
{
CommonManageModule
}
from
'../../DPU/common/common.module'
;
import
{
CommonManageModule
}
from
'../../DPU/common/common.module'
;
import
{
CompanyManagementModule
}
from
'../../DPU/company-management/company-management.module'
;
import
{
CompanyManagementModule
}
from
'../../DPU/company-management/company-management.module'
;
import
{
MyskillXModule
}
from
'../../DPU/myskill-x/myskill-x.module'
;
import
{
MyskillXModule
}
from
'../../DPU/myskill-x/myskill-x.module'
;
import
{
MylearnModule
}
from
'../../DPU/mylearn/mylearn.module'
;
export
const
content
:
Routes
=
[
export
const
content
:
Routes
=
[
...
@@ -63,7 +64,8 @@ export const content: Routes = [
...
@@ -63,7 +64,8 @@ export const content: Routes = [
...
tablesRoutingModule
.
routes
,
...
tablesRoutingModule
.
routes
,
...
CommonManageModule
.
routes
,
...
CommonManageModule
.
routes
,
...
CompanyManagementModule
.
routes
,
...
CompanyManagementModule
.
routes
,
...
MyskillXModule
.
routes
...
MyskillXModule
.
routes
,
...
MylearnModule
.
routes
]
]
}
}
...
...
src/app/shared/services/nav.service.ts
View file @
f56ef00d
...
@@ -272,5 +272,19 @@ export class NavService implements OnDestroy {
...
@@ -272,5 +272,19 @@ export class NavService implements OnDestroy {
];
];
}
}
getMylearnMenu
()
{
return
[
// Myportal
{
headTitle
:
'Mylearn'
},
{
icon
:
'receipt'
,
path
:
'/mylearn/dashboard'
,
title
:
'dashboard'
,
type
:
'link'
,
},
];
}
items
=
new
BehaviorSubject
<
Menu
[]
>
(
this
.
MENUITEMS
);
items
=
new
BehaviorSubject
<
Menu
[]
>
(
this
.
MENUITEMS
);
}
}
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