We purchased a bridge between Magento and SugarCRM and it works well but I only want to push the customers and their orders from a few specific customer groups in Magento because we have different divisions. The product support team sent me the following:
if(Mage::getSingleton('customer/session')->isLoggedIn() && Mage::getSingleton('customer/session')->getCustomerGroupId() == GROUP_NUMBER) return true; else return false;
Where GROUP_NUMBER
is the number of the groups you need.
So I did:
if(Mage::getSingleton('customer/session')->isLoggedIn() && Mage::getSingleton('customer/session')->getCustomerGroupId() == 12) return true; else return false;
But it doesn't work. What am I doing wrong?