This repository was archived by the owner on Mar 25, 2025. It is now read-only.
Danial/eds 228 geographic discount - #306
Merged
Merged
Conversation
|
Hello @danialmalik! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found: There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2020-02-26 08:31:37 UTC |
danialmalik
force-pushed
the
danial/EDS-228-geographic-discount
branch
from
February 25, 2020 06:46
0f77ee3 to
aa56471
Compare
There was a problem hiding this comment.
Suggested change
| if not settings.FEATURES['ENABLE_GEOGRAPHIC_DISCOUNTS']: | |
| if not settings.FEATURES.get('ENABLE_GEOGRAPHIC_DISCOUNTS'): |
Author
There was a problem hiding this comment.
not necessarily required as I am providing a default value in config but let's change it anyways to be on safe side
There was a problem hiding this comment.
Suggested change
| is_request_for_voucher_sent, message = ecommerce_client.assing_voucher_to_user( | |
| is_request_for_voucher_sent, message = ecommerce_client.assign_voucher_to_user( |
?
There was a problem hiding this comment.
Suggested change
| is_request_for_voucher_sent, message = ecommerce_client.assing_voucher_to_user( | |
| is_voucher_assigned, message = ecommerce_client.assing_voucher_to_user( |
There was a problem hiding this comment.
I think it would be better if we create a variable like self.user = user instead of passing it in functions
Author
There was a problem hiding this comment.
Yes otherwise the default value will be overwritten
danialmalik
force-pushed
the
danial/EDS-228-geographic-discount
branch
2 times, most recently
from
February 26, 2020 08:24
099c1f2 to
7e03fac
Compare
danialmalik
force-pushed
the
danial/EDS-228-geographic-discount
branch
from
February 26, 2020 08:31
7e03fac to
c5c6b89
Compare
danialmalik
marked this pull request as ready for review
February 26, 2020 08:32
HamzaIbnFarooq
approved these changes
Feb 26, 2020
mumarkhan999
approved these changes
Feb 26, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Story Link
Geographic Location Discount
PR Description
When a user enrolls in a course, check if the course has a verified mode and user's country is in the list of eligible countries for discount. If yes, then create a coupon and send him the voucher.
Type of change
Please select the options that are relevant.
Checklist before merging: