title: How can update Grand Total on observer in Magento?
body: <p>I have an observer for the event </p>
  
  <blockquote>
    <p>controller_action_predispatch_checkout_onepage_savePayment</p>
  </blockquote>
  
  <p>and I want to change the Grand Total based on some conditions.
  I tried with:</p>
  
  <blockquote>
    <p>$value = 100;</p>
    
    <p>$quote = Mage::getSingleton('checkout/type_onepage')->getQuote();</p>
    
    <p>$quote->setGrandTotal($value);</p>
    
    <p>$quote->setTotalsCollectedFlag(false)->collectTotals();</p>
    
    <p>$quote->save();</p>
  </blockquote>
  
  <p>or </p>
  
  <blockquote>
    <p>$value = 100;</p>
    
    <p>$quote = Mage::getSingleton('checkout/type_onepage')->getQuote();</p>
    
    <p>$quote->setGrandTotal($value);</p>
    
    <p>$quote->collectTotals();</p>
    
    <p>$quote->save();</p>
  </blockquote>
  
  <p>But it don't works. Any ideas?</p>
  
  <p>Thanks to all!</p>