mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-24 00:42:17 +00:00
Make TrainingLevelRequirement the correct level of unique
Also updates generateSampleData to match
This commit is contained in:
@@ -147,6 +147,9 @@ class TrainingLevelRequirement(models.Model):
|
||||
def __str__(self):
|
||||
return "{} in {}".format(TrainingItemQualification.CHOICES[self.depth][1], self.item)
|
||||
|
||||
class Meta:
|
||||
unique_together = ["level", "item"]
|
||||
|
||||
|
||||
class TrainingLevelQualification(models.Model):
|
||||
trainee = models.ForeignKey('Trainee', related_name='levels', on_delete=models.RESTRICT)
|
||||
|
||||
Reference in New Issue
Block a user