News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Problem with the configuration of developed payment method

Started by michaelpak, October 14, 2015, 09:35:03 AM

Previous topic - Next topic

michaelpak

I'm trying to write plugin for Joomla 2.5, VirtueMart for payment. XML configuration:
<?xml version="1.0" encoding="utf-8"?>
<extension version="2.5" type="plugin" group="vmpayment" method="upgrade">
<name>VMPAYMENT_TEST_PAYMENT</name>
<author>Test</author>
<creationDate>Jan 2015</creationDate>
<copyright>(C) 2015 RBS. All rights reserved.</copyright>
<license>GNU/GPLv3 or late</license>
<authorUrl>http://test.ru/</authorUrl>
<version>1.0.0</version>
<description>Test payment</description>
<files>
<filename plugin="test_payment">test_payment.php</filename>
</files>
<config>
        <fields name="params">
            <fieldset name="basic">
                <field name="merchant" type="text" size="20" label="Логин" description="" default="" />
                <field name="password"  type="text" size="20" label="Пароль" description="" default="" />
                <field name="test" type="list" default="1" label="Режим теста" description="">
<option value="1">Включен</option>
<option value="0">Выключен</option>
                </field>
<field name="step" type="list" default="1" label="СтаSPAMийность" description="">
<option value="1">ОSPAMностаSPAMийный платеж</option>
<option value="2">ДвухстаSPAMийный платеж</option>
</field>
            </fieldset>
        </fields>
    </config>
</extension>


When I'm saving the configuration data, it's stored in a database in table _virtuemart_paymentmethods:
merchant="test"|password="testPwd"|test="1"|step="1"|

However, the stored values are not displayed. Can you help me?

alatak

Hello

You must add this function in your plugin
function plgVmDeclarePluginParamsPaymentVM3( &$data) {
return $this->declarePluginParams('payment', $data);
}