Skip to content

Commit

Permalink
Merge pull request #282 from FJNR-inc/develop
Browse files Browse the repository at this point in the history
New release
  • Loading branch information
RignonNoel authored Nov 26, 2019
2 parents 9e11319 + 13bf48b commit e99e506
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 11 deletions.
6 changes: 3 additions & 3 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
pycodestyle==2.5.0
coveralls==1.8.2
responses==0.10.6
six==1.12.0
awscli==1.16.279
responses==0.10.7
awscli==1.16.286
six==1.13.0
8 changes: 4 additions & 4 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Django==2.2.7
djangorestframework==3.10.3
django-cors-headers==3.1.1
django-cors-headers==3.2.0
django-filter==2.2.0
coreapi==2.3.3
factory-boy==2.12.0
Expand All @@ -10,8 +10,8 @@ django-anymail==6.1.0
Pillow==6.2.1
django-simple-history==2.7.3
djangorestframework-filters==0.11.1
python-decouple==3.1
django-storages==1.7.2
python-decouple==3.3
django-storages==1.8
dj_database_url==0.5.0
zappa==0.48.2
psycopg2-binary==2.8.4
Expand All @@ -21,5 +21,5 @@ django-safedelete==0.5.2
django-import-export==1.2.0
jsonfield==2.0.2
django-model-utils==3.2.0
tqdm==4.38.0
tqdm==4.39.0
colorama==0.4.1
10 changes: 7 additions & 3 deletions retirement/resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@


# django-import-export models declaration
# These represent the models data that will be importd/exported
# These represent the models data that will be imported/exported
class ReservationResource(resources.ModelResource):

user = fields.Field(
Expand Down Expand Up @@ -250,7 +250,9 @@ class Meta:
'promo_code',
'personnal_restrictions',
'city',
'phone'
'phone',
'is_active',
'is_present'
)
export_order = (
'last_name',
Expand All @@ -261,7 +263,9 @@ class Meta:
'promo_code',
'personnal_restrictions',
'city',
'phone'
'phone',
'is_active',
'is_present'
)


Expand Down
3 changes: 2 additions & 1 deletion store/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,8 @@ def create(self, validated_data):
timeslot = reservation_orderline.content_object
reservations = timeslot.reservations.filter(is_active=True)
reserved = reservations.count()
if timeslot.billing_price > user.tickets:
if not bypass_payment and timeslot.billing_price > \
user.tickets:
raise serializers.ValidationError({
'non_field_errors': [_(
"You don't have enough tickets to make this "
Expand Down

0 comments on commit e99e506

Please sign in to comment.