'Exception' with message 'Quote totals must be collected before this operation.'PayPalPro - AdvancedWhat...

Why don't key signatures indicate the tonic?

What game did these black and yellow dice come from?

Can you tell from a blurry photo if focus was too close or too far?

Changing the laptop's CPU. Should I reinstall Linux?

Can 5 Aarakocra PCs summon an Air Elemental?

Current across a wire with zero potential difference

Does diversity provide anything that meritocracy does not?

Cat is tipping over bed-side lamps during the night

How does one write from a minority culture? A question on cultural references

Separate environment for personal and development use under macOS

Can I announce prefix 161.117.25.0/24 even though I don't have all of /24 IPs

A Missing Symbol for This Logo

How to deal with possible delayed baggage?

How does Leonard in "Memento" remember reading and writing?

Airplane generations - how does it work?

Looking for a specific 6502 Assembler

How to politely refuse in-office gym instructor for steroids and protein

How to assess the long-term stability of a college as part of a job search

Citing paid articles from illegal web sharing

Has any human ever had the choice to leave Earth permanently?

Why did Democrats in the Senate oppose the Born-Alive Abortion Survivors Protection Act?

Does it take energy to move something in a circle?

Macro expansion inside href

How do you voice extended chords?



'Exception' with message 'Quote totals must be collected before this operation.'


PayPalPro - AdvancedWhat could cause error related to “dashboard/tunnel/key”Error in admin panel: MySQL server has gone awayM1 CE, paypal exception “PayPal NVP gateway errors”Fedex - Shipping label not generated if extra street address field is added in billing/shippingSQLSTATE[HY000] : General error: 2013 Lost connection to MySQL server during query in MagentoCheckout redirecting to the cart pageError while saving product in admin panelMagento 1.9 - Invalid block type error in exception logProduct price not displaying when I add to cart













0















I have create a programmatically order and set programmatically discount amount but i have getting error when submit order.
Here is exception message :



DEBUG (7): ====ex==exception 'Exception' with message 'Quote totals must be collected before this operation.' in /home/xyz/public_html/testing/app/code/core/Mage/Sales/Model/Quote.php:1861
Stack trace:
#0 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(326): Mage_Sales_Model_Quote->prepareRecurringPaymentProfiles()
#1 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(223): Mage_Sales_Model_Service_Quote->_submitRecurringPaymentProfiles()
#2 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(238): Mage_Sales_Model_Service_Quote->submitNominalItems()
#3 /home/xyz/public_html/testing/app/code/local/Assel/StoreOwners/controllers/SalesorderController.php(364): Mage_Sales_Model_Service_Quote->submitAll()
#4 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Assel_StoreOwners_SalesorderController->submitOrderAction()
#5 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('submitOrder')
#6 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#7 /home/xyz/public_html/testing/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
#8 /home/xyz/public_html/testing/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#9 /home/xyz/public_html/testing/sellertesting.xyz.com/index.php(385): Mage::run('sellerwebsite', 'website')
#10 {main}


Please can anyone suggest me.










share|improve this question














bumped to the homepage by Community 3 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.




















    0















    I have create a programmatically order and set programmatically discount amount but i have getting error when submit order.
    Here is exception message :



    DEBUG (7): ====ex==exception 'Exception' with message 'Quote totals must be collected before this operation.' in /home/xyz/public_html/testing/app/code/core/Mage/Sales/Model/Quote.php:1861
    Stack trace:
    #0 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(326): Mage_Sales_Model_Quote->prepareRecurringPaymentProfiles()
    #1 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(223): Mage_Sales_Model_Service_Quote->_submitRecurringPaymentProfiles()
    #2 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(238): Mage_Sales_Model_Service_Quote->submitNominalItems()
    #3 /home/xyz/public_html/testing/app/code/local/Assel/StoreOwners/controllers/SalesorderController.php(364): Mage_Sales_Model_Service_Quote->submitAll()
    #4 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Assel_StoreOwners_SalesorderController->submitOrderAction()
    #5 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('submitOrder')
    #6 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
    #7 /home/xyz/public_html/testing/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
    #8 /home/xyz/public_html/testing/app/Mage.php(684): Mage_Core_Model_App->run(Array)
    #9 /home/xyz/public_html/testing/sellertesting.xyz.com/index.php(385): Mage::run('sellerwebsite', 'website')
    #10 {main}


    Please can anyone suggest me.










    share|improve this question














    bumped to the homepage by Community 3 mins ago


    This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.


















      0












      0








      0


      0






      I have create a programmatically order and set programmatically discount amount but i have getting error when submit order.
      Here is exception message :



      DEBUG (7): ====ex==exception 'Exception' with message 'Quote totals must be collected before this operation.' in /home/xyz/public_html/testing/app/code/core/Mage/Sales/Model/Quote.php:1861
      Stack trace:
      #0 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(326): Mage_Sales_Model_Quote->prepareRecurringPaymentProfiles()
      #1 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(223): Mage_Sales_Model_Service_Quote->_submitRecurringPaymentProfiles()
      #2 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(238): Mage_Sales_Model_Service_Quote->submitNominalItems()
      #3 /home/xyz/public_html/testing/app/code/local/Assel/StoreOwners/controllers/SalesorderController.php(364): Mage_Sales_Model_Service_Quote->submitAll()
      #4 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Assel_StoreOwners_SalesorderController->submitOrderAction()
      #5 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('submitOrder')
      #6 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
      #7 /home/xyz/public_html/testing/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
      #8 /home/xyz/public_html/testing/app/Mage.php(684): Mage_Core_Model_App->run(Array)
      #9 /home/xyz/public_html/testing/sellertesting.xyz.com/index.php(385): Mage::run('sellerwebsite', 'website')
      #10 {main}


      Please can anyone suggest me.










      share|improve this question














      I have create a programmatically order and set programmatically discount amount but i have getting error when submit order.
      Here is exception message :



      DEBUG (7): ====ex==exception 'Exception' with message 'Quote totals must be collected before this operation.' in /home/xyz/public_html/testing/app/code/core/Mage/Sales/Model/Quote.php:1861
      Stack trace:
      #0 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(326): Mage_Sales_Model_Quote->prepareRecurringPaymentProfiles()
      #1 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(223): Mage_Sales_Model_Service_Quote->_submitRecurringPaymentProfiles()
      #2 /home/xyz/public_html/testing/app/code/local/Mage/Sales/Model/Service/Quote.php(238): Mage_Sales_Model_Service_Quote->submitNominalItems()
      #3 /home/xyz/public_html/testing/app/code/local/Assel/StoreOwners/controllers/SalesorderController.php(364): Mage_Sales_Model_Service_Quote->submitAll()
      #4 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Assel_StoreOwners_SalesorderController->submitOrderAction()
      #5 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('submitOrder')
      #6 /home/xyz/public_html/testing/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
      #7 /home/xyz/public_html/testing/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
      #8 /home/xyz/public_html/testing/app/Mage.php(684): Mage_Core_Model_App->run(Array)
      #9 /home/xyz/public_html/testing/sellertesting.xyz.com/index.php(385): Mage::run('sellerwebsite', 'website')
      #10 {main}


      Please can anyone suggest me.







      magento-1.9 orders discount quote






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 28 '17 at 13:49









      Rakesh PatidarRakesh Patidar

      132216




      132216





      bumped to the homepage by Community 3 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







      bumped to the homepage by Community 3 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
























          1 Answer
          1






          active

          oldest

          votes


















          0














          please add your code to question
          i think you should do like this code



                $quote->setData($data);
          $quote->collectTotals()->save();





          share|improve this answer























            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "479"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f166578%2fexception-with-message-quote-totals-must-be-collected-before-this-operation%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            please add your code to question
            i think you should do like this code



                  $quote->setData($data);
            $quote->collectTotals()->save();





            share|improve this answer




























              0














              please add your code to question
              i think you should do like this code



                    $quote->setData($data);
              $quote->collectTotals()->save();





              share|improve this answer


























                0












                0








                0







                please add your code to question
                i think you should do like this code



                      $quote->setData($data);
                $quote->collectTotals()->save();





                share|improve this answer













                please add your code to question
                i think you should do like this code



                      $quote->setData($data);
                $quote->collectTotals()->save();






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered May 18 '17 at 7:07









                gh darvishanigh darvishani

                305217




                305217






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f166578%2fexception-with-message-quote-totals-must-be-collected-before-this-operation%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    “%fieldName is a required field.”, in Magento2 REST API Call for GET Method Type The Next...

                    How to change City field to a dropdown in Checkout step Magento 2Magento 2 : How to change UI field(s)...

                    夢乃愛華...