Skip to content

Commit

Permalink
fix: removed relationship fields in entities
Browse files Browse the repository at this point in the history
  • Loading branch information
markdeluk authored and AlbertoBaroso committed Apr 9, 2024
1 parent 1c2c652 commit f39f041
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
4 changes: 2 additions & 2 deletions api/src/availability/availability.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ export class Availability implements AvailabilityInterface {
@Column({ name: 'last_modified' })
lastModified: Date;
@Column({ name: 'time_slot' })
@ManyToOne(() => TimeSlot, (timeSlot) => timeSlot.availabilities)
@ManyToOne(() => TimeSlot)
timeSlot: TimeSlot;
@ManyToOne(() => User, (user) => user.availabilities)
@ManyToOne(() => User)
@JoinColumn()
user: User;
}
3 changes: 0 additions & 3 deletions api/src/timeslots/timeslot.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,4 @@ export class TimeSlot implements TimeSlotInterface {

@Column()
end: Date;

@OneToMany(() => Availability, (availability) => availability.timeSlot)
availabilities: Availability[];
}
3 changes: 0 additions & 3 deletions api/src/users/user.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,4 @@ export class User implements Person {

@Column()
role: Role;

@OneToMany(() => Availability, (availability) => availability.user)
availabilities: Availability[];
}

0 comments on commit f39f041

Please sign in to comment.