Dear Sugar Community,
I have a question relating to quoted line items. We have the need to add an additional field to the quoted line item, this field will be known as a “term”, i.e. a term of 1 year 1.5 years 2 years etc.
I need the “term” value to also be used within the calculations of the quoted line item totals.
I can see that there are several calculated value fields within the QLIs. i.e.
- Discount Total
- Subtotal
- Line Item Total
These calculated values all use the Quantity field within their calculation.
My first thought was to change each calculation formula to include the term within the calculation, i.e. the $term_c would become a new factor in the formula.
Another option would be to create a new calculated field being a new quantity field, i.e.
multiply($quantity, $term_c)
Then use this in the calculations listed above.
I’m attempting both approaches, however when I edit the formula, I can not save it as I receive this error.
Unknown field: discount_amount
However, this field exists in my QLIs, as you can see.
- Has anyone experienced this issue?
- Is there a work around, for example, can I edit the vardef.php for Products, to change the “Formula” to include my new “quantity” field in the calculation?
- Or does anyone have an alternate suggestion?
Many thanks for any assistance.
Sugar version details:
- SugarCRM Version 11.0.0 (Build 238 P) (Q2 2021)
- Professional
- On-Premise