Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

An event is triggered to allow PowerSync product to customize 'Sales Order Status' form in Magento. when you save Opportunity ID on the order page in the admin area.

 

Image Added

 

Code Block
languagephp
titleTNW_Salesforce_Block_Sales_Order_Status_New_Form
Mage::dispatchEvent('tnw_salesforce_order_save_form', array('order' => $_order));

...

Code Block
languagephp
titleExample Observer
<?php

/**
 * Class TNW_Salesforce_Model_Observer
 */
class TNW_Salesforce_Model_Observer
{

    public function orderSaveForm(Varien_Event_Observer $observer) {
		/**
		 * Magento order object
		 * @var Varien_Data_Form $_form
		 */
		$_order = $observer->getData('order');
 
        // Your custom code
    }
 
}

...