diff --git a/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.html b/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.html
index a08c8a10..345fa10d 100644
--- a/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.html
+++ b/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.html
@@ -14,41 +14,13 @@
- ID |
- Entity Type Id |
- Entity Object Id |
- Assigned Role |
- User |
- |
+ ID |
+ Entity Type Id |
+ Entity Object Id |
+ Assigned Role |
+ User |
+ |
-
-
-
- |
- |
- |
-
-
- |
-
-
- |
- |
-
-
-
= links['last']" [infiniteScrollDistance]="0">
diff --git a/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.ts b/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.ts
index 9aedd523..822109d8 100644
--- a/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.ts
+++ b/src/main/webapp/app/entities/user-role-assignment/user-role-assignment.component.ts
@@ -9,9 +9,6 @@ import { AccountService } from 'app/core';
import { ITEMS_PER_PAGE } from 'app/shared';
import { UserRoleAssignmentService } from './user-role-assignment.service';
-import { IUser } from 'app/core/user/user.model';
-import { UserService } from 'app/core/user/user.service';
-import { TableFilter, queryEquals, queryContains } from 'app/shared/util/tablefilter';
@Component({
selector: 'jhi-user-role-assignment',
@@ -27,17 +24,9 @@ export class UserRoleAssignmentComponent implements OnInit, OnDestroy {
predicate: any;
reverse: any;
totalItems: number;
- users: IUser[];
- filter: TableFilter<{
- entityTypeId?: string;
- entityObjectId?: string;
- assignedRole?: string;
- userId?: string;
- }>;
constructor(
protected userRoleAssignmentService: UserRoleAssignmentService,
- protected userService: UserService,
protected jhiAlertService: JhiAlertService,
protected eventManager: JhiEventManager,
protected parseLinks: JhiParseLinks,
@@ -51,24 +40,11 @@ export class UserRoleAssignmentComponent implements OnInit, OnDestroy {
};
this.predicate = 'id';
this.reverse = true;
- this.filter = new TableFilter(
- {
- entityTypeId: queryContains,
- entityObjectId: queryEquals,
- assignedRole: queryEquals,
- userId: queryEquals
- },
- 500,
- () => {
- this.loadAll();
- }
- );
}
loadAll() {
this.userRoleAssignmentService
.query({
- ...this.filter.buildQueryCriteria(),
page: this.page,
size: this.itemsPerPage,
sort: this.sort()
@@ -95,13 +71,6 @@ export class UserRoleAssignmentComponent implements OnInit, OnDestroy {
this.accountService.identity().then(account => {
this.currentAccount = account;
});
- this.userService
- .query()
- .pipe(
- filter((mayBeOk: HttpResponse) => mayBeOk.ok),
- map((response: HttpResponse) => response.body)
- )
- .subscribe((res: IUser[]) => (this.users = res), (res: HttpErrorResponse) => this.onError(res.message));
this.registerChangeInUserRoleAssignments();
}
@@ -109,7 +78,7 @@ export class UserRoleAssignmentComponent implements OnInit, OnDestroy {
this.eventManager.destroy(this.eventSubscriber);
}
- trackId(index: number, item: { id: number }) {
+ trackId(index: number, item: IUserRoleAssignment) {
return item.id;
}
@@ -128,7 +97,6 @@ export class UserRoleAssignmentComponent implements OnInit, OnDestroy {
protected paginateUserRoleAssignments(data: IUserRoleAssignment[], headers: HttpHeaders) {
this.links = this.parseLinks.parse(headers.get('link'));
this.totalItems = parseInt(headers.get('X-Total-Count'), 10);
- this.userRoleAssignments = [];
for (let i = 0; i < data.length; i++) {
this.userRoleAssignments.push(data[i]);
}