How to calculate the price after discount
In order management, it is often necessary to carry out some promotional activities for products, such as full discount and full discount.
How can these activities be implemented through YIDA? Very simple, through YIDAFormula 」Easy to solve!
1. Create a form
(1) Product Information Table 」
First, we create a product information table, which includes fields such as product code, product classification, product name, specification model, unit price, and unit price. Then enter the basic information of the product into the database for subsequent data calls.
(2) Order table 」
The order table includes the basic information and order details of the next person.
2. Discount calculation
If the rules of this discount activity are, no discount will be given if the price is less than 1,000 yuan, 10% off if the price is less than 1,000 yuan, 20% off if the price is less than 2,000 yuan, and 30% off if the price is less than 3,000 yuan.
Then add two numeric fields, one to calculate the discount rate and the other to calculate the discounted price.
3. Effect demonstration
Finally, let's look at the effect of the discount:
YIDA in order to better optimize the content and quality of YIDA user manual, it takes you 3-5 minutes to fill in the document feedback questionnaire. The document feedback questionnaire is submitted anonymously, and the questionnaire information is only used for YIDA document experience feedback collection. Thank you for your support for YIDA!
-------------------- Get the latest information YIDA, welcome to follow US--------------------