Announcement

Collapse
No announcement yet.

Is it possible to modify the formula for calculating standard fields ?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Is it possible to modify the formula for calculating standard fields ?


    Hello, I use the API to send the quote information to espo, I noticed that the field discountAmount does not take the value that I send by the API but it is always calculated from the sums of the discount of the quoteItem. While in my case I have overall discounts that do not apply on the quoteItem but directly on the quotes. So I thought to add a new globalDiscount field in which I send the global discount info, it works well except that the total amount of quotes does not take into account my new field and I do not have the opportunity to changed the grandTotalAmount calculation formula Is it possible to modify the formula for calculating standard fields?

  • #2
    Hello,
    here you can find, how to override server-side calculation

    Comment


    • #3
      Thanks tanya

      Comment


      • #4
        Hi,

        Just for information, the path of the class \ Espo \ Modules \ Advanced \ Repositories \ Quote is not good I find the class rather under \ Espo \ Modules \ Sales \ Repositories \ Quote
        I have the Advanced module installed and Espo version: 5.5.6
        Thanks

        Comment


        • #5
          It's known cache issue. See: https://forum.espocrm.com/forum/exte...age4#post45103

          Comment


          • #6

            Sorry but I did not understand! must I have the class quote.php In \ Espo \ Modules \ Sales \ Repositories \ Quote But not in \ Espo \ Modules \ Advanced \ Repositories \ Quote is a problem?

            Comment


            • #7
              Change change the path. It's old documentation.

              Comment


              • #8
                thanks

                Comment

                Working...
                X