New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Removing is_ticketing_enabled from event models #6634
Conversation
Codecov Report
@@ Coverage Diff @@
## development #6634 +/- ##
===============================================
- Coverage 65.34% 65.34% -0.01%
===============================================
Files 298 298
Lines 15242 15239 -3
===============================================
- Hits 9960 9958 -2
+ Misses 5282 5281 -1
Continue to review full report at Codecov.
|
Don't drop the column please, just remove the field from schema and logic for it |
@iamareebjamal Please have a look |
Fix dredd tests |
@iamareebjamal Why the |
Because modules are not added in the hooks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the PR really doing what it's supposed to do?
elif data.get('is_ticketing_enabled', True) and not modules.ticket_include: | ||
raise ForbiddenException({'source': '/data/attributes/is-ticketing-enabled'}, | ||
elif not modules.ticket_include: | ||
raise ForbiddenException({'source': ''}, | ||
"Ticketing is not enabled in the system") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"This event doesn't have any tickets"
Ticketing is not enables. Its corret error message
…On Fri, 29 Nov, 2019, 22:29 Saicharan Reddy, ***@***.***> wrote:
***@***.**** requested changes on this pull request.
Is the PR really doing what it's supposed to do?
------------------------------
In app/api/events.py
<#6634 (comment)>
:
> @@ -56,8 +56,8 @@ def validate_event(user, modules, data):
if not user.can_create_event():
raise ForbiddenException({'source': ''},
"Please verify your Email")
- elif data.get('is_ticketing_enabled', True) and not modules.ticket_include:
- raise ForbiddenException({'source': '/data/attributes/is-ticketing-enabled'},
+ elif not modules.ticket_include:
+ raise ForbiddenException({'source': ''},
"Ticketing is not enabled in the system")
"This event doesn't have any tickets"
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#6634?email_source=notifications&email_token=AKQMTLXIGRSOC7CK6EQAUR3QWFC7BA5CNFSM4JSZAFQ2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCNOCSKI#pullrequestreview-324806953>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKQMTLXFZNP26SG42FSCYMDQWFC7BANCNFSM4JSZAFQQ>
.
|
Okay. |
@iamareebjamal Please review and merge |
Refers fossasia/open-event-frontend#3664