diff --git a/README.md b/README.md index f714348..ae16621 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# Monero Gateway for WooCommerce +# Wownero Gateway for WooCommerce ## Features -* Payment validation done through either `monero-wallet-rpc` or the [xmrchain.net blockchain explorer](https://xmrchain.net/). +* Payment validation done through either `wownero-wallet-rpc` or the [explore.wownero.com blockchain explorer](https://explore.wownero.com/). * Validates payments with `cron`, so does not require users to stay on the order confirmation page for their order to validate. * Order status updates are done through AJAX instead of Javascript page reloads. * Customers can pay with multiple transactions and are notified as soon as transactions hit the mempool. @@ -10,60 +10,60 @@ * Live price updates every minute; total amount due is locked in after the order is placed for a configurable amount of time (default 60 minutes) so the price does not change after order has been made. * Hooks into emails, order confirmation page, customer order history page, and admin order details page. * View all payments received to your wallet with links to the blockchain explorer and associated orders. -* Optionally display all prices on your store in terms of Monero. +* Optionally display all prices on your store in terms of Wownero. * Shortcodes! Display exchange rates in numerous currencies. ## Requirements -* Monero wallet to receive payments - [GUI](https://github.com/monero-project/monero-gui/releases) - [CLI](https://github.com/monero-project/monero/releases) - [Paper](https://moneroaddress.org/) +* Wownero wallet to receive payments - [GUI](https://github.com/wownero/wownero/releases) * [BCMath](http://php.net/manual/en/book.bc.php) - A PHP extension used for arbitrary precision maths ## Installing the plugin -* Download the plugin from the [releases page](https://github.com/monero-integrations/monerowp) or clone with `git clone https://github.com/monero-integrations/monerowp` -* Unzip or place the `monero-woocommerce-gateway` folder in the `wp-content/plugins` directory. -* Activate "Monero Woocommerce Gateway" in your WordPress admin dashboard. +* Download the plugin from the [releases page](https://github.com/itssteven/monerowp) or clone with `git clone https://github.com/itssteven/monerowp` +* Unzip or place the `wownero-woocommerce-gateway` folder in the `wp-content/plugins` directory. +* Activate "Wownero Woocommerce Gateway" in your WordPress admin dashboard. * It is highly recommended that you use native cronjobs instead of WordPress's "Poor Man's Cron" by adding `define('DISABLE_WP_CRON', true);` into your `wp-config.php` file and adding `* * * * * wget -q -O - https://yourstore.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1` to your crontab. ## Option 1: Use your wallet address and viewkey -This is the easiest way to start accepting Monero on your website. You'll need: +This is the easiest way to start accepting Wownero on your website. You'll need: -* Your Monero wallet address starting with `4` +* Your Wownero wallet address starting with `W` * Your wallet's secret viewkey Then simply select the `viewkey` option in the settings page and paste your address and viewkey. You're all set! -Note on privacy: when you validate transactions with your private viewkey, your viewkey is sent to (but not stored on) xmrchain.net over HTTPS. This could potentially allow an attacker to see your incoming, but not outgoing, transactions if they were to get his hands on your viewkey. Even if this were to happen, your funds would still be safe and it would be impossible for somebody to steal your money. For maximum privacy use your own `monero-wallet-rpc` instance. +Note on privacy: when you validate transactions with your private viewkey, your viewkey is sent to (but not stored on) xmrchain.net over HTTPS. This could potentially allow an attacker to see your incoming, but not outgoing, transactions if they were to get his hands on your viewkey. Even if this were to happen, your funds would still be safe and it would be impossible for somebody to steal your money. For maximum privacy use your own `wownero-wallet-rpc` instance. -## Option 2: Using `monero-wallet-rpc` +## Option 2: Using `wownero-wallet-rpc` -The most secure way to accept Monero on your website. You'll need: +The most secure way to accept Wownero on your website. You'll need: * Root access to your webserver -* Latest [Monero-currency binaries](https://github.com/monero-project/monero/releases) +* Latest [Wownero-currency binaries](https://github.com/wownero/wownero/releases) -After downloading (or compiling) the Monero binaries on your server, install the [systemd unit files](https://github.com/monero-integrations/monerowp/tree/master/assets/systemd-unit-files) or run `monerod` and `monero-wallet-rpc` with `screen` or `tmux`. You can skip running `monerod` by using a remote node with `monero-wallet-rpc` by adding `--daemon-address node.moneroworld.com:18089` to the `monero-wallet-rpc.service` file. +After downloading (or compiling) the Wownero binaries on your server, install the [systemd unit files](https://github.com/monero-integrations/monerowp/tree/master/assets/systemd-unit-files) or run `wownerod` and `wownero-wallet-rpc` with `screen` or `tmux`. You can skip running `wownerod` by using a remote node with `wownero-wallet-rpc` by adding `--daemon-address node.wowne.ro:34568` to the `wownero-wallet-rpc.service` file. -Note on security: using this option, while the most secure, requires you to run the Monero wallet RPC program on your server. Best practice for this is to use a view-only wallet since otherwise your server would be running a hot-wallet and a security breach could allow hackers to empty your funds. +Note on security: using this option, while the most secure, requires you to run the Wownero wallet RPC program on your server. Best practice for this is to use a view-only wallet since otherwise your server would be running a hot-wallet and a security breach could allow hackers to empty your funds. ## Configuration -* `Enable / Disable` - Turn on or off Monero gateway. (Default: Disable) -* `Title` - Name of the payment gateway as displayed to the customer. (Default: Monero Gateway) -* `Discount for using Monero` - Percentage discount applied to orders for paying with Monero. Can also be negative to apply a surcharge. (Default: 0) +* `Enable / Disable` - Turn on or off Wownero gateway. (Default: Disable) +* `Title` - Name of the payment gateway as displayed to the customer. (Default: Wownero Gateway) +* `Discount for using Wownero` - Percentage discount applied to orders for paying with Wownero. Can also be negative to apply a surcharge. (Default: 0) * `Order valid time` - Number of seconds after order is placed that the transaction must be seen in the mempool. (Default: 3600 [1 hour]) * `Number of confirmations` - Number of confirmations the transaction must recieve before the order is marked as complete. Use `0` for nearly instant confirmation. (Default: 5) -* `Confirmation Type` - Confirm transactions with either your viewkey, or by using `monero-wallet-rpc`. (Default: viewkey) -* `Monero Address` (if confirmation type is viewkey) - Your public Monero address starting with 4. (No default) +* `Confirmation Type` - Confirm transactions with either your viewkey, or by using `wownero-wallet-rpc`. (Default: viewkey) +* `Wownero Address` (if confirmation type is viewkey) - Your public Wownero address starting with 4. (No default) * `Secret Viewkey` (if confirmation type is viewkey) - Your *private* viewkey (No default) -* `Monero wallet RPC Host/IP` (if confirmation type is `monero-wallet-rpc`) - IP address where the wallet rpc is running. It is highly discouraged to run the wallet anywhere other than the local server! (Default: 127.0.0.1) -* `Monero wallet RPC port` (if confirmation type is `monero-wallet-rpc`) - Port the wallet rpc is bound to with the `--rpc-bind-port` argument. (Default 18080) +* `Wownero wallet RPC Host/IP` (if confirmation type is `wownero-wallet-rpc`) - IP address where the wallet rpc is running. It is highly discouraged to run the wallet anywhere other than the local server! (Default: 127.0.0.1) +* `Wownero wallet RPC port` (if confirmation type is `wownero-wallet-rpc`) - Port the wallet rpc is bound to with the `--rpc-bind-port` argument. (Default 18080) * `Testnet` - Check this to change the blockchain explorer links to the testnet explorer. (Default: unchecked) * `SSL warnings` - Check this to silence SSL warnings. (Default: unchecked) -* `Show QR Code` - Show payment QR codes. There is no Monero software that can read QR codes at this time (Default: unchecked) -* `Show Prices in Monero` - Convert all prices on the frontend to Monero. Experimental feature, only use if you do not accept any other payment option. (Default: unchecked) -* `Display Decimals` (if show prices in Monero is enabled) - Number of decimals to round prices to on the frontend. The final order amount will not be rounded and will be displayed down to the nanoMonero. (Default: 12) +* `Show QR Code` - Show payment QR codes. There is no Wownero software that can read QR codes at this time (Default: unchecked) +* `Show Prices in Wownero` - Convert all prices on the frontend to Wownero. Experimental feature, only use if you do not accept any other payment option. (Default: unchecked) +* `Display Decimals` (if show prices in Wownero is enabled) - Number of decimals to round prices to on the frontend. The final order amount will not be rounded and will be displayed down to the nanoWownero. (Default: 11) ## Shortcodes @@ -71,35 +71,36 @@ This plugin makes available two shortcodes that you can use in your theme. #### Live price shortcode -This will display the price of Monero in the selected currency. If no currency is provided, the store's default currency will be used. +This will display the price of Wownero in the selected currency. If no currency is provided, the store's default currency will be used. ``` -[monero-price] -[monero-price currency="BTC"] -[monero-price currency="USD"] -[monero-price currency="CAD"] -[monero-price currency="EUR"] -[monero-price currency="GBP"] +[wownero-price] +[wownero-price currency="BTC"] +[wownero-price currency="USD"] +[wownero-price currency="CAD"] +[wownero-price currency="EUR"] +[wownero-price currency="GBP"] ``` Will display: ``` -1 XMR = 123.68000 USD -1 XMR = 0.01827000 BTC -1 XMR = 123.68000 USD -1 XMR = 168.43000 CAD -1 XMR = 105.54000 EUR -1 XMR = 94.84000 GBP +1 WOW = 123.68000 USD +1 WOW = 0.01827000 BTC +1 WOW = 123.68000 USD +1 WOW = 168.43000 CAD +1 WOW = 105.54000 EUR +1 WOW = 94.84000 GBP ``` -#### Monero accepted here badge +#### Wownero accepted here badge -This will display a badge showing that you accept Monero-currency. +This will display a badge showing that you accept Wownero-currency. -`[monero-accepted-here]` +`[wownero-accepted-here]` -![Monero Accepted Here](/assets/images/monero-accepted-here.png?raw=true "Monero Accepted Here") +![Wownero Accepted Here](/assets/images/wownero-accepted-here.png?raw=true "Wownero Accepted Here") ## Donations monero-integrations: 44krVcL6TPkANjpFwS2GWvg1kJhTrN7y9heVeQiDJ3rP8iGbCd5GeA4f3c2NKYHC1R4mCgnW7dsUUUae2m9GiNBGT4T8s2X +guy who converted it to wownero: Wo57gnyJUihhnfpr7rbjv8Q9eJ8igcbyFPtbPogbLoGaLrYCV3RZHANc1SCJoL3WkCD6XGHbVaWYminF6rCzei6Y1Bhix1iRn diff --git a/assets/css/monero-gateway-order-page.css b/assets/css/wownero-gateway-order-page.css similarity index 73% rename from assets/css/monero-gateway-order-page.css rename to assets/css/wownero-gateway-order-page.css index b4c51f3..43c6a1d 100644 --- a/assets/css/monero-gateway-order-page.css +++ b/assets/css/wownero-gateway-order-page.css @@ -1,26 +1,26 @@ -#monero_payment_messages > span { +#wownero_payment_messages > span { display:none; } -.monero_details_row { +.wownero_details_row { display: flex !important; align-items: center; margin:0 -8px; } -.monero_details_row > * { +.wownero_details_row > * { padding:0 8px; } -.monero_details_left { +.wownero_details_left { } -.monero_details_main { +.wownero_details_main { flex-grow: 1; word-break:break-all; } -.monero_details_right.button-row { +.wownero_details_right.button-row { display:flex; margin-top: 5px; align-self: self-start; } -.monero_details_right.button-row button { +.wownero_details_right.button-row button { width: 32px; height: 32px; padding: 6px 2px; @@ -28,10 +28,10 @@ line-height:28px; text-align:center; } -#monero_integrated_address { +#wownero_integrated_address { line-height: 16px; } -#monero_qr_code_container { +#wownero_qr_code_container { position:fixed; top:0; left:0; @@ -40,7 +40,7 @@ z-index:9999; background:rgba(0,0,0,0.5); } -#monero_qr_code { +#wownero_qr_code { position: absolute; width: 256px; height: 256px; @@ -52,13 +52,13 @@ background: white; border-radius: 5px; } -#monero_toast { +#wownero_toast { position: fixed; z-index: 999; top: 32px; right: 12px; } -#monero_toast > div { +#wownero_toast > div { display: block; position: relative; overflow: hidden; @@ -70,9 +70,9 @@ color: white; right: -400px; } -#monero_toast > div.success { +#wownero_toast > div.success { background: rgba(68, 190, 117, 0.8); } -#monero_toast > div.error { +#wownero_toast > div.error { background: rgba(195, 60, 60, 0.8); -} \ No newline at end of file +} diff --git a/assets/images/monero-accepted-here.png b/assets/images/monero-accepted-here.png deleted file mode 100644 index 27ba0c3..0000000 Binary files a/assets/images/monero-accepted-here.png and /dev/null differ diff --git a/assets/images/monero-icon-admin.png b/assets/images/monero-icon-admin.png deleted file mode 100644 index 2f67892..0000000 Binary files a/assets/images/monero-icon-admin.png and /dev/null differ diff --git a/assets/images/monero-icon.png b/assets/images/monero-icon.png deleted file mode 100644 index 65240e1..0000000 Binary files a/assets/images/monero-icon.png and /dev/null differ diff --git a/assets/images/wownero-accepted-here.png b/assets/images/wownero-accepted-here.png new file mode 100644 index 0000000..35dfe0f Binary files /dev/null and b/assets/images/wownero-accepted-here.png differ diff --git a/assets/images/wownero-icon-admin.png b/assets/images/wownero-icon-admin.png new file mode 100644 index 0000000..9becba7 Binary files /dev/null and b/assets/images/wownero-icon-admin.png differ diff --git a/assets/images/wownero-icon.png b/assets/images/wownero-icon.png new file mode 100644 index 0000000..090dacb Binary files /dev/null and b/assets/images/wownero-icon.png differ diff --git a/assets/js/monero-gateway-order-page.js b/assets/js/monero-gateway-order-page.js deleted file mode 100644 index da7ca24..0000000 --- a/assets/js/monero-gateway-order-page.js +++ /dev/null @@ -1,161 +0,0 @@ -/* - * Copyright (c) 2018, Ryo Currency Project -*/ -function monero_showNotification(message, type='success') { - var toast = jQuery('
' + message + '
'); - jQuery('#monero_toast').append(toast); - toast.animate({ "right": "12px" }, "fast"); - setInterval(function() { - toast.animate({ "right": "-400px" }, "fast", function() { - toast.remove(); - }); - }, 2500) -} -function monero_showQR(show=true) { - jQuery('#monero_qr_code_container').toggle(show); -} -function monero_fetchDetails() { - var data = { - '_': jQuery.now(), - 'order_id': monero_details.order_id - }; - jQuery.get(monero_ajax_url, data, function(response) { - if (typeof response.error !== 'undefined') { - console.log(response.error); - } else { - monero_details = response; - monero_updateDetails(); - } - }); -} - -function monero_updateDetails() { - - var details = monero_details; - - jQuery('#monero_payment_messages').children().hide(); - switch(details.status) { - case 'unpaid': - jQuery('.monero_payment_unpaid').show(); - jQuery('.monero_payment_expire_time').html(details.order_expires); - break; - case 'partial': - jQuery('.monero_payment_partial').show(); - jQuery('.monero_payment_expire_time').html(details.order_expires); - break; - case 'paid': - jQuery('.monero_payment_paid').show(); - jQuery('.monero_confirm_time').html(details.time_to_confirm); - jQuery('.button-row button').prop("disabled",true); - break; - case 'confirmed': - jQuery('.monero_payment_confirmed').show(); - jQuery('.button-row button').prop("disabled",true); - break; - case 'expired': - jQuery('.monero_payment_expired').show(); - jQuery('.button-row button').prop("disabled",true); - break; - case 'expired_partial': - jQuery('.monero_payment_expired_partial').show(); - jQuery('.button-row button').prop("disabled",true); - break; - } - - jQuery('#monero_exchange_rate').html('1 XMR = '+details.rate_formatted+' '+details.currency); - jQuery('#monero_total_amount').html(details.amount_total_formatted); - jQuery('#monero_total_paid').html(details.amount_paid_formatted); - jQuery('#monero_total_due').html(details.amount_due_formatted); - - jQuery('#monero_integrated_address').html(details.integrated_address); - - if(monero_show_qr) { - var qr = jQuery('#monero_qr_code').html(''); - new QRCode(qr.get(0), details.qrcode_uri); - } - - if(details.txs.length) { - jQuery('#monero_tx_table').show(); - jQuery('#monero_tx_none').hide(); - jQuery('#monero_tx_table tbody').html(''); - for(var i=0; i < details.txs.length; i++) { - var tx = details.txs[i]; - var height = tx.height == 0 ? 'N/A' : tx.height; - var row = ''+ - ''+ - ''+ - ''+tx.txid+''+ - ''+ - ''+height+''+ - ''+tx.amount_formatted+' Monero'+ - ''; - - jQuery('#monero_tx_table tbody').append(row); - } - } else { - jQuery('#monero_tx_table').hide(); - jQuery('#monero_tx_none').show(); - } - - // Show state change notifications - var new_txs = details.txs; - var old_txs = monero_order_state.txs; - if(new_txs.length != old_txs.length) { - for(var i = 0; i < new_txs.length; i++) { - var is_new_tx = true; - for(var j = 0; j < old_txs.length; j++) { - if(new_txs[i].txid == old_txs[j].txid && new_txs[i].amount == old_txs[j].amount) { - is_new_tx = false; - break; - } - } - if(is_new_tx) { - monero_showNotification('Transaction received for '+new_txs[i].amount_formatted+' Monero'); - } - } - } - - if(details.status != monero_order_state.status) { - switch(details.status) { - case 'paid': - monero_showNotification('Your order has been paid in full'); - break; - case 'confirmed': - monero_showNotification('Your order has been confirmed'); - break; - case 'expired': - case 'expired_partial': - monero_showNotification('Your order has expired', 'error'); - break; - } - } - - monero_order_state = { - status: monero_details.status, - txs: monero_details.txs - }; - -} -jQuery(document).ready(function($) { - if (typeof monero_details !== 'undefined') { - monero_order_state = { - status: monero_details.status, - txs: monero_details.txs - }; - setInterval(monero_fetchDetails, 30000); - monero_updateDetails(); - new ClipboardJS('.clipboard').on('success', function(e) { - e.clearSelection(); - if(e.trigger.disabled) return; - switch(e.trigger.getAttribute('data-clipboard-target')) { - case '#monero_integrated_address': - monero_showNotification('Copied destination address!'); - break; - case '#monero_total_due': - monero_showNotification('Copied total amount due!'); - break; - } - e.clearSelection(); - }); - } -}); \ No newline at end of file diff --git a/assets/js/wownero-gateway-order-page.js b/assets/js/wownero-gateway-order-page.js new file mode 100644 index 0000000..f8e8837 --- /dev/null +++ b/assets/js/wownero-gateway-order-page.js @@ -0,0 +1,161 @@ +/* + * Copyright (c) 2018, Ryo Currency Project +*/ +function wownero_showNotification(message, type='success') { + var toast = jQuery('
' + message + '
'); + jQuery('#wownero_toast').append(toast); + toast.animate({ "right": "12px" }, "fast"); + setInterval(function() { + toast.animate({ "right": "-400px" }, "fast", function() { + toast.remove(); + }); + }, 2500) +} +function wownero_showQR(show=true) { + jQuery('#wownero_qr_code_container').toggle(show); +} +function wownero_fetchDetails() { + var data = { + '_': jQuery.now(), + 'order_id': wownero_details.order_id + }; + jQuery.get(wownero_ajax_url, data, function(response) { + if (typeof response.error !== 'undefined') { + console.log(response.error); + } else { + wownero_details = response; + wownero_updateDetails(); + } + }); +} + +function wownero_updateDetails() { + + var details = wownero_details; + + jQuery('#wownero_payment_messages').children().hide(); + switch(details.status) { + case 'unpaid': + jQuery('.wownero_payment_unpaid').show(); + jQuery('.wownero_payment_expire_time').html(details.order_expires); + break; + case 'partial': + jQuery('.wownero_payment_partial').show(); + jQuery('.wownero_payment_expire_time').html(details.order_expires); + break; + case 'paid': + jQuery('.wownero_payment_paid').show(); + jQuery('.wownero_confirm_time').html(details.time_to_confirm); + jQuery('.button-row button').prop("disabled",true); + break; + case 'confirmed': + jQuery('.wownero_payment_confirmed').show(); + jQuery('.button-row button').prop("disabled",true); + break; + case 'expired': + jQuery('.wownero_payment_expired').show(); + jQuery('.button-row button').prop("disabled",true); + break; + case 'expired_partial': + jQuery('.wownero_payment_expired_partial').show(); + jQuery('.button-row button').prop("disabled",true); + break; + } + + jQuery('#wownero_exchange_rate').html('1 WOW = '+details.rate_formatted+' '+details.currency); + jQuery('#wownero_total_amount').html(details.amount_total_formatted); + jQuery('#wownero_total_paid').html(details.amount_paid_formatted); + jQuery('#wownero_total_due').html(details.amount_due_formatted); + + jQuery('#wownero_integrated_address').html(details.integrated_address); + + if(wownero_show_qr) { + var qr = jQuery('#wownero_qr_code').html(''); + new QRCode(qr.get(0), details.qrcode_uri); + } + + if(details.txs.length) { + jQuery('#wownero_tx_table').show(); + jQuery('#wownero_tx_none').hide(); + jQuery('#wownero_tx_table tbody').html(''); + for(var i=0; i < details.txs.length; i++) { + var tx = details.txs[i]; + var height = tx.height == 0 ? 'N/A' : tx.height; + var row = ''+ + ''+ + ''+ + ''+tx.txid+''+ + ''+ + ''+height+''+ + ''+tx.amount_formatted+' wownero'+ + ''; + + jQuery('#wownero_tx_table tbody').append(row); + } + } else { + jQuery('#wownero_tx_table').hide(); + jQuery('#wownero_tx_none').show(); + } + + // Show state change notifications + var new_txs = details.txs; + var old_txs = wownero_order_state.txs; + if(new_txs.length != old_txs.length) { + for(var i = 0; i < new_txs.length; i++) { + var is_new_tx = true; + for(var j = 0; j < old_txs.length; j++) { + if(new_txs[i].txid == old_txs[j].txid && new_txs[i].amount == old_txs[j].amount) { + is_new_tx = false; + break; + } + } + if(is_new_tx) { + wownero_showNotification('Transaction received for '+new_txs[i].amount_formatted+' wownero'); + } + } + } + + if(details.status != wownero_order_state.status) { + switch(details.status) { + case 'paid': + wownero_showNotification('Your order has been paid in full'); + break; + case 'confirmed': + wownero_showNotification('Your order has been confirmed'); + break; + case 'expired': + case 'expired_partial': + wownero_showNotification('Your order has expired', 'error'); + break; + } + } + + wownero_order_state = { + status: wownero_details.status, + txs: wownero_details.txs + }; + +} +jQuery(document).ready(function($) { + if (typeof wownero_details !== 'undefined') { + wownero_order_state = { + status: wownero_details.status, + txs: wownero_details.txs + }; + setInterval(wownero_fetchDetails, 30000); + wownero_updateDetails(); + new ClipboardJS('.clipboard').on('success', function(e) { + e.clearSelection(); + if(e.trigger.disabled) return; + switch(e.trigger.getAttribute('data-clipboard-target')) { + case '#wownero_integrated_address': + wownero_showNotification('Copied destination address!'); + break; + case '#wownero_total_due': + wownero_showNotification('Copied total amount due!'); + break; + } + e.clearSelection(); + }); + } +}); diff --git a/assets/systemd-unit-files/monero-wallet-rpc.service b/assets/systemd-unit-files/monero-wallet-rpc.service deleted file mode 100644 index 9818c4c..0000000 --- a/assets/systemd-unit-files/monero-wallet-rpc.service +++ /dev/null @@ -1,14 +0,0 @@ -[Unit] -Description=Monero Wallet RPC -After=network.target monerod.service - -[Service] -User=moneroservices -Group=moneroservices -WorkingDirectory=/opt/monero-wallets -Type=simple -ExecStart=/opt/monero-bin/monero-wallet-rpc --wallet-file /opt/monero-wallets/woocommerce --rpc-bind-port 18080 --password-file /opt/monero-wallets/woocommerce.password --disable-rpc-login --log-file /var/log/monero-wallet.log -Restart=always - -[Install] -WantedBy=multi-user.target diff --git a/assets/systemd-unit-files/monerod.service b/assets/systemd-unit-files/monerod.service deleted file mode 100644 index 65e56b7..0000000 --- a/assets/systemd-unit-files/monerod.service +++ /dev/null @@ -1,14 +0,0 @@ -[Unit] -Description=Monero Full Node -After=network.target - -[Service] -User=moneroservices -Group=moneroservices -WorkingDirectory=/opt/monero-data-dir -Type=simple -LimitNOFILE=65535 -ExecStart=/usr/bin/monerod --log-file /var/log/monerod.log --data-dir /opt/monero-data-dir --non-interactive -Restart=always -[Install] -WantedBy=multi-user.target diff --git a/assets/systemd-unit-files/wownero-wallet-rpc.service b/assets/systemd-unit-files/wownero-wallet-rpc.service new file mode 100644 index 0000000..294f0f8 --- /dev/null +++ b/assets/systemd-unit-files/wownero-wallet-rpc.service @@ -0,0 +1,14 @@ +[Unit] +Description=Wownero Wallet RPC +After=network.target wownerod.service + +[Service] +User=wowneroservices +Group=wowneroservices +WorkingDirectory=/opt/wownero-wallets +Type=simple +ExecStart=/opt/wownero-bin/wownero-wallet-rpc --wallet-file /opt/wownero-wallets/woocommerce --rpc-bind-port 18080 --password-file /opt/wownero-wallets/woocommerce.password --disable-rpc-login --log-file /var/log/wownero-wallet.log +Restart=always + +[Install] +WantedBy=multi-user.target diff --git a/assets/systemd-unit-files/wownerod.service b/assets/systemd-unit-files/wownerod.service new file mode 100644 index 0000000..69f99e5 --- /dev/null +++ b/assets/systemd-unit-files/wownerod.service @@ -0,0 +1,14 @@ +[Unit] +Description=Wownero Full Node +After=network.target + +[Service] +User=wowneroservices +Group=wowneroservices +WorkingDirectory=/opt/wownero-data-dir +Type=simple +LimitNOFILE=65535 +ExecStart=/usr/bin/wownerod --log-file /var/log/wownerod.log --data-dir /opt/wownero-data-dir --non-interactive +Restart=always +[Install] +WantedBy=multi-user.target diff --git a/include/admin/class-monero-admin-interface.php b/include/admin/class-wownero-admin-interface.php similarity index 67% rename from include/admin/class-monero-admin-interface.php rename to include/admin/class-wownero-admin-interface.php index 930f84e..1269b59 100644 --- a/include/admin/class-monero-admin-interface.php +++ b/include/admin/class-wownero-admin-interface.php @@ -1,19 +1,19 @@ prepare_items(); $payments_list->display(); } /** - * Monero settings page + * Wownero settings page */ public function settings_page() { WC_Admin_Settings::output(); @@ -105,7 +105,7 @@ class Monero_Admin_Interface { public function settings_page_init() { global $current_tab, $current_section; - $current_section = 'monero_gateway'; + $current_section = 'wownero_gateway'; $current_tab = 'checkout'; // Include settings pages. @@ -130,4 +130,4 @@ class Monero_Admin_Interface { } -return new Monero_Admin_Interface(); +return new Wownero_Admin_Interface(); diff --git a/include/admin/class-monero-admin-payments-list.php b/include/admin/class-wownero-admin-payments-list.php similarity index 86% rename from include/admin/class-monero-admin-payments-list.php rename to include/admin/class-wownero-admin-payments-list.php index 40ea59c..ba3515f 100644 --- a/include/admin/class-monero-admin-payments-list.php +++ b/include/admin/class-wownero-admin-payments-list.php @@ -1,7 +1,7 @@ Wallet height: {$balance['height']}
@@ -69,37 +69,37 @@ HTML; } echo << -

Monero Payments

+

Wownero Payments

$balance_info
- -

Monero Payments List

+

Wownero Payments List

\ No newline at end of file diff --git a/templates/monero-gateway/admin/order-history-error-page.php b/templates/wownero-gateway/admin/order-history-error-page.php similarity index 100% rename from templates/monero-gateway/admin/order-history-error-page.php rename to templates/wownero-gateway/admin/order-history-error-page.php diff --git a/templates/monero-gateway/admin/order-history-page.php b/templates/wownero-gateway/admin/order-history-page.php similarity index 87% rename from templates/monero-gateway/admin/order-history-page.php rename to templates/wownero-gateway/admin/order-history-page.php index cfdb47a..0219a53 100644 --- a/templates/monero-gateway/admin/order-history-page.php +++ b/templates/wownero-gateway/admin/order-history-page.php @@ -1,23 +1,23 @@ - + - + - + - + - + diff --git a/templates/wownero-gateway/admin/settings-page.php b/templates/wownero-gateway/admin/settings-page.php new file mode 100644 index 0000000..6bed925 --- /dev/null +++ b/templates/wownero-gateway/admin/settings-page.php @@ -0,0 +1,54 @@ + +

Wownero Gateway Error:

+ + +

Wownero Gateway Settings

+ + +
+ '; + echo 'Your balance is: ' . $balance['balance'] . '
'; + echo 'Unlocked balance: ' . $balance['unlocked_balance'] . '
'; + ?> +
+ + +
Exchange rate1 XMR = 1 WOW =
Total amount XMR WOW
Total paid XMR WOW
Total due XMR WOW
Order age ago ago
Order exipires
+ +
+ +

Learn more about using the Wownero payment gateway

+ + + + diff --git a/templates/monero-gateway/customer/order-email-block.php b/templates/wownero-gateway/customer/order-email-block.php similarity index 95% rename from templates/monero-gateway/customer/order-email-block.php rename to templates/wownero-gateway/customer/order-email-block.php index 57b1e85..5e6df59 100644 --- a/templates/monero-gateway/customer/order-email-block.php +++ b/templates/wownero-gateway/customer/order-email-block.php @@ -4,7 +4,7 @@ -

Your order has been confirmed. Thank you for paying with Monero!

+

Your order has been confirmed. Thank you for paying with Wownero!

@@ -37,7 +37,7 @@ TOTAL DUE:
- XMR + WOW @@ -45,7 +45,7 @@ EXCHANGE RATE:
- 1 XMR = + 1 WOW = @@ -53,4 +53,4 @@ - \ No newline at end of file + diff --git a/templates/monero-gateway/customer/order-email-error-block.php b/templates/wownero-gateway/customer/order-email-error-block.php similarity index 100% rename from templates/monero-gateway/customer/order-email-error-block.php rename to templates/wownero-gateway/customer/order-email-error-block.php diff --git a/templates/monero-gateway/customer/order-error-page.php b/templates/wownero-gateway/customer/order-error-page.php similarity index 100% rename from templates/monero-gateway/customer/order-error-page.php rename to templates/wownero-gateway/customer/order-error-page.php diff --git a/templates/monero-gateway/customer/order-page.php b/templates/wownero-gateway/customer/order-page.php similarity index 53% rename from templates/monero-gateway/customer/order-page.php rename to templates/wownero-gateway/customer/order-page.php index 8e809a2..7ae519b 100644 --- a/templates/monero-gateway/customer/order-page.php +++ b/templates/wownero-gateway/customer/order-page.php @@ -2,35 +2,35 @@

- + - Please pay the amount due to complete your transactions. Your order will expire in if payment is not received. + Please pay the amount due to complete your transactions. Your order will expire in if payment is not received. - We have received partial payment. Please pay the remaining amount to complete your transactions. Your order will expire in if payment is not received. + We have received partial payment. Please pay the remaining amount to complete your transactions. Your order will expire in if payment is not received. - We have received your payment in full. Please wait while amount is confirmed. Approximate confirm time is .
You can check your payment status anytime in your account dashboard.
+ We have received your payment in full. Please wait while amount is confirmed. Approximate confirm time is .
You can check your payment status anytime in your account dashboard.
- Your order has been confirmed. Thank you for paying with Monero! + Your order has been confirmed. Thank you for paying with Wownero! - Your order has expired. Please place another order to complete your purchase. + Your order has expired. Please place another order to complete your purchase. - Your order has expired. Please contact the store owner to receive refund on your partial payment. + Your order has expired. Please contact the store owner to receive refund on your partial payment.
- + @@ -80,21 +80,21 @@ -