OpenSlides/client/src/app/core/models/group.ts

30 lines
630 B
TypeScript
Raw Normal View History

2018-06-30 16:56:18 +02:00
import { BaseModel } from './baseModel';
export class Group extends BaseModel {
id: number;
name: string;
permissions: string[];
constructor(id: number) {
super();
this.id = id;
}
static getCollectionString(): string {
return 'users/group';
}
static get(id: number): Group | undefined {
return this._get<Group>(id);
}
static getAll(): Group[] {
return this._getAll<Group>();
}
static filter(callback): Group[] {
return this._filter<Group>(callback);
}
getCollectionString(): string {
return 'users/group';
}
}