Add Woodworking-2 and CNC tool certification
This commit is contained in:
@@ -51,6 +51,8 @@ class Member(models.Model):
|
||||
lathe_cert_date = models.DateField(blank=True, null=True, default=None)
|
||||
mill_cert_date = models.DateField(blank=True, null=True, default=None)
|
||||
wood_cert_date = models.DateField(blank=True, null=True, default=None)
|
||||
wood2_cert_date = models.DateField(blank=True, null=True, default=None)
|
||||
cnc_cert_date = models.DateField(blank=True, null=True, default=None)
|
||||
paused_date = models.DateField(blank=True, null=True)
|
||||
monthly_fees = models.IntegerField(default=55, blank=True, null=True)
|
||||
|
||||
|
@@ -142,6 +142,8 @@ class MemberSerializer(serializers.ModelSerializer):
|
||||
'lathe_cert_date',
|
||||
'mill_cert_date',
|
||||
'wood_cert_date',
|
||||
'wood2_cert_date',
|
||||
'cnc_cert_date',
|
||||
]
|
||||
|
||||
def get_status(self, obj):
|
||||
|
@@ -376,10 +376,14 @@ class LockoutViewSet(viewsets.ViewSet, List):
|
||||
if member.paused_date: continue
|
||||
|
||||
authorization = {}
|
||||
authorization['id'] = member.id
|
||||
authorization['name'] = member.first_name + " " + member.last_name
|
||||
authorization['common'] = bool(member.orientation_date or member.vetted_date)
|
||||
authorization['lathe'] = bool(member.lathe_cert_date)
|
||||
authorization['mill'] = bool(member.mill_cert_date)
|
||||
authorization['wood'] = bool(member.wood_cert_date)
|
||||
authorization['wood2'] = bool(member.wood2_cert_date)
|
||||
authorization['cnc'] = bool(member.cnc_cert_date)
|
||||
|
||||
active_member_cards[card.card_number] = authorization
|
||||
|
||||
|
Reference in New Issue
Block a user