Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

“Hook” into checkout process
 
csimon
Jr. Member
 
Total Posts:  12
Joined:  2009-05-04
 

Hi everybody,

first of all, i want to say that i’m very satisfied by magento and it’s proper design and feature richness smile

I’m currently developing a module, which hooks into checkout process in order to check a customers solvency against a database and block a payment method if the customer is not checked solvent, like for example invoice.

Now my question is, how i let a my module “hook” into the checkout process, which classes are responsible for the payment step?

I found the method isAvailable at Mage_Payment_Model_Method_Abstract. how can i extend this class in order to have a modified method for verification of the solvency at every possible payment method? (not all methods should check solvency, if a customer chooses to pay in advance, no solvency check is needed, but it should be possible)

Thanks in advance smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
back2007
Member
 
Total Posts:  59
Joined:  2009-03-30
 

Hi, there are a few articles in the wiki. Hope, you’ll find them useful
http://www.magentocommerce.com/wiki/groups/174/changing_and_customizing_magento_code
http://www.magentocommerce.com/wiki/custom_module_with_custom_database_table

 
Magento Community Magento Community
Magento Community
Magento Community
 
csimon
Jr. Member
 
Total Posts:  12
Joined:  2009-05-04
 

yes, thank you. second link helped me for creating the module itself and extending the Class. Another Question: Where should i place a external PHP library, which is utilized by my module? Is there any Standard for placing librarys in Magento modules or can i place it anywhere? Just want to keep Structure clean smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
back2007
Member
 
Total Posts:  59
Joined:  2009-03-30
 

Try to create subfolder under the “lib” folder.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top