Hello Community,

Just to add, I've created OFBIZ-13269
<https://issues.apache.org/jira/browse/OFBIZ-13269> for the requirement
scenario addressed above so that further discussions or process
enhancements could be taken care of there.

Thanks & Regards,
Ankit Joshi

On Mon, Jun 2, 2025 at 8:42 PM Ankit Joshi <[email protected]>
wrote:

> Thanks Gil for your thoughts and sharing good use-case scenarios with
> questions around this.
>
> To elaborate the requirement and intent behind maxDiscountAmount, the
> primary aim is not to enforce a minimum margin rule for the product price
> but to set a maximum discount limit regardless of the cart total
> particularly for the high valued cart totals.
>
> In regards to multiple promotion scenarios you shared, it could be
> designed/handled in 2 ways:
>
> #1 promotion level max discount cap -> If two promotions are applied,
> individual promotion will apply based on their max discount cap configured.
>
> #2 Global Cart level max discount cap ->  Sum of discounted amount from
> all the applied promotions could not exceed the maximum cap.
>
> Looking forward to further insights on it !!
>
> Thanks,
> Ankit Joshi
>
> On Mon, Jun 2, 2025 at 2:27 PM gil.portenseigne <
> [email protected]> wrote:
>
>> Hello Ankit, just giving some food for thought
>>
>> In case of multiple promo application, how do you envision the
>> maxDiscountAmount configuration in both options ?
>>
>> Do this kind of limitation is to avoid a promotion instance to not
>> lower the price below a threshold ? Or the need is to ensure that the
>> product would not be sold below `production price + minimum marging`
>> regardless of promotions applied ?
>>
>> Gil
>>
>>
>> On 30/05/25 03:05, Ankit Joshi wrote:
>> > Thanks Chandan and Devanshu for your input on this.
>> >
>> > Extending the ProductPromoAction entity with maxDiscountAmount field
>> could
>> > be a standard and straight-forward enhancement.
>> >
>> > Just as an alternative option, a separate ProductPromoAction record
>> with a
>> > new productPromoActionEnumId (say 'PROMO_MAX_DISCOUNT') could be created
>> > (along with existing PROMO_ORDER_PERCENT record) that will help
>> > promotion engine to validate/compare the calculated promotional
>> percentage
>> > discount with maxDiscount limit and override the final discounted
>> amount as
>> > needed.
>> >
>> > Any additional insights to conclude the approach from the above two
>> options
>> > would be appreciated.
>> >
>> > Thanks & Regards,
>> > Ankit Joshi
>> >
>> > HotWax Systems
>> >
>> > On Tue, May 27, 2025 at 12:13 PM Devanshu Vyas <
>> [email protected]>
>> > wrote:
>> >
>> > > Hello Ankit,
>> > >
>> > > I agree with the need to have this enhancement in the current
>> promotion
>> > > engine of Apache OFBiz.
>> > >
>> > > And yes, Chandan's suggestion looks good to start with. Once we have a
>> > > working solution on this, we can discuss if this needs some tweaking
>> to
>> > > support multiple scenarios.
>> > >
>> > >
>> > > Thanks & Regards,
>> > > Devanshu Vyas
>> > >
>> > >
>> > > On Fri, May 23, 2025 at 4:14 PM Chandan Khandelwal <
>> > > [email protected]> wrote:
>> > >
>> > > > Hello Ankit,
>> > > >
>> > > > This is a very common and practical use case. Adding a *maximum
>> discount
>> > > > cap* to *Cart Range Percent Discount* would be a valuable
>> enhancement and
>> > > > aligns with standard business needs.
>> > > >
>> > > > As an initial thought, extending or leveraging the existing
>> > > > ProductPromoAction (e.g., adding maxDiscountAmount) and related
>> support
>> > > in
>> > > > the promotion engine seems like a possible approach.
>> > > > Kind Regards,
>> > > > Chandan Khandelwal
>> > > >
>> > > >
>> > > >
>> > > > On Mon, May 19, 2025 at 4:51 PM Ankit Joshi <
>> > > [email protected]
>> > > > >
>> > > > wrote:
>> > > >
>> > > > > Hello Community,
>> > > > >
>> > > > > I wanted to bring up a use-case scenario that I am implementing,
>> which
>> > > is
>> > > > > identified oftenly while working with a few clients.  It seems to
>> be a
>> > > > > generic use case and good to address as a possible support in
>> OFBiz
>> > > > > promotion engine:
>> > > > >
>> > > > > In the current OFBiz setup, when configuring a *Cart Range Percent
>> > > > > Discount*
>> > > > > for promotions, there doesn’t seem to be an out-of-the-box option
>> to
>> > > > > set a *maximum
>> > > > > discount cap*. For instance, if the business wants to offer a *15%
>> > > > > discount*
>> > > > > on the cart total, but with a *maximum discount limit of $100*,
>> the
>> > > > system
>> > > > > currently applies the percentage across the total cart value
>> without a
>> > > > > ceiling.
>> > > > >
>> > > > > This kind of feature is quite common in promotions where
>> businesses
>> > > want
>> > > > to
>> > > > > incentivize larger purchases with a discount but also want to
>> control
>> > > the
>> > > > > maximum discount exposure.
>> > > > >
>> > > > > I am curious if anyone has encountered this requirement before
>> and if
>> > > > there
>> > > > > are any existing implementations or customizations that could
>> address
>> > > it.
>> > > > > Alternatively, it would be great to discuss potential ways to
>> extend
>> > > the
>> > > > > current promotion engine to support this use case.
>> > > > >
>> > > > > Looking forward to your valuable inputs!
>> > > > > Thanks & Regards,
>> > > > > Ankit Joshi
>> > > > >
>> > > > > *HotWax Systems*
>> > > > > *Enterprise open-source experts*
>> > > > > http://www.hotwaxsystems.com
>> > > > >
>> > > >
>> > >
>>
>
> On Mon, Jun 2, 2025 at 2:27 PM gil.portenseigne <
> [email protected]> wrote:
>
>> Hello Ankit, just giving some food for thought
>>
>> In case of multiple promo application, how do you envision the
>> maxDiscountAmount configuration in both options ?
>>
>> Do this kind of limitation is to avoid a promotion instance to not
>> lower the price below a threshold ? Or the need is to ensure that the
>> product would not be sold below `production price + minimum marging`
>> regardless of promotions applied ?
>>
>> Gil
>>
>>
>> On 30/05/25 03:05, Ankit Joshi wrote:
>> > Thanks Chandan and Devanshu for your input on this.
>> >
>> > Extending the ProductPromoAction entity with maxDiscountAmount field
>> could
>> > be a standard and straight-forward enhancement.
>> >
>> > Just as an alternative option, a separate ProductPromoAction record
>> with a
>> > new productPromoActionEnumId (say 'PROMO_MAX_DISCOUNT') could be created
>> > (along with existing PROMO_ORDER_PERCENT record) that will help
>> > promotion engine to validate/compare the calculated promotional
>> percentage
>> > discount with maxDiscount limit and override the final discounted
>> amount as
>> > needed.
>> >
>> > Any additional insights to conclude the approach from the above two
>> options
>> > would be appreciated.
>> >
>> > Thanks & Regards,
>> > Ankit Joshi
>> >
>> > HotWax Systems
>> >
>> > On Tue, May 27, 2025 at 12:13 PM Devanshu Vyas <
>> [email protected]>
>> > wrote:
>> >
>> > > Hello Ankit,
>> > >
>> > > I agree with the need to have this enhancement in the current
>> promotion
>> > > engine of Apache OFBiz.
>> > >
>> > > And yes, Chandan's suggestion looks good to start with. Once we have a
>> > > working solution on this, we can discuss if this needs some tweaking
>> to
>> > > support multiple scenarios.
>> > >
>> > >
>> > > Thanks & Regards,
>> > > Devanshu Vyas
>> > >
>> > >
>> > > On Fri, May 23, 2025 at 4:14 PM Chandan Khandelwal <
>> > > [email protected]> wrote:
>> > >
>> > > > Hello Ankit,
>> > > >
>> > > > This is a very common and practical use case. Adding a *maximum
>> discount
>> > > > cap* to *Cart Range Percent Discount* would be a valuable
>> enhancement and
>> > > > aligns with standard business needs.
>> > > >
>> > > > As an initial thought, extending or leveraging the existing
>> > > > ProductPromoAction (e.g., adding maxDiscountAmount) and related
>> support
>> > > in
>> > > > the promotion engine seems like a possible approach.
>> > > > Kind Regards,
>> > > > Chandan Khandelwal
>> > > >
>> > > >
>> > > >
>> > > > On Mon, May 19, 2025 at 4:51 PM Ankit Joshi <
>> > > [email protected]
>> > > > >
>> > > > wrote:
>> > > >
>> > > > > Hello Community,
>> > > > >
>> > > > > I wanted to bring up a use-case scenario that I am implementing,
>> which
>> > > is
>> > > > > identified oftenly while working with a few clients.  It seems to
>> be a
>> > > > > generic use case and good to address as a possible support in
>> OFBiz
>> > > > > promotion engine:
>> > > > >
>> > > > > In the current OFBiz setup, when configuring a *Cart Range Percent
>> > > > > Discount*
>> > > > > for promotions, there doesn’t seem to be an out-of-the-box option
>> to
>> > > > > set a *maximum
>> > > > > discount cap*. For instance, if the business wants to offer a *15%
>> > > > > discount*
>> > > > > on the cart total, but with a *maximum discount limit of $100*,
>> the
>> > > > system
>> > > > > currently applies the percentage across the total cart value
>> without a
>> > > > > ceiling.
>> > > > >
>> > > > > This kind of feature is quite common in promotions where
>> businesses
>> > > want
>> > > > to
>> > > > > incentivize larger purchases with a discount but also want to
>> control
>> > > the
>> > > > > maximum discount exposure.
>> > > > >
>> > > > > I am curious if anyone has encountered this requirement before
>> and if
>> > > > there
>> > > > > are any existing implementations or customizations that could
>> address
>> > > it.
>> > > > > Alternatively, it would be great to discuss potential ways to
>> extend
>> > > the
>> > > > > current promotion engine to support this use case.
>> > > > >
>> > > > > Looking forward to your valuable inputs!
>> > > > > Thanks & Regards,
>> > > > > Ankit Joshi
>> > > > >
>> > > > > *HotWax Systems*
>> > > > > *Enterprise open-source experts*
>> > > > > http://www.hotwaxsystems.com
>> > > > >
>> > > >
>> > >
>>
>

Reply via email to