Skip to content

Instantly share code, notes, and snippets.

@avstudnitz
Created July 26, 2012 20:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save avstudnitz/3184381 to your computer and use it in GitHub Desktop.
Save avstudnitz/3184381 to your computer and use it in GitHub Desktop.
<?php
class MyCompany_MyModule_Model_Type_Onepage extends Mage_Checkout_Model_Type_Onepage
{
/**
* Save billing address information to quote
* This method is called by One Page Checkout JS (AJAX) while saving the billing information.
*
* @param array $data
* @param int $customerAddressId
* @return Mage_Checkout_Model_Type_Onepage
*/
public function saveBilling($data, $customerAddressId)
{
$group = Mage::app()->getRequest()->getParam('group');
Mage::getSingleton('checkout/session')->setGroup($group);
return parent::saveBilling($data, $customerAddressId);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment