Add book deletion feature with admin permission control
This commit is contained in:
committed by
Aditya Chandel
parent
6f032153b8
commit
ce96fcff6d
@@ -21,6 +21,7 @@
|
||||
<th style="width: 80px;">Edit Metadata</th>
|
||||
<th style="width: 80px;">Manage Library</th>
|
||||
<th style="width: 80px;">Email Books</th>
|
||||
<th style="width: 80px;">Delete Books</th>
|
||||
<th style="width: 120px;">Edit</th>
|
||||
<th style="width: 80px;">Change Password</th>
|
||||
<th style="width: 80px;">Delete</th>
|
||||
@@ -114,6 +115,14 @@
|
||||
<p-checkbox [binary]="true" [(ngModel)]="user.permissions.canEmailBook" disabled></p-checkbox>
|
||||
}
|
||||
</td>
|
||||
<td class="text-center">
|
||||
@if (user.isEditing) {
|
||||
<p-checkbox [binary]="true" [(ngModel)]="user.permissions.canDeleteBook"></p-checkbox>
|
||||
}
|
||||
@if (!user.isEditing) {
|
||||
<p-checkbox [binary]="true" [(ngModel)]="user.permissions.canDeleteBook" disabled></p-checkbox>
|
||||
}
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<ng-container>
|
||||
@if (!user.isEditing) {
|
||||
|
||||
@@ -90,6 +90,7 @@ export interface User {
|
||||
canUpload: boolean;
|
||||
canDownload: boolean;
|
||||
canEmailBook: boolean;
|
||||
canDeleteBook: boolean;
|
||||
canEditMetadata: boolean;
|
||||
canManipulateLibrary: boolean;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user