gumroad icon indicating copy to clipboard operation
gumroad copied to clipboard

Add feature to automatically apply discount code to the product

Open ershad opened this issue 1 month ago • 4 comments

Design

When no discount code is applied:

Image

When the radio is selected:

Image

When discount code is selected:

Image
  • [ ] When a product has an auto-applied discount code, show the discounted price everywhere:
    • Preview on product edit page
    • Discover
    • Seller profile
    • Product page

Discounted price should look similar to how it looks now when we apply a discount code through &code=<discount_code> query string:

Image

If the buyer has supplied another discount code (through the URL), prioritize that over the product's default discount code.

  • [ ] Track purchases made using the default discount code (can use attr_json_data_accessor on Purchase object)

ershad avatar Nov 17 '25 22:11 ershad

Hello !

I have a deep passion for being a part of this feature. I have reviewed the issue, as well as the conversation; and, I'm looking forward to working on this auto apply discount system with you.

I will be building a simple validation layer to verify eligibility rules on the client side and / or server side (depending on the design of the application) before the discount is automatically applied, once the eligibility conditions have been met. Also, I will build the logic in a way that allows for future enhancement with additional discount types.

While I am still getting to know the code base; however, I will complete this task and will be very thankful for any help or guidance that you may have. I'll also submit a PR with my proposed method to begin implementation once I have completed my plan.

Please let me know if there are any specific topics of interest or concern that you would like me to cover at this time.

Thanks, and I look forward to collaborating with you!

thakkerpankti837-tech avatar Nov 28 '25 16:11 thakkerpankti837-tech