Skip to content

Commit

Permalink
Merge pull request #20 from RichardCardGate/master
Browse files Browse the repository at this point in the history
Fix: payment title.
  • Loading branch information
cardgate committed Jun 16, 2020
2 parents 67e4eaa + b77de73 commit 2fc9da1
Show file tree
Hide file tree
Showing 23 changed files with 39 additions and 179 deletions.
13 changes: 7 additions & 6 deletions cardgate/cardgate.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Description: Integrates Cardgate Gateway for WooCommerce into WordPress
* Text Domain: cardgate
* Domain Path: /i18n/languages
* Version: 3.1.16
* Version: 3.1.17
* Requires at least: 4.4
* Author: CardGate
* Author URI: http://cardgate.com
Expand Down Expand Up @@ -230,9 +230,9 @@ static function cardgate_config_page() {
$sHtml = '<div class="wrap">
<form name="frmCardgate" action="' . $sAction_url . '" method="post">';
$sHtml .= wp_nonce_field('action854', 'nonce134');
$sHtml .= '
<h2>' . '<img src="' . $icon_file . '" />&nbsp;' . __('CardGate Settings', 'cardgate') . '</h2>
<b>Version ' . get_option('cardgate_version') . '</b>
$sHtml .= '<img style="max-width:100px;" src="' . $icon_file . '" />&nbsp;
<b>Version ' . get_option('cardgate_version') . '</b>
<h2>'. __('CardGate Settings', 'cardgate') . '</h2>
<table class="form-table">
<tbody>
<tr>
Expand Down Expand Up @@ -326,8 +326,9 @@ static function cardgate_payments_table() {
$wp_list_table->prepare_items();
?>
<div class="wrap">
<h2>
<?php '<img src="' . $icon_file . '" />&nbsp;' . __('CardGate Payments','cardgate') ?>
<div><?php echo '<img style="max-width:100px;" src="' . $icon_file . '" />&nbsp;' ?></div>
<h2>
<?php echo __('CardGate Payments','cardgate') ?>
</h2>

<?php $wp_list_table->views(); ?>
Expand Down
8 changes: 8 additions & 0 deletions cardgate/classes/CGP_Common_Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ class CGP_Common_Gateway extends WC_Payment_Gateway {

// ////////////////////////////////////////////////
public function __construct() {
$this->init_form_fields();
$this->init_settings();
$this->title = (isset($this->settings['title']) && !empty($this->settings['title']) ? $this->settings['title'] : $this->payment_name);
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
}

/**
Expand Down
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateAfterpay.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateAfterpay extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateBancontact.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateBancontact extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateBanktransfer.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateBanktransfer extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateBillink.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateBillink extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateBitcoin.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateBitcoin extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateCreditcard.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateCreditcard extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateDirectDebit.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateDirectDebit extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateGiftcard.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateGiftcard extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateGiropay.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateGiropay extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
11 changes: 1 addition & 10 deletions cardgate/classes/WC_CardgateIdeal.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,6 @@ class WC_CardgateIdeal extends CGP_Common_Gateway {
var $has_fields = true; //extra field for bank data

public function __construct() {

$this->supports = array ('products');
$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateIdealqr.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateIdealqr extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateKlarna.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateKlarna extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateMistercash.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateMisterCash extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateOnlineueberweisen.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateOnlineueberweisen extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgatePayPal.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgatePayPal extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgatePaysafecard.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgatePaysafecard extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgatePaysafecash.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgatePaysafecash extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgatePrzelewy24.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgatePrzelewy24 extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
10 changes: 1 addition & 9 deletions cardgate/classes/WC_CardgateSofortbanking.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ class WC_CardgateSofortbanking extends CGP_Common_Gateway {
var $has_fields = false; //extra field for bank data

public function __construct() {

$this->init_form_fields();
$this->init_settings();
$this->title = $this->payment_name;
$this->description = $this->settings['description'];

add_filter ( 'woocommerce_gateway_icon', array($this, 'modify_icon'), 20, 2 );
add_action( 'woocommerce_update_options_payment_gateways_' . $this->id, array( $this, 'process_admin_options' ) );
add_action( 'woocommerce_receipt_' . $this->id, array( $this, 'receiptPage' ) );
parent::__construct();
}
}
Binary file modified cardgate/images/cardgate.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 5 additions & 1 deletion cardgate/readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Contributors: cardgate
Tags: CardGate, iDEAL, Creditcard, WooCommerce, Payment, MisterCash, SofortBanking, OverBoeking, PayPal, Giropay, DirectDebit, Webmoney
Requires at least: 4.2
Tested up to: 5.2
Stable tag: 3.1.16
Stable tag: 3.1.17
License: GPLv3 or later
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -74,6 +74,10 @@ If you are updating from an older version then 3.0.4 you will need new [CardGate

== Changelog ==

= 3.1.17 =
* Fix: Payment method title
* new admin logo

= 3.1.16 =
* New pullConfig method implementation

Expand Down

0 comments on commit 2fc9da1

Please sign in to comment.