zburnham
Total Posts: 69
Joined: 2007-11-07
Westborough, MA
This tutorial does provide some great info… But is there a central documentation repository that I’m not finding? Maybe it’s my lack of deep experience with XML, but how is one to figure out what tags are appropriate in what locations in these files, or how to add things like support for events and so forth?
I admit I’m not a very senior coder, but it seems like there’s a piece missing here that I could really use at this point.
Posted: February 7 2008
| top
| # 61
Methodz
Total Posts: 5
Joined: 2007-09-21
West Haven, UT
Has anybody considered an ACH payment module? I wonder how difficult that’s going to be.
Signature
-- Matt Kammersell
Senior Software Enginner / eCommerce / Software Engineering Consultant
Posted: February 8 2008
| top
| # 62
mediacrea
Total Posts: 38
Joined: 2008-02-06
hi,
I’ve got some french bank kit, I post it here for whom want to make a module from it, I think it will be more easy for the CMCIC kit:
- CMCIC
- SIPS
Sorry for my bad english.
There are some modules developped for virtuemart, perhaps it can boost the integration of payment module.
File Attachments
Posted: February 9 2008
| top
| # 63
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi,
iam trying to get my own payment method shown up in backend, no chance, i tried all hints in that thread. May i post my code here. Maybe iam blind at the moment. Trying under newest version of magento.
MZPayment/etc/config.xml
< config > < modules > < Mage_MZPayment > < version > 0.1.0 </ version > </ Mage_MZPayment > </ modules > <global> < models > < mzpayment > <class> Mage_MZPayment_Model </class> </ mzpayment > </ models > < resources > < mzpayment_setup > < setup > < module > Mage_MZPayment </ module > </ setup > < connection > <use> core_setup </use> </ connection > </ mzpayment_setup > </ resources > </global> <default> < payment > < mzpayment > < active > 1 </ active > < cctypes > AE , VI , MC , DI </ cctypes > < model > payment / method_hpcc </ model > < order_status > pending </ order_status > < title > MZ_Payment </ title > < allowspecific > 0 </ allowspecific > </ mzpayment > </ payment > </default> </ config >
MZPayment/etc/system.xml
< config > < sections > < payment > < groups > < mzpayment translate = "label" > < label > MZ Payment </ label > < frontend_type > text </ frontend_type > < sort_order > 1 </ sort_order > < show_in_default > 1 </ show_in_default > < show_in_website > 1 </ show_in_website > < show_in_store > 0 </ show_in_store > < fields > < active translate = "label" > < label > Enabled </ label > < frontend_type > select </ frontend_type > < source_model > adminhtml / system_config_source_yesno </ source_model > < sort_order > 1 </ sort_order > < show_in_default > 1 </ show_in_default > < show_in_website > 1 </ show_in_website > < show_in_store > 0 </ show_in_store > </ active > < model > </ model > </ fields > </ mzpayment > </ groups > </ payment > </ sections > </ config >
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 16 2008
| top
| # 64
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
MZPayment/Model/HPCc.php
<?php /** Our test CC module adapter**/ class Mage_MZPayment_Model_PaymentMethod extends Mage_Payment_Model_Abstract { /** * unique internal payment method identifier * * @var string [a-z0-9_] **/ protected $_code = 'mzpayment' ; /** * Possible result statuses **/ const RESPONSE_CODE_APPROVED = 1 ; const RESPONSE_CODE_DECLINED = 2 ; const RESPONSE_CODE_ERROR = 3 ; const RESPONSE_CODE_HELD = 4 ; } ?>
MZPayment/sql/mzpayment_setup.php
<?php $code = 'mzpayment' ; $this -> setConfigData ( 'payment/' . $code . '/model' , 'mzpayment/hpcc' ); // create payment method group in Admin / System / Configuration / Payment Methods $this -> addConfigField ( 'payment/' . $code , 'MZPayment' ); // specify title for this payment method $this -> addConfigField ( 'payment/' . $code . '/title' , 'MZPayment' ); $this -> setConfigData ( 'payment/' . $code . '/title' , 'MZPayment' ); // add Enabled flag configuration $this -> addConfigField ( 'payment/' . $code . '/active' , 'Enabled' , array( 'frontend_type' => 'select' , 'source_model' => 'adminhtml/system_config_source_payment_active' ) ); // choose initial order status when checking out with this payment method $this -> addConfigField ( 'payment/' . $code . '/order_status' , 'Order Status' , array( 'frontend_type' => 'select' , 'source_model' => 'adminhtml/system_config_source_order_status' ) ); // set position for this payment method in list $this -> addConfigField ( 'payment/' . $code . '/sort_order' , 'Sort Order' ); ?>
also added app/etc/modules/MZPayment.xml
< config > < modules > < Mage_MZPayment > < active > true </ active > < codePool > locale </ codePool > </ Mage_MZPayment > </ modules > </ config >
and app/etc/local.xml looks like
< config > <global> < install > < date ><! [CDATA[Tue , 05 Feb 2008 18 : 50 : 19 + 0000]] ></ date > </ install > < crypt > < key ><! [CDATA[fsdjk324fjds523jgkv324tg2433s3]] ></ key > </ crypt > < resources > </ resources > </global> < modules > < Mage_MZPayment > < active > true </ active > < codePool > locale </ codePool > </ Mage_MZPayment > </ modules > </ config >
Nothing is shown up in backend, no SQL Inserts in DB, no Errors, using Magento 0.8.16100
Could anyone look at the code and report me my misstakes? For me it seems all is correct…
Maybe version conflicts? smth changed?
Thanks, KR
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 16 2008
| top
| # 65
Moshe
Total Posts: 1771
Joined: 2007-08-07
Los Angeles
[m] Zentrale: things i see right away:
MZPayment/sql/mzpayment_setup.php - the file name is not correct it should be mzpayment_setup-install-0.1.0.php, but it is not needed anymore in new version as all the configuration fiels are read from MZPayment/etc/system.xml
don’t need to update local.xml as you have already created app/etc/modules/MZPayment.xml
rename MZPayment/Model/HPCc.php to MZPayment/Model/Hpcc.php
// instead of class Mage_MZPayment_Model_PaymentMethod extends Mage_Payment_Model_Abstract // use class Mage_MZPayment_Model_Hpcc extends Mage_Payment_Model_Method_Abstract
Signature
- I would love to change the world, but they won’t give me the source code -
Posted: February 16 2008
| top
| # 66
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi Moshe,
it still dont work, but than i tried to adapt the paygate module to an local module. i called it MZHeidelpay. I renamed Models, Controllers and all that stuff to the new names. Copied to local/Menge, cleared all cache in backend, cleared cache in folder, deactivated all caches but my module wount be displayed in payment modules anyway. Is it a problem to name the module and the model with same name? May i attach my adapted module?
KR
Stefan
File Attachments
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 19 2008
| top
| # 67
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi,
Ok, after reading you article i changed following:
name of file MHHeidelpay.php in Model changed to Mzheidelpay.php, also changed classname of model to Mage_MZHeidelpay_Model_Mzheidelpay instead of Mage_MZHeidelpay_Model_MZHeidelpay !
but it is still not shown up in Payment Modules :(! Its listed under “Advanced”
Need some help please
KR
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 19 2008
| top
| # 68
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi Guys,
so, now i have the solution for this:
I have to put my module to folder /app/code/community/Mage/ instead of folder /app/code/local/Mage/
and set in app/etc/modules/MZHeidelpay.xml
< config > < modules > < Mage_Heidelpay > < active > true </ active > < codePool > community </ codePool > </ Mage_Heidelpay > </ modules > </ config >
KR
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 20 2008
| top
| # 69
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi,
iam too stupid, in MZHeidelpay.xml i set for codePool to locale instead of local ! OMG!
cheers
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 20 2008
| top
| # 70
beha
Total Posts: 2
Joined: 2008-02-20
Poland
Hi,
It seems like core_config_field table not longer exists in Magento 8.161
I ‘ve tried to go trough tutorial and at the end I getting an error
Zend_Db_Statement_Exception Object ( [message : protected] => SQLSTATE[42S02] : Base table or view not found : 1146 Table 'magento.core_config_field' doesnt exist [string : private] => [code : protected] => 0 [file : protected] => /var/ ww ... { ... }
Posted: February 20 2008
| top
| # 71
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi,
yes, in new Version smth changed, you dont need the sql any more. During the day ill post my code for implementation of a new Payment Module.
Cu later.
Cheers
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 21 2008
| top
| # 72
beha
Total Posts: 2
Joined: 2008-02-20
Poland
Hi,
Sorry, I should read all posts in the thread… :/ It’s pretty obvious, now.
Posted: February 21 2008
| top
| # 73
[m] zentrale
Total Posts: 401
Joined: 2007-12-06
Stuttgart, Germany
Hi,
np, so i dont have to post my example.
Cheers
Stefan
Signature
Account-User: S. Bothner & A. Jaus
[m] zentrale | InternetAgentur Stuttgart & München
Agentur für Beratung, Entwicklung & Marketing.
Magento™ Silver Partner & Community Pro Member
----
Ich habe Visionen - muss ich jetzt zum Arzt?
Posted: February 21 2008
| top
| # 74
phrench
Total Posts: 32
Joined: 2007-11-10
Moshe - 16 February 2008 09:26 AM
[m] Zentrale: things i see right away:
MZPayment/sql/mzpayment_setup.php - the file name is not correct it should be mzpayment_setup-install-0.1.0.php, but it is not needed anymore in new version as all the configuration fiels are read from MZPayment/etc/system.xml
Does this mean the wiki HowTo is not up to date anymore?
Posted: February 21 2008
| top
| # 75