Commit e9de2e4f by sawit

generateToken

parent 91bc8256
...@@ -19,6 +19,7 @@ import { Validators } from 'ngx-editor'; ...@@ -19,6 +19,7 @@ import { Validators } from 'ngx-editor';
import { EmployeeService } from '../../portal-manage/services/employee.service'; import { EmployeeService } from '../../portal-manage/services/employee.service';
import { EmployeeAuthService } from '../../portal-manage/services/employee-auth.service'; import { EmployeeAuthService } from '../../portal-manage/services/employee-auth.service';
import { JwtService } from '../../portal-manage/services/jwt.service'; import { JwtService } from '../../portal-manage/services/jwt.service';
import { GenarateTokenModel } from '../../portal-manage/models/auth.model';
@Component({ @Component({
selector: 'app-login', selector: 'app-login',
...@@ -149,6 +150,18 @@ export class LoginComponent { ...@@ -149,6 +150,18 @@ export class LoginComponent {
this.tokenService.saveToken(response.accessToken); this.tokenService.saveToken(response.accessToken);
} }
// Call generateToken after successful login
const tokenModel: GenarateTokenModel = {
username: response.username,
memberId: response.memberId,
accessToken: response.accessToken,
role: '', // Unknown, set to empty string
modules: [] // Unknown, set to empty array
};
this.authService.generateToken(tokenModel).subscribe(tokenResponse => {
console.log('Token generation response:', tokenResponse);
});
// ตรวจสอบว่าเป็น JWT token หรือไม่ // ตรวจสอบว่าเป็น JWT token หรือไม่
if (response.accessToken && this.isJwtToken(response.accessToken)) { if (response.accessToken && this.isJwtToken(response.accessToken)) {
console.log('JWT token detected, processing...'); console.log('JWT token detected, processing...');
......
...@@ -9,6 +9,7 @@ import { UserRoleService } from '../services/user-role.service'; ...@@ -9,6 +9,7 @@ import { UserRoleService } from '../services/user-role.service';
import { EmployeeAuthService, Employee } from '../services/employee-auth.service'; import { EmployeeAuthService, Employee } from '../services/employee-auth.service';
import { EmployeeFromJwt } from '../models/jwt-token.model'; import { EmployeeFromJwt } from '../models/jwt-token.model';
import { FormsModule } from '@angular/forms'; import { FormsModule } from '@angular/forms';
import { environment } from '../../../environments/environment';
interface AppModule { interface AppModule {
id: string; id: string;
...@@ -27,6 +28,7 @@ interface AppModule { ...@@ -27,6 +28,7 @@ interface AppModule {
export: boolean; export: boolean;
import: boolean; import: boolean;
}; };
appUrl?: string;
} }
interface AppCategory { interface AppCategory {
...@@ -214,8 +216,8 @@ export class HomeComponent implements OnInit { ...@@ -214,8 +216,8 @@ export class HomeComponent implements OnInit {
return [ return [
// แอปพลิเคชันที่เข้าถึงได้ // แอปพลิเคชันที่เข้าถึงได้
{ {
id: 'myhr-plus', id: 'MYHR',
name: 'myhr-plus', name: 'MYHR',
displayName: 'myHR-Plus', displayName: 'myHR-Plus',
description: 'ระบบจัดการทรัพยากรบุคคลขั้นสูง', description: 'ระบบจัดการทรัพยากรบุคคลขั้นสูง',
icon: './assets/images/logoallHR/myhr-plus.jpg', icon: './assets/images/logoallHR/myhr-plus.jpg',
...@@ -225,8 +227,8 @@ export class HomeComponent implements OnInit { ...@@ -225,8 +227,8 @@ export class HomeComponent implements OnInit {
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true }
}, },
{ {
id: 'myhr-lite', id: 'MYHR-LITE',
name: 'myhr-lite', name: 'MYHR-LITE',
displayName: 'myHR-Lite', displayName: 'myHR-Lite',
description: 'ระบบจัดการทรัพยากรบุคคลพื้นฐาน', description: 'ระบบจัดการทรัพยากรบุคคลพื้นฐาน',
icon: './assets/images/logoallHR/myHR-Lite-logo-new.png', icon: './assets/images/logoallHR/myHR-Lite-logo-new.png',
...@@ -236,8 +238,8 @@ export class HomeComponent implements OnInit { ...@@ -236,8 +238,8 @@ export class HomeComponent implements OnInit {
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true }
}, },
{ {
id: 'zeeme', id: 'ZEESERVER',
name: 'zeeme', name: 'ZEESERVER',
displayName: 'Zeeme Plus', displayName: 'Zeeme Plus',
description: 'ระบบจัดการเวลาและลงเวลา', description: 'ระบบจัดการเวลาและลงเวลา',
icon: './assets/images/logoallHR/zeemePlus.png', icon: './assets/images/logoallHR/zeemePlus.png',
...@@ -247,8 +249,8 @@ export class HomeComponent implements OnInit { ...@@ -247,8 +249,8 @@ export class HomeComponent implements OnInit {
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true }
}, },
{ {
id: 'myface', id: 'MYFACE',
name: 'myface', name: 'MYFACE',
displayName: 'myFace', displayName: 'myFace',
description: 'ระบบจัดการใบหน้าและความปลอดภัย', description: 'ระบบจัดการใบหน้าและความปลอดภัย',
icon: './assets/images/logoallHR/logo_myface.png', icon: './assets/images/logoallHR/logo_myface.png',
...@@ -258,8 +260,8 @@ export class HomeComponent implements OnInit { ...@@ -258,8 +260,8 @@ export class HomeComponent implements OnInit {
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true }
}, },
{ {
id: 'mylearn', id: 'MYLEARN',
name: 'mylearn', name: 'MYLEARN',
displayName: 'myLearn', displayName: 'myLearn',
description: 'ระบบจัดการการเรียนรู้และฝึกอบรม', description: 'ระบบจัดการการเรียนรู้และฝึกอบรม',
icon: './assets/images/logoallHR/mylearn-logo.png', icon: './assets/images/logoallHR/mylearn-logo.png',
...@@ -269,19 +271,20 @@ export class HomeComponent implements OnInit { ...@@ -269,19 +271,20 @@ export class HomeComponent implements OnInit {
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true }
}, },
{ {
id: 'myjob', id: 'MYJOB',
name: 'myjob', name: 'MYJOB',
displayName: 'myJob', displayName: 'myJob',
description: 'ระบบจัดการงานและโครงการ', description: 'ระบบจัดการงานและโครงการ',
icon: './assets/images/logoallHR/logo_myjob.png', icon: './assets/images/logoallHR/logo_myjob.png',
path: '/portal-manage/myjob', path: '/portal-manage/myjob',
isVisible: true, isVisible: true,
category: 'applications', category: 'applications',
permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true } permissions: { view: true, create: true, edit: true, delete: true, export: true, import: true },
appUrl: environment.url
}, },
{ {
id: 'myskill-x', id: 'MYSKILL-X',
name: 'myskill-x', name: 'MYSKILL-X',
displayName: 'mySkill-X', displayName: 'mySkill-X',
description: 'ระบบจัดการทักษะและความสามารถ', description: 'ระบบจัดการทักษะและความสามารถ',
icon: './assets/images/logoallHR/mySkill-x.png', icon: './assets/images/logoallHR/mySkill-x.png',
......
...@@ -12,6 +12,29 @@ export interface AuthModel { ...@@ -12,6 +12,29 @@ export interface AuthModel {
company: CompanyModelS company: CompanyModelS
} }
export interface GenarateTokenModel {
username: string
memberId: string
role: string
accessToken: string
modules: GenerateTokenModule[]
}
export interface GenerateTokenModule {
app: string
accessToken: string
refreshToken: string
}
export interface AppRefreshTokenModel {
username: string
memberId: string
role: string
accessToken: string
refreshToken: string
}
export class AuthModel extends BaseModel implements AuthModel { export class AuthModel extends BaseModel implements AuthModel {
username: string username: string
password: string password: string
......
...@@ -315,7 +315,7 @@ ...@@ -315,7 +315,7 @@
<div class="grid grid-cols-4 gap-3 min-h-0"> <div class="grid grid-cols-4 gap-3 min-h-0">
<!-- myHR-Plus --> <!-- myHR-Plus -->
<div class=""> <div class="">
<a (click)="checkAppToken('myhr-plus')" <a (click)="checkAppToken('MYHR')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/myhr-plus.jpg" alt="myHR-Plus" <img src="./assets/images/logoallHR/myhr-plus.jpg" alt="myHR-Plus"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -325,7 +325,7 @@ ...@@ -325,7 +325,7 @@
<!-- myHR-Lite --> <!-- myHR-Lite -->
<div class=""> <div class="">
<a (click)="checkAppToken('myhr-lite')" <a (click)="checkAppToken('MYHR-LITE')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/myHR-Lite-logo-new.png" alt="myHR-Lite" <img src="./assets/images/logoallHR/myHR-Lite-logo-new.png" alt="myHR-Lite"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -335,7 +335,7 @@ ...@@ -335,7 +335,7 @@
<!-- Zeeme Plus --> <!-- Zeeme Plus -->
<div class=""> <div class="">
<a (click)="checkAppToken('zeeme')" <a (click)="checkAppToken('ZEESERVER')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/zeemePlus.png" alt="Zeeme Plus" <img src="./assets/images/logoallHR/zeemePlus.png" alt="Zeeme Plus"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -345,7 +345,7 @@ ...@@ -345,7 +345,7 @@
<!-- myFace --> <!-- myFace -->
<div class=""> <div class="">
<a (click)="checkAppToken('myface')" <a (click)="checkAppToken('MYFACE')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/logo_myface.png" alt="myFace" <img src="./assets/images/logoallHR/logo_myface.png" alt="myFace"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -355,7 +355,7 @@ ...@@ -355,7 +355,7 @@
<!-- myLearn --> <!-- myLearn -->
<div class=""> <div class="">
<a (click)="checkAppToken('mylearn')" <a (click)="checkAppToken('MYLEARN')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 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="myLearn" <img src="./assets/images/logoallHR/mylearn-logo.png" alt="myLearn"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -365,7 +365,7 @@ ...@@ -365,7 +365,7 @@
<!-- myJob --> <!-- myJob -->
<div class=""> <div class="">
<a (click)="checkAppToken('myjob')" <a (click)="checkAppToken('MYJOB')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/logo_myjob.png" alt="myJob" <img src="./assets/images/logoallHR/logo_myjob.png" alt="myJob"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
...@@ -375,7 +375,7 @@ ...@@ -375,7 +375,7 @@
<!-- mySkill-X --> <!-- mySkill-X -->
<div class=""> <div class="">
<a (click)="checkAppToken('myskill-x')" <a (click)="checkAppToken('MYSKILL-X')"
class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20"> class="p-3 items-center related-app block text-center rounded-sm hover:bg-gray-50 dark:hover:bg-black/20">
<img src="./assets/images/logoallHR/mySkill-x.png" alt="mySkill-X" <img src="./assets/images/logoallHR/mySkill-x.png" alt="mySkill-X"
class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto"> class="leading-[1.5] text-2xl !h-[1.5rem] align-middle flex justify-center mx-auto">
......
import { GenarateTokenModel } from './../../portal-manage/models/auth.model';
import { Injectable, NgZone } from '@angular/core'; import { Injectable, NgZone } from '@angular/core';
import { HttpClient } from '@angular/common/http'; import { HttpClient } from '@angular/common/http';
import { LoginModel, ProfileModel, UserModel } from '../user-auth.model'; import { LoginModel, ProfileModel, UserModel } from '../user-auth.model';
import { environment } from '../../../environments/environment'; import { environment } from '../../../environments/environment';
import { Observable } from 'rxjs'; import { Observable, tap } from 'rxjs';
@Injectable({ @Injectable({
providedIn: 'root', providedIn: 'root',
}) })
export class AuthService { export class AuthService {
apiBaseUrl = "/auth/company"; apiBaseUrl = "/auth/company";
private apiUrl = environment.jbossUrl + '/usapi'; //add private apiUrl = environment.jbossUrl + '/usapi'; //add
public generatedTokenData: any;
constructor( constructor(
private http: HttpClient, private http: HttpClient,
) { ) {
...@@ -23,9 +25,9 @@ export class AuthService { ...@@ -23,9 +25,9 @@ export class AuthService {
// } // }
login(credentials: LoginModel): Observable<UserModel> { login(credentials: LoginModel): Observable<UserModel> {
credentials.dbName = credentials.dbName || 'DB'; credentials.dbName = credentials.dbName || 'DB';
credentials.dbcomp = credentials.dbcomp || '100'; credentials.dbcomp = credentials.dbcomp || '100';
credentials.lang = credentials.lang || 'tha'; credentials.lang = credentials.lang || 'tha';
return this.http.post<UserModel>(`${this.apiUrl}/authen`, credentials); return this.http.post<UserModel>(`${this.apiUrl}/authen`, credentials);
} }
...@@ -40,4 +42,18 @@ export class AuthService { ...@@ -40,4 +42,18 @@ export class AuthService {
return this.http.post<any>(this.apiBaseUrl + "/register", new ProfileModel()); return this.http.post<any>(this.apiBaseUrl + "/register", new ProfileModel());
} }
generateToken(body: GenarateTokenModel) {
return this.http.get<any>(environment.url + "/auth/generate-token",).pipe(tap(
response => {
this.generatedTokenData = response;
}
))
}
postPortalRefreshToken(appUrl: string){
return this.http.post<any>(appUrl + "/refresh-token", {
"refreshToken": this.generatedTokenData.refreshToken
});
}
} }
...@@ -8,12 +8,13 @@ import { CompanyModel } from "../../portal-manage/models/company.model"; ...@@ -8,12 +8,13 @@ import { CompanyModel } from "../../portal-manage/models/company.model";
import { environment } from "../../../environments/environment"; import { environment } from "../../../environments/environment";
// import jwt_decode from "jwt-decode"; // import jwt_decode from "jwt-decode";
const TOKEN_KEY = 'auth-token'; const TOKEN_KEY = 'hroffice-token';
const APP_TOKEN_KEY = 'app-token'; const APP_TOKEN_KEY = 'app-token';
const REFRESHTOKEN_KEY = 'auth-refreshtoken'; const REFRESHTOKEN_KEY = 'auth-refreshtoken';
const USER_KEY = 'auth-user'; const USER_KEY = 'auth-user';
const USER_DATA_KEY = 'auth-user-data'; const USER_DATA_KEY = 'auth-user-data';
const COMPANY = 'company'; const COMPANY = 'company';
const MODULE_KEY = 'module-token';
@Injectable({ @Injectable({
providedIn: "root", providedIn: "root",
...@@ -23,17 +24,17 @@ export class TokenService { ...@@ -23,17 +24,17 @@ export class TokenService {
throw new Error('Method not implemented.'); throw new Error('Method not implemented.');
} }
apptoken: any = { apptoken: any = {
"myhr-plus": "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJBdXRoIiwidWlkIjoiOGFhNDUzMzAtMzE0Yy0xMWU3LWJhZjMtMmQ3ZDA5ODc3NzQ0Iiwicm9sZXMiOlsiYWRtaW4iXSwiaXNzIjoiQ29tcHV0ZXIgU2NpZW5jZSBDb3Jwb3JhdGlvbiBMaW1pdGVkIiwidXNlcm5hbWUiOiJhZG1pbiJ9.Um39_CTM01n1g4XpFyuAa3VPxOozNPnJ0mu7kxU6KUs", "MYHR": "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJBdXRoIiwidWlkIjoiOGFhNDUzMzAtMzE0Yy0xMWU3LWJhZjMtMmQ3ZDA5ODc3NzQ0Iiwicm9sZXMiOlsiYWRtaW4iXSwiaXNzIjoiQ29tcHV0ZXIgU2NpZW5jZSBDb3Jwb3JhdGlvbiBMaW1pdGVkIiwidXNlcm5hbWUiOiJhZG1pbiJ9.Um39_CTM01n1g4XpFyuAa3VPxOozNPnJ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iXSwiaXNzIjoiQ29tcHV0ZXIgU2NpZW5jZSBDb3Jwb3JhdGlvbiBMaW1pdGVkIiwidXNlcm5hbWUiOiJhZG1pbiJ9.Um39_CTM01n1g4XpFyuAa3VPxOozNPnJ0mu7kxU6KUs",
} }
dbApp: any = { dbApp: any = {
"myhr-plus": { "MYHR": {
"companyId": "DEMO", "companyId": "DEMO",
"companyName": "DEMO", "companyName": "DEMO",
"serverName": "192.168.30.150", "serverName": "192.168.30.150",
...@@ -44,7 +45,7 @@ export class TokenService { ...@@ -44,7 +45,7 @@ export class TokenService {
"status": "online", "status": "online",
"dbType": "PGSQL" "dbType": "PGSQL"
}, },
"myhr-lite": { "MYHR-LITE": {
"companyId": "", "companyId": "",
"companyName": "", "companyName": "",
"serverName": "", "serverName": "",
...@@ -55,7 +56,7 @@ export class TokenService { ...@@ -55,7 +56,7 @@ export class TokenService {
"status": "", "status": "",
"dbType": "" "dbType": ""
}, },
"zeeme": { "ZEESERVER": {
"companyId": "", "companyId": "",
"companyName": "", "companyName": "",
"serverName": "", "serverName": "",
...@@ -66,7 +67,7 @@ export class TokenService { ...@@ -66,7 +67,7 @@ export class TokenService {
"status": "", "status": "",
"dbType": "" "dbType": ""
}, },
"myface": { "MYFACE": {
"companyId": "", "companyId": "",
"companyName": "", "companyName": "",
"serverName": "", "serverName": "",
...@@ -77,7 +78,7 @@ export class TokenService { ...@@ -77,7 +78,7 @@ export class TokenService {
"status": "", "status": "",
"dbType": "" "dbType": ""
}, },
"mylearn": { "MYLEARN": {
"companyId": "", "companyId": "",
"companyName": "", "companyName": "",
"serverName": "", "serverName": "",
...@@ -88,7 +89,7 @@ export class TokenService { ...@@ -88,7 +89,7 @@ export class TokenService {
"status": "", "status": "",
"dbType": "" "dbType": ""
}, },
"myjob": { "MYJOB": {
"companyId": "DEMO", "companyId": "DEMO",
"companyName": "DEMO", "companyName": "DEMO",
"databaseName": "DEMOCUS", "databaseName": "DEMOCUS",
...@@ -99,7 +100,7 @@ export class TokenService { ...@@ -99,7 +100,7 @@ export class TokenService {
"status": "online", "status": "online",
"userName": "myhradmin" "userName": "myhradmin"
}, },
"myskill-x": { "MYSKILL-X": {
"companyId": "MYSKILX_UAT", "companyId": "MYSKILX_UAT",
"companyName": "MYSKILX_UAT", "companyName": "MYSKILX_UAT",
"databaseName": "MYSKILL_X_UAT", "databaseName": "MYSKILL_X_UAT",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment