Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/a165337421066728_create_accredit…
Browse files Browse the repository at this point in the history
…ations'
  • Loading branch information
kroman0 committed Nov 25, 2016
2 parents 960d318 + 984eb0b commit cb5ee8c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
}

setup(name='openprocurement.api',
version='2.3.36',
version='2.3.37',
description='openprocurement.api',
long_description=README,
classifiers=[
Expand Down
4 changes: 3 additions & 1 deletion src/openprocurement/api/validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ def validate_tender_data(request):
return

model = request.tender_from_data(data, create=False)
if not request.check_accreditation(model.create_accreditation):
#if not request.check_accreditation(model.create_accreditation):
#if not any([request.check_accreditation(acc) for acc in getattr(model, 'create_accreditations', [getattr(model, 'create_accreditation', '')])]):
if not any([request.check_accreditation(acc) for acc in iter(str(model.create_accreditation))]):
request.errors.add('procurementMethodType', 'accreditation', 'Broker Accreditation level does not permit tender creation')
request.errors.status = 403
return
Expand Down

0 comments on commit cb5ee8c

Please sign in to comment.