-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathHarmonyPay.php
83 lines (73 loc) · 1.9 KB
/
HarmonyPay.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<?php
/*
Author: @harmonypay
Author Email: contact@harmonypay.one
Author URI: https://harmonypay.one
Description: Cryptocurrency payment gateway for WooCommerce and Easy Digital Downloads.
Plugin Name: HarmonyPay
Plugin URI: https://harmonypay.one
Text Domain: harmonypay
Version: 0.57
WC tested up to: 5.0.0
*/
namespace harmonypay
{
require_once( __DIR__ . '/vendor/autoload.php' );
class HarmonyPay
extends \plainview\sdk_mcc\wordpress\base
{
/**
@brief Plugin version.
@since 2018-03-14 19:04:03
**/
public $plugin_version = HARMONYPAY_PLUGIN_VERSION;
use \plainview\sdk_mcc\wordpress\traits\debug;
use admin_trait;
use api_trait;
use autosettlement_trait;
use currencies_trait;
use donations_trait;
use wallets_trait;
use menu_trait;
use misc_methods_trait;
use qr_code_trait;
use payment_timer_trait;
/**
@brief Constructor.
@since 2017-12-07 19:31:43
**/
public function _construct()
{
$this->init_admin_trait();
$this->init_api_trait();
$this->init_currencies_trait();
$this->init_donations_trait();
$this->init_menu_trait();
$this->init_misc_methods_trait();
$this->easy_digital_downloads = new ecommerce\easy_digital_downloads\Easy_Digital_Downloads();
$this->woocommerce = new ecommerce\woocommerce\WooCommerce();
if ( defined( 'WP_CLI' ) && WP_CLI )
{
$cli = new cli\HarmonyPay();
\WP_CLI::add_command( 'harmonypay', $cli );
}
if ( ! defined( 'HARMONYPAY_API_URL' ) ) {
$gateway_api_url = $this->get_site_option( 'gateway_api_url', 'https://api.harmonypay.one/api/v1/' );
define('HARMONYPAY_API_URL', $gateway_api_url);
}
}
}
}
namespace
{
define( 'HARMONYPAY_PLUGIN_VERSION', 0.57 );
/**
@brief Return the instance of MCC.
@since 2014-10-18 14:48:37
**/
function HarmonyPay()
{
return harmonypay\HarmonyPay::instance();
}
$harmonypay = new harmonypay\HarmonyPay( __FILE__ );
}