patriciaperez90/restaurant-ordering-system
View on GitHubEnatega Admin Dashboard: When adding a Coupon, Discount field is allowing to enter more than 100%
Open
#102 opened on Feb 20, 2025
Enatega MultiVendor Admin DashboardHigh prioritybuggood first issue
Repository metrics
- Stars
- (1 star)
- PR merge metrics
- (PR metrics pending)
Description
Describe the bug When adding a coupon, the Discount field allows users to enter a value greater than 100%, which is invalid. This could lead to incorrect calculations and potential financial losses or Also display an error message that discount percentage should not exceed 100%.
To Reproduce Steps to reproduce the behavior:
- Navigate to the Coupon Management section.
- Click on Add New Coupon.
- Enter a discount value greater than 100% (e.g., 150%).
- Save the coupon, it will not save it so it should display an error message or restrict it to not enter amount greater than 100%.
Expected behavior The system should restrict the Discount field to a maximum of 100% and display a validation error if a higher value is entered.
Desktop (please complete the following information):
- OS: [e.g. Windows]
- Browser [e.g. Chrome]
- Version [e.g. Latest]