latestt changes

This commit is contained in:
govardhan
2025-08-19 14:03:53 +05:30
parent 911933074b
commit cfe68a276f
5 changed files with 29 additions and 8 deletions

View File

@ -1,4 +1,4 @@
import {Component, OnDestroy, OnInit} from '@angular/core';
import {Component, ElementRef, OnDestroy, OnInit, ViewChild} from '@angular/core';
import {BehaviorSubject} from "rxjs";
import {User} from "../../model/user";
import {UserService} from "../../service/user.service";
@ -10,6 +10,8 @@ import {CustomHttpResponse} from "../../dto/custom-http-response";
import { AuthenticationService } from 'src/app/service/authentication.service';
;
import {Router} from "@angular/router";
import {FileUploadStatus} from "../../model/file-upload.status";
import {Role} from "../../enum/role.enum";
@ -290,6 +292,20 @@ export class UserComponent implements OnInit, OnDestroy {
}
}
@ViewChild('addUserModal') addUserModal!: ElementRef;
openAddUserModal() {
console.log("clicked")
if (this.addUserModal) {
// const modalInstance = new Modal(this.addUserModal.nativeElement);
// modalInstance.show();
}
}
public get isAdmin(): boolean {
return this.loggedInUser.role === Role.ADMIN || this.loggedInUser.role === Role.SUPER_ADMIN;
}