course creation
This commit is contained in:
@@ -79,7 +79,7 @@ export class UsersPage {
|
||||
constructor(private api: UserService, private roleService: RoleService) {
|
||||
this.roleService
|
||||
.list({ page: 1, perPage: 100, search: '', sortKey: 'name', sortDir: 'asc' } as any)
|
||||
.subscribe((res) => (res.data as Role[]).forEach((r) => this.roleMap.set(r.id, r.name)));
|
||||
.subscribe((res) => (res.content as Role[]).forEach((r) => this.roleMap.set(r.id, r.name)));
|
||||
effect(() => {
|
||||
const params = {
|
||||
page: this.page(),
|
||||
@@ -102,8 +102,8 @@ export class UsersPage {
|
||||
this.loading.set(true);
|
||||
this.api.list(params).subscribe({
|
||||
next: (res) => {
|
||||
this.rows.set(res.data);
|
||||
this.total.set(res.meta.total);
|
||||
this.rows.set(res.content);
|
||||
this.total.set(res.pageable.total);
|
||||
this.loading.set(false);
|
||||
},
|
||||
error: () => {
|
||||
|
||||
Reference in New Issue
Block a user