feat: show membership by superior
This commit is contained in:
@@ -17,16 +17,23 @@ export class Membership {
|
||||
|
||||
this.data = response.body.data.map((item, idx) => {
|
||||
item.key = idx;
|
||||
item.roleName = item.roles.name;
|
||||
return item
|
||||
}) ?? []
|
||||
|
||||
this.total_data = response.body.total_data ?? 0
|
||||
}
|
||||
|
||||
async getDataBySuperior() {
|
||||
const response = await http.get(`/users/find-by-supperior?page=${this.page}&pageSize=${this.pageSize}`);
|
||||
this.data = response.body.data.map((item, idx) => {
|
||||
item.key = idx;
|
||||
item.roleName = item.roles.name;
|
||||
return item
|
||||
}) ?? []
|
||||
|
||||
this.total_data = response.body.total_data ?? 0
|
||||
}
|
||||
// async getData() {
|
||||
// const response = await http.get(`/users/find-by-supperior?page=${this.page}&pageSize=${this.pageSize}`);
|
||||
// this.data = response.body.data ?? []
|
||||
// this.total_data = response.body.total_data ?? 0
|
||||
// }
|
||||
|
||||
async create(data) {
|
||||
return await http.post('/users').send(data)
|
||||
|
||||
Reference in New Issue
Block a user