style: fix linting issues met Prettier
This commit is contained in:
parent
e78849f568
commit
400a955850
40 changed files with 321 additions and 700 deletions
|
@ -4,10 +4,7 @@ import { Assignment } from '../../entities/assignments/assignment.entity.js';
|
|||
import { Student } from '../../entities/users/student.entity.js';
|
||||
|
||||
export class GroupRepository extends DwengoEntityRepository<Group> {
|
||||
public findByAssignmentAndGroupNumber(
|
||||
assignment: Assignment,
|
||||
groupNumber: number
|
||||
): Promise<Group | null> {
|
||||
public findByAssignmentAndGroupNumber(assignment: Assignment, groupNumber: number): Promise<Group | null> {
|
||||
return this.findOne(
|
||||
{
|
||||
assignment: assignment,
|
||||
|
@ -16,26 +13,16 @@ export class GroupRepository extends DwengoEntityRepository<Group> {
|
|||
{ populate: ['members'] }
|
||||
);
|
||||
}
|
||||
public findAllGroupsForAssignment(
|
||||
assignment: Assignment
|
||||
): Promise<Group[]> {
|
||||
public findAllGroupsForAssignment(assignment: Assignment): Promise<Group[]> {
|
||||
return this.findAll({
|
||||
where: { assignment: assignment },
|
||||
populate: ['members'],
|
||||
});
|
||||
}
|
||||
public findAllGroupsWithStudent(
|
||||
student: Student
|
||||
): Promise<Group[]> {
|
||||
return this.find(
|
||||
{ members: student },
|
||||
{ populate: ['members'] }
|
||||
)
|
||||
public findAllGroupsWithStudent(student: Student): Promise<Group[]> {
|
||||
return this.find({ members: student }, { populate: ['members'] });
|
||||
}
|
||||
public deleteByAssignmentAndGroupNumber(
|
||||
assignment: Assignment,
|
||||
groupNumber: number
|
||||
) {
|
||||
public deleteByAssignmentAndGroupNumber(assignment: Assignment, groupNumber: number) {
|
||||
return this.deleteWhere({
|
||||
assignment: assignment,
|
||||
groupNumber: groupNumber,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue