Version Description
Download this release
Release Info
Developer | cklosows |
Plugin | Easy Digital Downloads |
Version | 3.1.0.3 |
Comparing to | |
See all releases |
Code changes from version 3.1.0.2 to 3.1.0.3
- assets/js/edd-admin-settings.js +1 -1
- easy-digital-downloads.php +2 -2
- includes/admin/payments/class-payments-table.php +1 -1
- includes/admin/reporting/export/class-batch-export-payments.php +9 -8
- includes/admin/reporting/export/class-batch-export-taxed-orders.php +6 -5
- includes/admin/reporting/reports-callbacks.php +11 -18
- includes/admin/reporting/reports.php +222 -284
- includes/admin/tools.php +2 -0
- includes/admin/upgrades/v3/class-data-migrator.php +25 -3
- includes/blocks/edd-blocks.php +1 -1
- includes/blocks/includes/checkout/checkout.php +1 -3
- includes/blocks/includes/checkout/forms.php +24 -10
- includes/blocks/includes/orders/functions.php +5 -4
- includes/blocks/includes/orders/orders.php +1 -1
- includes/blocks/views/checkout/purchase-form/logged-in.php +9 -3
- includes/blocks/views/checkout/purchase-form/personal-info.php +39 -33
- includes/class-easy-digital-downloads.php +1 -1
- includes/class-edd-cli.php +9 -0
- includes/class-edd-download.php +1 -1
- includes/compat-functions.php +29 -0
- includes/deprecated-functions.php +182 -0
- includes/discount-functions.php +7 -3
- includes/emails/template.php +37 -6
- includes/gateways/paypal/admin/connect.php +124 -17
- includes/gateways/paypal/ipn.php +405 -0
- includes/gateways/paypal/paypal.php +1 -0
- includes/gateways/paypal/webhooks/functions.php +11 -8
- includes/gateways/stripe/vendor/autoload.php +16 -3
- includes/gateways/stripe/vendor/composer/autoload_psr4.php +0 -1
- includes/gateways/stripe/vendor/composer/autoload_real.php +4 -6
- includes/gateways/stripe/vendor/composer/autoload_static.php +4 -12
- includes/gateways/stripe/vendor/composer/installed.json +0 -153
- includes/gateways/stripe/vendor/composer/installed.php +2 -23
- includes/gateways/stripe/vendor/composer/installers/LICENSE +0 -19
- includes/gateways/stripe/vendor/composer/installers/composer.json +0 -121
- includes/gateways/stripe/vendor/composer/installers/phpstan.neon.dist +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AglInstaller.php +0 -21
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AsgardInstaller.php +0 -49
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AttogramInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BaseInstaller.php +0 -137
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php +0 -126
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BonefishInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CakePHPInstaller.php +0 -65
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ChefInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CiviCrmInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php +0 -32
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Concrete5Installer.php +0 -13
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CraftInstaller.php +0 -35
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CroogoInstaller.php +0 -21
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DframeInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DokuWikiInstaller.php +0 -50
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DolibarrInstaller.php +0 -16
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DrupalInstaller.php +0 -22
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ElggInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/EliasisInstaller.php +0 -12
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php +0 -29
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/EzPlatformInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/FuelInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/FuelphpInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/GravInstaller.php +0 -30
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/HuradInstaller.php +0 -25
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ImageCMSInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Installer.php +0 -297
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ItopInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/JoomlaInstaller.php +0 -15
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KanboardInstaller.php +0 -18
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KirbyInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KnownInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KodiCMSInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KohanaInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php +0 -27
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LaravelInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LavaLiteInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LithiumInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MODXEvoInstaller.php +0 -16
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MagentoInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MajimaInstaller.php +0 -37
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MakoInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MantisBTInstaller.php +0 -23
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MauticInstaller.php +0 -48
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MayaInstaller.php +0 -33
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MediaWikiInstaller.php +0 -51
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MiaoxingInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MicroweberInstaller.php +0 -119
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ModxInstaller.php +0 -12
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MoodleInstaller.php +0 -59
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OctoberInstaller.php +0 -48
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php +0 -24
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php +0 -14
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OxidInstaller.php +0 -59
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PPIInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PhpBBInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php +0 -21
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php +0 -32
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php +0 -29
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Plugin.php +0 -27
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PortoInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PrestashopInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ProcessWireInstaller.php +0 -22
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PuppetInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PxcmsInstaller.php +0 -63
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php +0 -24
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ReIndexInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Redaxo5Installer.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RedaxoInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RoundcubeInstaller.php +0 -22
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SMFInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ShopwareInstaller.php +0 -60
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SilverStripeInstaller.php +0 -35
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php +0 -25
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/StarbugInstaller.php +0 -12
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SyDESInstaller.php +0 -47
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SyliusInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Symfony1Installer.php +0 -26
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php +0 -16
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php +0 -38
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TaoInstaller.php +0 -30
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php +0 -32
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TheliaInstaller.php +0 -12
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TuskInstaller.php +0 -14
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/UserFrostingInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/VanillaInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/VgmcpInstaller.php +0 -49
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WHMCSInstaller.php +0 -21
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WinterInstaller.php +0 -58
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WolfCMSInstaller.php +0 -9
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WordPressInstaller.php +0 -12
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/YawikInstaller.php +0 -32
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ZendInstaller.php +0 -11
- includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ZikulaInstaller.php +0 -10
- includes/gateways/stripe/vendor/composer/installers/src/bootstrap.php +0 -13
- includes/gateways/stripe/vendor/composer/platform_check.php +0 -26
- includes/orders/functions/orders.php +12 -16
- includes/payments/actions.php +0 -166
- includes/process-download.php +38 -4
- includes/shortcodes.php +10 -10
- languages/easy-digital-downloads.pot +393 -336
- readme.txt +23 -2
- templates/history-downloads.php +8 -6
- templates/history-purchases.php +5 -4
assets/js/edd-admin-settings.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(e){var t={};function n(a){if(t[a])return t[a].exports;var o=t[a]={i:a,l:!1,exports:{}};return e[a].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,a){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(n.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(a,o,function(t){return e[t]}.bind(null,o));return a},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=202)}({1:function(e,t){e.exports=jQuery},173:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var a=function(){e.post(ajaxurl,{action:"edd_recapture_remote_install"},(function(e){e.success||!confirm(e.data.error)?window.location.href="https://recapture.io/register":location.reload()}))}}).call(this,n(1))},202:function(e,t,n){"use strict";n.r(t),function(e,t){var a=n(173),o=(n(203),{init:function(){this.general(),this.misc(),this.gateways(),this.emails()},general:function(){var n=e(".edd-color-picker");if(n.length&&n.wpColorPicker(),"undefined"==typeof wp||"1"!==edd_vars.new_media_ui){var a=e(".edd_settings_upload_button");a.length>0&&(window.formfield="",e(document.body).on("click",a,(function(n){n.preventDefault(),window.formfield=e(this).parent().prev(),window.tbframe_interval=setInterval((function(){t("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()}),2e3),tb_show(edd_vars.add_new_download,"media-upload.php?TB_iframe=true")})),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(t){window.formfield?(imgurl=e("a","<div>"+t+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(t),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1})}else{var o;window.formfield="",e(document.body).on("click",".edd_settings_upload_button",(function(t){t.preventDefault();var n=e(this);window.formfield=e(this).parent().prev(),o||((o=wp.media.frames.file_frame=wp.media({title:n.data("uploader_title"),library:{type:"image"},button:{text:n.data("uploader_button_text")},multiple:!1})).on("menu:render:default",(function(e){e.unset("library-separator"),e.unset("gallery"),e.unset("featured-image"),e.unset("embed"),e.set({})})),o.on("select",(function(){o.state().get("selection").each((function(e,t){e=e.toJSON(),window.formfield.val(e.url)}))}))),o.open()})),window.formfield=""}},misc:function(){var t=e('select[name="edd_settings[download_method]"]'),n=t.parent().parent().next();"direct"===t.val()&&(n.css("opacity","0.4"),n.find("input").prop("checked",!1).prop("disabled",!0)),t.on("change",(function(){"direct"===e(this).val()?(n.css("opacity","0.4"),n.find("input").prop("checked",!1).prop("disabled",!0)):(n.find("input").prop("disabled",!1),n.css("opacity","1"))}))},gateways:function(){e('#edd-payment-gateways input[type="checkbox"]').on("change",(function(){var t=e(this).data("gateway-key"),n=e("#edd_settings\\[default_gateway\\]"),a=n.find('option[value="'+t+'"]');a.prop("disabled",(function(e,t){return!t})),a.prop("selected")&&a.prop("selected",!1),n.trigger("chosen:updated")}))},emails:function(){e("#edd-recapture-connect").on("click",(function(t){t.preventDefault(),e(this).html(edd_vars.wait+' <span class="edd-loading"></span>'),document.body.style.cursor="wait",Object(a.a)()}));var t=e('select[name="edd_settings[email_summary_recipient]"]'),n=t.val(),o=e('textarea[name="edd_settings[email_summary_custom_recipients]"]').parents("tr"),d=e("#edd-send-test-summary-save-changes-notice"),i=e("#edd-send-test-summary"),
|
1 |
+
!function(e){var t={};function n(a){if(t[a])return t[a].exports;var o=t[a]={i:a,l:!1,exports:{}};return e[a].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,a){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(n.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(a,o,function(t){return e[t]}.bind(null,o));return a},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=202)}({1:function(e,t){e.exports=jQuery},173:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var a=function(){e.post(ajaxurl,{action:"edd_recapture_remote_install"},(function(e){e.success||!confirm(e.data.error)?window.location.href="https://recapture.io/register":location.reload()}))}}).call(this,n(1))},202:function(e,t,n){"use strict";n.r(t),function(e,t){var a=n(173),o=(n(203),{init:function(){this.general(),this.misc(),this.gateways(),this.emails()},general:function(){var n=e(".edd-color-picker");if(n.length&&n.wpColorPicker(),"undefined"==typeof wp||"1"!==edd_vars.new_media_ui){var a=e(".edd_settings_upload_button");a.length>0&&(window.formfield="",e(document.body).on("click",a,(function(n){n.preventDefault(),window.formfield=e(this).parent().prev(),window.tbframe_interval=setInterval((function(){t("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()}),2e3),tb_show(edd_vars.add_new_download,"media-upload.php?TB_iframe=true")})),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(t){window.formfield?(imgurl=e("a","<div>"+t+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(t),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1})}else{var o;window.formfield="",e(document.body).on("click",".edd_settings_upload_button",(function(t){t.preventDefault();var n=e(this);window.formfield=e(this).parent().prev(),o||((o=wp.media.frames.file_frame=wp.media({title:n.data("uploader_title"),library:{type:"image"},button:{text:n.data("uploader_button_text")},multiple:!1})).on("menu:render:default",(function(e){e.unset("library-separator"),e.unset("gallery"),e.unset("featured-image"),e.unset("embed"),e.set({})})),o.on("select",(function(){o.state().get("selection").each((function(e,t){e=e.toJSON(),window.formfield.val(e.url)}))}))),o.open()})),window.formfield=""}},misc:function(){var t=e('select[name="edd_settings[download_method]"]'),n=t.parent().parent().next();"direct"===t.val()&&(n.css("opacity","0.4"),n.find("input").prop("checked",!1).prop("disabled",!0)),t.on("change",(function(){"direct"===e(this).val()?(n.css("opacity","0.4"),n.find("input").prop("checked",!1).prop("disabled",!0)):(n.find("input").prop("disabled",!1),n.css("opacity","1"))}))},gateways:function(){e('#edd-payment-gateways input[type="checkbox"]').on("change",(function(){var t=e(this).data("gateway-key"),n=e("#edd_settings\\[default_gateway\\]"),a=n.find('option[value="'+t+'"]');a.prop("disabled",(function(e,t){return!t})),a.prop("selected")&&a.prop("selected",!1),n.trigger("chosen:updated")}))},emails:function(){e("#edd-recapture-connect").on("click",(function(t){t.preventDefault(),e(this).html(edd_vars.wait+' <span class="edd-loading"></span>'),document.body.style.cursor="wait",Object(a.a)()}));var t=e('select[name="edd_settings[email_summary_recipient]"]'),n=t.val(),o=e('textarea[name="edd_settings[email_summary_custom_recipients]"]').parents("tr"),d=e("#edd-send-test-summary-save-changes-notice"),i=e("#edd-send-test-summary"),s=e("#edd-send-test-summary-notice");t.on("change",(function(){o.toggleClass("hidden"),i.removeClass("hidden updated-message"),s.empty(),d.empty(),n!==t.val()&&(i.addClass("hidden"),d.html('<div class="notice notice-info"><p>'+edd_vars.test_email_save_changes+"</p></div>"))})),i.on("click",(function(t){t.preventDefault(),e.ajax({type:"GET",dataType:"json",url:ajaxurl,data:{action:"edd_send_test_email_summary"},beforeSend:function(){s.empty(),i.addClass("updating-message").prop("disabled",!0)},success:function(e){"error"==e.status?s.html('<div class="updated '+e.status+'"><p>'+e.message+"</p></div>"):(i.addClass("updated-message"),setTimeout((function(){i.removeClass("updated-message")}),3e3))}}).fail((function(e){window.console&&window.console.log&&console.log(e)})).done((function(e){i.removeClass("updating-message").prop("disabled",!1)}))}))}});t(document).ready((function(e){o.init()}))}.call(this,n(1),n(1))},203:function(e,t,n){(function(e){e(document).ready((function(e){function t(){var t=document.getElementById("edd-paypal-commerce-connect-wrap");t&&e.post(ajaxurl,{action:"edd_paypal_commerce_get_account_info",_ajax_nonce:t.getAttribute("data-nonce")},(function(e){var n="<p>"+eddPayPalConnectVars.defaultError+"</p>";e.success?(n=e.data.account_status,e.data.actions&&e.data.actions.length&&(n+='<p class="edd-paypal-connect-actions">'+e.data.actions.join(" ")+"</p>"),e.data.disconnect_links&&e.data.disconnect_links.length&&(document.getElementById("edd-paypal-disconnect").innerHTML=e.data.disconnect_links.join(" "))):e.data&&e.data.message&&(n=e.data.message),t.innerHTML=n,t.classList.remove("notice-success","notice-warning","notice-error");var a=e.success&&e.data.status?"notice-"+e.data.status:"notice-error";t.classList.add(a)}))}e("#edd-paypal-commerce-connect").on("click",(function(t){t.preventDefault();var n=e("#edd-paypal-commerce-errors");n.empty().removeClass("notice notice-error");var a=document.getElementById("edd-paypal-commerce-connect");a.classList.add("updating-message"),a.disabled=!0,e.post(ajaxurl,{action:"edd_paypal_commerce_connect",_ajax_nonce:e(this).data("nonce")},(function(e){if(!e.success)return console.log("Connection failure",e.data),a.classList.remove("updating-message"),a.disabled=!1,void n.html("<p>"+e.data+"</p>").addClass("notice notice-error");var t=document.getElementById("edd-paypal-commerce-link");t.href=e.data.signupLink+"&displayMode=minibrowser",t.click()}))})),e("#edd-paypal-commerce-reconnect").on("click",(function(t){t.preventDefault();var n=e("#edd-paypal-commerce-errors");n.empty().removeClass("notice notice-error");var a=document.getElementById("edd-paypal-commerce-reconnect");a.classList.add("updating-message"),a.disabled=!0,e.post(ajaxurl,{action:"edd_paypal_commerce_reconnect",_ajax_nonce:e(this).data("nonce")},(function(e){if(!e.success)return console.log("Reconnect failure",e.data),a.classList.remove("updating-message"),a.disabled=!1,void n.html("<p>"+e.data+"</p>").addClass("notice notice-error")}))})),t(),e(document).on("click",".edd-paypal-connect-action",(function(n){n.preventDefault();var a=e(this);a.prop("disabled",!0),a.addClass("updating-message");var o=e("#edd-paypal-commerce-connect-wrap").find(".edd-paypal-actions-error-wrap");o.length&&o.remove(),e.post(ajaxurl,{action:a.data("action"),_ajax_nonce:a.data("nonce")},(function(e){a.prop("disabled",!1),a.removeClass("updating-message"),e.success?(a.addClass("updated-message"),t()):a.parent().after('<p class="edd-paypal-actions-error-wrap">'+e.data+"</p>")}))}))})),window.eddPayPalOnboardingCallback=function(t,n){var a=document.getElementById("edd-paypal-commerce-connect"),o=document.getElementById("edd-paypal-commerce-errors");e.post(ajaxurl,{action:"edd_paypal_commerce_get_access_token",auth_code:t,share_id:n,_ajax_nonce:a.getAttribute("data-nonce")},(function(e){if(a.classList.remove("updating-message"),!e.success)return a.disabled=!1,o.innerHTML="<p>"+e.data+"</p>",void o.classList.add("notice notice-error");a.classList.add("updated-message"),window.location.reload()}))}}).call(this,n(1))}});
|
easy-digital-downloads.php
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
* Description: The easiest way to sell digital products with WordPress.
|
6 |
* Author: Easy Digital Downloads
|
7 |
* Author URI: https://easydigitaldownloads.com
|
8 |
-
* Version: 3.1.0.
|
9 |
* Text Domain: easy-digital-downloads
|
10 |
* Domain Path: languages
|
11 |
* Requires PHP: 5.6
|
@@ -26,7 +26,7 @@
|
|
26 |
* @package EDD
|
27 |
* @category Core
|
28 |
* @author Easy Digital Downloads
|
29 |
-
* @version 3.1.0.
|
30 |
*/
|
31 |
|
32 |
// Exit if accessed directly.
|
5 |
* Description: The easiest way to sell digital products with WordPress.
|
6 |
* Author: Easy Digital Downloads
|
7 |
* Author URI: https://easydigitaldownloads.com
|
8 |
+
* Version: 3.1.0.3
|
9 |
* Text Domain: easy-digital-downloads
|
10 |
* Domain Path: languages
|
11 |
* Requires PHP: 5.6
|
26 |
* @package EDD
|
27 |
* @category Core
|
28 |
* @author Easy Digital Downloads
|
29 |
+
* @version 3.1.0.3
|
30 |
*/
|
31 |
|
32 |
// Exit if accessed directly.
|
includes/admin/payments/class-payments-table.php
CHANGED
@@ -964,7 +964,7 @@ class EDD_Payment_History_Table extends List_Table {
|
|
964 |
|
965 |
// Download ID
|
966 |
if ( is_string( $search ) && ( false !== strpos( $search, '#' ) ) ) {
|
967 |
-
$args['product_id'] =
|
968 |
|
969 |
return $args;
|
970 |
}
|
964 |
|
965 |
// Download ID
|
966 |
if ( is_string( $search ) && ( false !== strpos( $search, '#' ) ) ) {
|
967 |
+
$args['product_id'] = intval( trim( str_replace( '#', '', $search ) ) );
|
968 |
|
969 |
return $args;
|
970 |
}
|
includes/admin/reporting/export/class-batch-export-payments.php
CHANGED
@@ -38,8 +38,8 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
38 |
*/
|
39 |
public function csv_cols() {
|
40 |
$cols = array(
|
41 |
-
'id' => __( '
|
42 |
-
'seq_id' => __( '
|
43 |
'email' => __( 'Email', 'easy-digital-downloads' ),
|
44 |
'customer_id' => __( 'Customer ID', 'easy-digital-downloads' ),
|
45 |
'name' => __( 'Customer Name', 'easy-digital-downloads' ),
|
@@ -91,12 +91,13 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
91 |
$data = array();
|
92 |
|
93 |
$args = array(
|
94 |
-
'number'
|
95 |
-
'offset'
|
96 |
-
'status'
|
97 |
-
'order'
|
98 |
-
'orderby'
|
99 |
-
'type'
|
|
|
100 |
);
|
101 |
|
102 |
if ( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
38 |
*/
|
39 |
public function csv_cols() {
|
40 |
$cols = array(
|
41 |
+
'id' => __( 'Order ID', 'easy-digital-downloads' ), // unaltered payment ID (use for querying)
|
42 |
+
'seq_id' => __( 'Order Number', 'easy-digital-downloads' ), // sequential payment ID
|
43 |
'email' => __( 'Email', 'easy-digital-downloads' ),
|
44 |
'customer_id' => __( 'Customer ID', 'easy-digital-downloads' ),
|
45 |
'name' => __( 'Customer Name', 'easy-digital-downloads' ),
|
91 |
$data = array();
|
92 |
|
93 |
$args = array(
|
94 |
+
'number' => 30,
|
95 |
+
'offset' => ( $this->step * 30 ) - 30,
|
96 |
+
'status' => $this->status,
|
97 |
+
'order' => 'ASC',
|
98 |
+
'orderby' => 'date_created',
|
99 |
+
'type' => 'sale',
|
100 |
+
'status__not_in' => array( 'trash' ),
|
101 |
);
|
102 |
|
103 |
if ( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
includes/admin/reporting/export/class-batch-export-taxed-orders.php
CHANGED
@@ -90,11 +90,12 @@ class EDD_Batch_Taxed_Orders_Export extends EDD_Batch_Export {
|
|
90 |
$data = array();
|
91 |
|
92 |
$args = array(
|
93 |
-
'number'
|
94 |
-
'offset'
|
95 |
-
'status'
|
96 |
-
'order'
|
97 |
-
'orderby'
|
|
|
98 |
);
|
99 |
|
100 |
if ( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
90 |
$data = array();
|
91 |
|
92 |
$args = array(
|
93 |
+
'number' => 30,
|
94 |
+
'offset' => ( $this->step * 30 ) - 30,
|
95 |
+
'status' => $this->status,
|
96 |
+
'order' => 'ASC',
|
97 |
+
'orderby' => 'date_created',
|
98 |
+
'status__not_in' => array( 'trash' ),
|
99 |
);
|
100 |
|
101 |
if ( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
includes/admin/reporting/reports-callbacks.php
CHANGED
@@ -105,10 +105,9 @@ function edd_overview_sales_earnings_chart() {
|
|
105 |
*
|
106 |
* We use the Chart based dates for this loop, so the graph shows in the proper date ranges while the actual DB queries are all UTC based.
|
107 |
*/
|
108 |
-
while ( strtotime( $
|
109 |
-
$
|
110 |
-
$
|
111 |
-
$date_on_chart = new DateTime( $chart_dates['start'], $timezone );
|
112 |
|
113 |
$sales[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
114 |
$sales[ $timestamp ][1] = 0;
|
@@ -118,7 +117,7 @@ function edd_overview_sales_earnings_chart() {
|
|
118 |
|
119 |
// Loop through each date there were sales/earnings, which we queried from the database.
|
120 |
foreach ( $earnings_results as $earnings_result ) {
|
121 |
-
$date_of_db_value =
|
122 |
|
123 |
// Add any sales/earnings that happened during this hour.
|
124 |
if ( $hour_by_hour ) {
|
@@ -143,8 +142,7 @@ function edd_overview_sales_earnings_chart() {
|
|
143 |
|
144 |
// Loop through each date there were sales/earnings, which we queried from the database.
|
145 |
foreach ( $sales_results as $sales_result ) {
|
146 |
-
|
147 |
-
$date_of_db_value = new DateTime( $sales_result->date, $timezone );
|
148 |
|
149 |
// Add any sales/earnings that happened during this hour.
|
150 |
if ( $hour_by_hour ) {
|
@@ -169,17 +167,16 @@ function edd_overview_sales_earnings_chart() {
|
|
169 |
|
170 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
171 |
if ( $hour_by_hour ) {
|
172 |
-
$dates['start']->addHour( 1 );
|
173 |
$chart_dates['start']->addHour( 1 );
|
174 |
} elseif ( $day_by_day ) {
|
175 |
-
$dates['start']->addDays( 1 );
|
176 |
$chart_dates['start']->addDays( 1 );
|
177 |
} else {
|
178 |
-
$dates['start']->addMonth( 1 );
|
179 |
$chart_dates['start']->addMonth( 1 );
|
180 |
}
|
181 |
}
|
182 |
|
|
|
|
|
183 |
return array(
|
184 |
'sales' => array_values( $sales ),
|
185 |
'earnings' => array_values( $earnings ),
|
@@ -245,10 +242,9 @@ function edd_overview_refunds_chart() {
|
|
245 |
$amount = array();
|
246 |
|
247 |
// Initialise all arrays with timestamps and set values to 0.
|
248 |
-
while ( strtotime( $
|
249 |
-
$
|
250 |
-
$
|
251 |
-
$date_on_chart = new DateTime( $chart_dates['start'], $timezone );
|
252 |
|
253 |
$number[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
254 |
$number[ $timestamp ][1] = 0;
|
@@ -258,7 +254,7 @@ function edd_overview_refunds_chart() {
|
|
258 |
|
259 |
// Loop through each date there were refunds, which we queried from the database.
|
260 |
foreach ( $results as $result ) {
|
261 |
-
$date_of_db_value =
|
262 |
|
263 |
// Add any refunds that happened during this hour.
|
264 |
if ( $hour_by_hour ) {
|
@@ -286,13 +282,10 @@ function edd_overview_refunds_chart() {
|
|
286 |
|
287 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
288 |
if ( $hour_by_hour ) {
|
289 |
-
$dates['start']->addHour( 1 );
|
290 |
$chart_dates['start']->addHour( 1 );
|
291 |
} elseif ( $day_by_day ) {
|
292 |
-
$dates['start']->addDays( 1 );
|
293 |
$chart_dates['start']->addDays( 1 );
|
294 |
} else {
|
295 |
-
$dates['start']->addMonth( 1 );
|
296 |
$chart_dates['start']->addMonth( 1 );
|
297 |
}
|
298 |
}
|
105 |
*
|
106 |
* We use the Chart based dates for this loop, so the graph shows in the proper date ranges while the actual DB queries are all UTC based.
|
107 |
*/
|
108 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
109 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
110 |
+
$date_on_chart = $chart_dates['start'];
|
|
|
111 |
|
112 |
$sales[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
113 |
$sales[ $timestamp ][1] = 0;
|
117 |
|
118 |
// Loop through each date there were sales/earnings, which we queried from the database.
|
119 |
foreach ( $earnings_results as $earnings_result ) {
|
120 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $earnings_result->date ) );
|
121 |
|
122 |
// Add any sales/earnings that happened during this hour.
|
123 |
if ( $hour_by_hour ) {
|
142 |
|
143 |
// Loop through each date there were sales/earnings, which we queried from the database.
|
144 |
foreach ( $sales_results as $sales_result ) {
|
145 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $sales_result->date ) );
|
|
|
146 |
|
147 |
// Add any sales/earnings that happened during this hour.
|
148 |
if ( $hour_by_hour ) {
|
167 |
|
168 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
169 |
if ( $hour_by_hour ) {
|
|
|
170 |
$chart_dates['start']->addHour( 1 );
|
171 |
} elseif ( $day_by_day ) {
|
|
|
172 |
$chart_dates['start']->addDays( 1 );
|
173 |
} else {
|
|
|
174 |
$chart_dates['start']->addMonth( 1 );
|
175 |
}
|
176 |
}
|
177 |
|
178 |
+
|
179 |
+
|
180 |
return array(
|
181 |
'sales' => array_values( $sales ),
|
182 |
'earnings' => array_values( $earnings ),
|
242 |
$amount = array();
|
243 |
|
244 |
// Initialise all arrays with timestamps and set values to 0.
|
245 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
246 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
247 |
+
$date_on_chart = $chart_dates['start'];
|
|
|
248 |
|
249 |
$number[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
250 |
$number[ $timestamp ][1] = 0;
|
254 |
|
255 |
// Loop through each date there were refunds, which we queried from the database.
|
256 |
foreach ( $results as $result ) {
|
257 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $result->date ) );
|
258 |
|
259 |
// Add any refunds that happened during this hour.
|
260 |
if ( $hour_by_hour ) {
|
282 |
|
283 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
284 |
if ( $hour_by_hour ) {
|
|
|
285 |
$chart_dates['start']->addHour( 1 );
|
286 |
} elseif ( $day_by_day ) {
|
|
|
287 |
$chart_dates['start']->addDays( 1 );
|
288 |
} else {
|
|
|
289 |
$chart_dates['start']->addMonth( 1 );
|
290 |
}
|
291 |
}
|
includes/admin/reporting/reports.php
CHANGED
@@ -740,25 +740,25 @@ function edd_register_downloads_report( $reports ) {
|
|
740 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
741 |
|
742 |
$sql_clauses = array(
|
743 |
-
'select' => '
|
744 |
-
'
|
745 |
-
'
|
746 |
);
|
747 |
|
|
|
|
|
|
|
|
|
|
|
748 |
if ( $hour_by_hour ) {
|
749 |
-
$sql_clauses =
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
);
|
754 |
-
} elseif ( ! $day_by_day ) {
|
755 |
-
$sql_clauses = array(
|
756 |
-
'select' => 'YEAR(edd_oi.date_created) AS year, MONTH(edd_oi.date_created) AS month',
|
757 |
-
'groupby' => 'YEAR(edd_oi.date_created), MONTH(edd_oi.date_created)',
|
758 |
-
'orderby' => 'YEAR(edd_oi.date_created), MONTH(edd_oi.date_created)',
|
759 |
-
);
|
760 |
}
|
761 |
|
|
|
762 |
$price_id = isset( $download_data['price_id'] ) && is_numeric( $download_data['price_id'] )
|
763 |
? sprintf( 'AND price_id = %d', absint( $download_data['price_id'] ) )
|
764 |
: '';
|
@@ -768,15 +768,13 @@ function edd_register_downloads_report( $reports ) {
|
|
768 |
"SELECT SUM(edd_oi.total / edd_oi.rate) AS earnings, %1s
|
769 |
FROM {$wpdb->edd_order_items} edd_oi
|
770 |
WHERE edd_oi.product_id = %d %1s AND edd_oi.date_created >= %s AND edd_oi.date_created <= %s AND edd_oi.status IN ( 'complete', 'refunded', 'partially_refunded' )
|
771 |
-
GROUP BY
|
772 |
-
ORDER BY
|
773 |
$sql_clauses['select'],
|
774 |
$download_data['download_id'],
|
775 |
$price_id,
|
776 |
$dates['start']->copy()->format( 'mysql' ),
|
777 |
-
$dates['end']->copy()->format( 'mysql' )
|
778 |
-
$sql_clauses['groupby'],
|
779 |
-
$sql_clauses['orderby']
|
780 |
)
|
781 |
);
|
782 |
|
@@ -794,15 +792,13 @@ function edd_register_downloads_report( $reports ) {
|
|
794 |
FROM {$wpdb->edd_order_items} edd_oi
|
795 |
{$join}
|
796 |
WHERE edd_oi.product_id = %d %1s AND edd_oi.date_created >= %s AND edd_oi.date_created <= %s AND edd_oi.status IN ( 'complete', 'refunded', 'partially_refunded' )
|
797 |
-
GROUP BY
|
798 |
-
ORDER BY
|
799 |
$sql_clauses['select'],
|
800 |
$download_data['download_id'],
|
801 |
$price_id,
|
802 |
$dates['start']->copy()->format( 'mysql' ),
|
803 |
-
$dates['end']->copy()->format( 'mysql' )
|
804 |
-
$sql_clauses['groupby'],
|
805 |
-
$sql_clauses['orderby']
|
806 |
)
|
807 |
);
|
808 |
|
@@ -810,83 +806,73 @@ function edd_register_downloads_report( $reports ) {
|
|
810 |
$earnings = array();
|
811 |
|
812 |
// Initialise all arrays with timestamps and set values to 0.
|
813 |
-
while ( strtotime( $
|
814 |
-
$
|
815 |
-
$date_on_chart =
|
816 |
-
|
817 |
-
if ( $hour_by_hour ) {
|
818 |
-
$timestamp = \Carbon\Carbon::create( $dates['start']->year, $dates['start']->month, $dates['start']->day, $dates['start']->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
819 |
|
820 |
-
|
821 |
-
|
822 |
|
823 |
-
|
824 |
-
|
825 |
|
826 |
-
|
827 |
-
|
828 |
-
|
829 |
-
$day = ( true === $day_by_day )
|
830 |
-
? $dates['start']->day
|
831 |
-
: 1;
|
832 |
-
|
833 |
-
$timestamp = \Carbon\Carbon::create( $dates['start']->year, $dates['start']->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
834 |
|
835 |
-
|
836 |
-
|
837 |
-
|
838 |
-
|
839 |
-
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
|
|
|
|
|
|
|
|
|
844 |
} else {
|
845 |
-
|
846 |
-
$
|
|
|
|
|
847 |
}
|
848 |
}
|
849 |
-
}
|
850 |
|
851 |
-
|
852 |
-
|
853 |
-
|
854 |
-
/**
|
855 |
-
* If this is hour by hour, the database returns the timestamps in UTC and an offset
|
856 |
-
* needs to be applied to that.
|
857 |
-
*/
|
858 |
-
$timestamp = \Carbon\Carbon::create( $earnings_result->year, $earnings_result->month, $earnings_result->day, $earnings_result->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
859 |
-
} else {
|
860 |
-
$day = ( true === $day_by_day )
|
861 |
-
? $earnings_result->day
|
862 |
-
: 1;
|
863 |
|
864 |
-
|
865 |
-
|
866 |
-
|
867 |
-
|
868 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
869 |
}
|
870 |
-
}
|
871 |
|
872 |
-
|
873 |
if ( $hour_by_hour ) {
|
874 |
-
|
875 |
-
|
876 |
-
|
877 |
-
* needs to be applied to that.
|
878 |
-
*/
|
879 |
-
$timestamp = \Carbon\Carbon::create( $sales_result->year, $sales_result->month, $sales_result->day, $sales_result->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
880 |
} else {
|
881 |
-
$
|
882 |
-
? $sales_result->day
|
883 |
-
: 1;
|
884 |
-
|
885 |
-
$timestamp = \Carbon\Carbon::create( $sales_result->year, $sales_result->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
886 |
-
}
|
887 |
-
|
888 |
-
if ( isset( $sales[ $timestamp ] ) ) {
|
889 |
-
$sales[ $timestamp ][1] += $sales_result->sales;
|
890 |
}
|
891 |
}
|
892 |
|
@@ -1534,23 +1520,21 @@ function edd_register_payment_gateways_report( $reports ) {
|
|
1534 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
1535 |
|
1536 |
$sql_clauses = array(
|
1537 |
-
'select'
|
1538 |
-
'
|
1539 |
-
'orderby' => 'YEAR(date_created), MONTH(date_created), DAY(date_created)',
|
1540 |
);
|
1541 |
|
|
|
|
|
|
|
|
|
|
|
1542 |
if ( $hour_by_hour ) {
|
1543 |
-
$sql_clauses =
|
1544 |
-
|
1545 |
-
|
1546 |
-
|
1547 |
-
);
|
1548 |
-
} elseif ( ! $day_by_day ) {
|
1549 |
-
$sql_clauses = array(
|
1550 |
-
'select' => 'YEAR(date_created) AS year, MONTH(date_created) AS month',
|
1551 |
-
'groupby' => 'YEAR(date_created), MONTH(date_created)',
|
1552 |
-
'orderby' => 'YEAR(date_created), MONTH(date_created)',
|
1553 |
-
);
|
1554 |
}
|
1555 |
|
1556 |
$gateway = Reports\get_filter_value( 'gateways' );
|
@@ -1577,63 +1561,57 @@ function edd_register_payment_gateways_report( $reports ) {
|
|
1577 |
$sales = array();
|
1578 |
$earnings = array();
|
1579 |
|
1580 |
-
|
1581 |
-
|
1582 |
-
|
1583 |
-
|
|
|
|
|
|
|
|
|
1584 |
|
1585 |
-
|
1586 |
-
|
1587 |
|
1588 |
-
|
1589 |
-
|
1590 |
|
1591 |
-
|
1592 |
-
|
1593 |
-
|
1594 |
-
$dates['start']->addHour( 1 );
|
1595 |
-
$chart_dates['start']->addHour( 1 );
|
1596 |
-
} else {
|
1597 |
-
$day = ( true === $day_by_day )
|
1598 |
-
? $dates['start']->day
|
1599 |
-
: 1;
|
1600 |
-
|
1601 |
-
$timestamp = \Carbon\Carbon::create( $dates['start']->year, $dates['start']->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
1602 |
-
|
1603 |
-
$sales[ $timestamp ][] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
1604 |
-
$sales[ $timestamp ][] = 0;
|
1605 |
-
|
1606 |
-
$earnings[ $timestamp ][] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
1607 |
-
$earnings[ $timestamp ][] = 0.00;
|
1608 |
|
1609 |
-
|
1610 |
-
|
1611 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1612 |
} else {
|
1613 |
-
|
1614 |
-
$
|
|
|
|
|
|
|
1615 |
}
|
1616 |
}
|
1617 |
-
}
|
1618 |
|
1619 |
-
|
1620 |
if ( $hour_by_hour ) {
|
1621 |
-
|
1622 |
-
|
1623 |
-
|
1624 |
-
* needs to be applied to that.
|
1625 |
-
*/
|
1626 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $result->day, $result->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
1627 |
} else {
|
1628 |
-
$
|
1629 |
-
? $result->day
|
1630 |
-
: 1;
|
1631 |
-
|
1632 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
1633 |
}
|
1634 |
-
|
1635 |
-
$sales[ $timestamp ][1] += $result->sales;
|
1636 |
-
$earnings[ $timestamp ][1] += floatval( $result->earnings );
|
1637 |
}
|
1638 |
|
1639 |
$sales = array_values( $sales );
|
@@ -2041,20 +2019,21 @@ function edd_register_file_downloads_report( $reports ) {
|
|
2041 |
$hour_by_hour = Reports\get_dates_filter_hour_by_hour();
|
2042 |
|
2043 |
$sql_clauses = array(
|
2044 |
-
'select'
|
2045 |
-
'where'
|
|
|
2046 |
);
|
2047 |
|
2048 |
// Default to 'monthly'.
|
2049 |
-
$sql_clauses['groupby'] = 'MONTH
|
2050 |
$sql_clauses['orderby'] = 'MONTH(date_created)';
|
2051 |
|
2052 |
// Now drill down to the smallest unit.
|
2053 |
if ( $hour_by_hour ) {
|
2054 |
-
$sql_clauses['groupby'] = 'HOUR
|
2055 |
$sql_clauses['orderby'] = 'HOUR(date_created)';
|
2056 |
} elseif ( $day_by_day ) {
|
2057 |
-
$sql_clauses['groupby'] = 'DATE
|
2058 |
$sql_clauses['orderby'] = 'DATE(date_created)';
|
2059 |
}
|
2060 |
|
@@ -2080,19 +2059,15 @@ function edd_register_file_downloads_report( $reports ) {
|
|
2080 |
$file_downloads = array();
|
2081 |
|
2082 |
// Initialise all arrays with timestamps and set values to 0.
|
2083 |
-
while ( strtotime( $
|
2084 |
-
$
|
2085 |
-
$
|
2086 |
-
|
2087 |
-
$timestamp = $dates['start']->copy()->format( 'U' );
|
2088 |
-
$date_on_chart = new DateTime( $chart_dates['start'], $timezone );
|
2089 |
|
2090 |
$file_downloads[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2091 |
$file_downloads[ $timestamp ][1] = 0;
|
2092 |
|
2093 |
foreach ( $results as $result ) {
|
2094 |
-
$date_of_db_value =
|
2095 |
-
$date_of_db_value = $date_of_db_value->setTimeZone( $timezone );
|
2096 |
|
2097 |
// Add any file downloads that happened during this hour.
|
2098 |
if ( $hour_by_hour ) {
|
@@ -2117,13 +2092,10 @@ function edd_register_file_downloads_report( $reports ) {
|
|
2117 |
|
2118 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
2119 |
if ( $hour_by_hour ) {
|
2120 |
-
$dates['start']->addHour( 1 );
|
2121 |
$chart_dates['start']->addHour( 1 );
|
2122 |
} elseif ( $day_by_day ) {
|
2123 |
-
$dates['start']->addDays( 1 );
|
2124 |
$chart_dates['start']->addDays( 1 );
|
2125 |
} else {
|
2126 |
-
$dates['start']->addMonth( 1 );
|
2127 |
$chart_dates['start']->addMonth( 1 );
|
2128 |
}
|
2129 |
}
|
@@ -2141,15 +2113,16 @@ function edd_register_file_downloads_report( $reports ) {
|
|
2141 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2142 |
'fill' => true,
|
2143 |
'borderWidth' => 2,
|
2144 |
-
'type' => 'currency',
|
2145 |
'pointRadius' => 4,
|
2146 |
'pointHoverRadius' => 6,
|
2147 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
|
|
2148 |
),
|
2149 |
),
|
2150 |
'scales' => array(
|
2151 |
'yAxes' => array(
|
2152 |
array(
|
|
|
2153 |
'type' => 'linear',
|
2154 |
'display' => true,
|
2155 |
'position' => 'left',
|
@@ -2384,24 +2357,23 @@ function edd_register_discounts_report( $reports ) {
|
|
2384 |
$hour_by_hour = Reports\get_dates_filter_hour_by_hour();
|
2385 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
2386 |
|
|
|
2387 |
$sql_clauses = array(
|
2388 |
-
'select'
|
2389 |
-
'
|
2390 |
-
'orderby' => 'YEAR(edd_oa.date_created), MONTH(edd_oa.date_created), DAY(edd_oa.date_created)',
|
2391 |
);
|
2392 |
|
|
|
|
|
|
|
|
|
|
|
2393 |
if ( $hour_by_hour ) {
|
2394 |
-
$sql_clauses =
|
2395 |
-
|
2396 |
-
|
2397 |
-
|
2398 |
-
);
|
2399 |
-
} elseif ( ! $day_by_day ) {
|
2400 |
-
$sql_clauses = array(
|
2401 |
-
'select' => 'YEAR(edd_oa.date_created) AS year, MONTH(edd_oa.date_created) AS month',
|
2402 |
-
'groupby' => 'YEAR(edd_oa.date_created), MONTH(edd_oa.date_created)',
|
2403 |
-
'orderby' => 'YEAR(edd_oa.date_created), MONTH(edd_oa.date_created)',
|
2404 |
-
);
|
2405 |
}
|
2406 |
|
2407 |
$discount_code = ! empty( $d->code )
|
@@ -2419,56 +2391,45 @@ function edd_register_discounts_report( $reports ) {
|
|
2419 |
$discount_usage = array();
|
2420 |
|
2421 |
// Initialise all arrays with timestamps and set values to 0.
|
2422 |
-
while ( strtotime( $
|
2423 |
-
$
|
2424 |
-
$date_on_chart =
|
2425 |
-
|
2426 |
-
|
2427 |
-
|
2428 |
-
|
2429 |
-
|
2430 |
-
|
2431 |
-
|
2432 |
-
|
2433 |
-
|
2434 |
-
|
2435 |
-
|
2436 |
-
|
2437 |
-
|
2438 |
-
|
2439 |
-
|
2440 |
-
|
2441 |
-
|
2442 |
-
|
2443 |
-
|
2444 |
-
|
2445 |
-
|
2446 |
-
$chart_dates['start']->addDays( 1 );
|
2447 |
} else {
|
2448 |
-
|
2449 |
-
$
|
|
|
|
|
2450 |
}
|
2451 |
}
|
2452 |
-
}
|
2453 |
|
2454 |
-
|
2455 |
if ( $hour_by_hour ) {
|
2456 |
-
|
2457 |
-
|
2458 |
-
|
2459 |
-
* needs to be applied to that.
|
2460 |
-
*/
|
2461 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $result->day, $result->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
2462 |
} else {
|
2463 |
-
$
|
2464 |
-
? $result->day
|
2465 |
-
: 1;
|
2466 |
-
|
2467 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
2468 |
-
}
|
2469 |
-
|
2470 |
-
if ( array_key_exists( $timestamp, $discount_usage ) ) {
|
2471 |
-
$discount_usage[ $timestamp ][1] += $result->total;
|
2472 |
}
|
2473 |
}
|
2474 |
|
@@ -2485,7 +2446,6 @@ function edd_register_discounts_report( $reports ) {
|
|
2485 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2486 |
'fill' => true,
|
2487 |
'borderWidth' => 2,
|
2488 |
-
'type' => 'currency',
|
2489 |
'pointRadius' => 4,
|
2490 |
'pointHoverRadius' => 6,
|
2491 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
@@ -2642,23 +2602,17 @@ function edd_register_customer_report( $reports ) {
|
|
2642 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
2643 |
|
2644 |
$sql_clauses = array(
|
2645 |
-
'select' => '
|
2646 |
-
'groupby' =>
|
2647 |
-
'orderby' => '
|
2648 |
);
|
2649 |
|
2650 |
if ( $hour_by_hour ) {
|
2651 |
-
$sql_clauses =
|
2652 |
-
|
2653 |
-
|
2654 |
-
|
2655 |
-
);
|
2656 |
-
} elseif ( ! $day_by_day ) {
|
2657 |
-
$sql_clauses = array(
|
2658 |
-
'select' => 'YEAR(date_created) AS year, MONTH(date_created) AS month',
|
2659 |
-
'groupby' => 'YEAR(date_created), MONTH(date_created)',
|
2660 |
-
'orderby' => 'YEAR(date_created), MONTH(date_created)',
|
2661 |
-
);
|
2662 |
}
|
2663 |
|
2664 |
$results = $wpdb->get_results( $wpdb->prepare(
|
@@ -2672,64 +2626,49 @@ function edd_register_customer_report( $reports ) {
|
|
2672 |
$customers = array();
|
2673 |
|
2674 |
// Initialise all arrays with timestamps and set values to 0.
|
2675 |
-
while ( strtotime( $
|
2676 |
-
$
|
2677 |
-
$date_on_chart =
|
2678 |
|
2679 |
-
|
2680 |
-
|
2681 |
|
2682 |
-
|
2683 |
-
$
|
2684 |
-
|
2685 |
-
$earnings[ $timestamp ][] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2686 |
-
$earnings[ $timestamp ][] = 0.00;
|
2687 |
-
|
2688 |
-
$dates['start']->addHour( 1 );
|
2689 |
-
$chart_dates['start']->addHour( 1 );
|
2690 |
-
} else {
|
2691 |
-
$day = ( true === $day_by_day )
|
2692 |
-
? $dates['start']->day
|
2693 |
-
: 1;
|
2694 |
-
|
2695 |
-
$timestamp = \Carbon\Carbon::create( $dates['start']->year, $dates['start']->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
2696 |
-
|
2697 |
-
$customers[ $timestamp ][] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2698 |
-
$customers[ $timestamp ][] = 0;
|
2699 |
|
2700 |
-
|
2701 |
-
|
2702 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2703 |
} else {
|
2704 |
-
|
2705 |
-
$
|
|
|
|
|
2706 |
}
|
2707 |
}
|
2708 |
-
}
|
2709 |
|
2710 |
-
|
2711 |
if ( $hour_by_hour ) {
|
2712 |
-
|
2713 |
-
|
2714 |
-
|
2715 |
-
* needs to be applied to that.
|
2716 |
-
*/
|
2717 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $result->day, $result->hour, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
2718 |
} else {
|
2719 |
-
$
|
2720 |
-
? $result->day
|
2721 |
-
: 1;
|
2722 |
-
|
2723 |
-
$timestamp = \Carbon\Carbon::create( $result->year, $result->month, $day, 0, 0, 0, 'UTC' )->setTimezone( edd_get_timezone_id() )->timestamp;
|
2724 |
}
|
2725 |
-
|
2726 |
-
$customers[ $timestamp ][1] += $result->total;
|
2727 |
}
|
2728 |
|
2729 |
-
$customers = array_values( $customers );
|
2730 |
-
|
2731 |
return array(
|
2732 |
-
'customers' => $customers,
|
2733 |
);
|
2734 |
},
|
2735 |
'type' => 'line',
|
@@ -2741,7 +2680,6 @@ function edd_register_customer_report( $reports ) {
|
|
2741 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2742 |
'fill' => true,
|
2743 |
'borderWidth' => 2,
|
2744 |
-
'type' => 'currency',
|
2745 |
'pointRadius' => 4,
|
2746 |
'pointHoverRadius' => 6,
|
2747 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
740 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
741 |
|
742 |
$sql_clauses = array(
|
743 |
+
'select' => 'edd_oi.date_created AS date',
|
744 |
+
'where' => '',
|
745 |
+
'groupby' => '',
|
746 |
);
|
747 |
|
748 |
+
// Default to 'monthly'.
|
749 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'MONTH', 'edd_oi.date_created' );
|
750 |
+
$sql_clauses['orderby'] = 'MONTH(edd_oi.date_created)';
|
751 |
+
|
752 |
+
// Now drill down to the smallest unit.
|
753 |
if ( $hour_by_hour ) {
|
754 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'HOUR', 'edd_oi.date_created' );
|
755 |
+
$sql_clauses['orderby'] = 'HOUR(edd_oi.date_created)';
|
756 |
+
} elseif ( $day_by_day ) {
|
757 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'DATE', 'edd_oi.date_created' );
|
758 |
+
$sql_clauses['orderby'] = 'DATE(edd_oi.date_created)';
|
|
|
|
|
|
|
|
|
|
|
|
|
759 |
}
|
760 |
|
761 |
+
|
762 |
$price_id = isset( $download_data['price_id'] ) && is_numeric( $download_data['price_id'] )
|
763 |
? sprintf( 'AND price_id = %d', absint( $download_data['price_id'] ) )
|
764 |
: '';
|
768 |
"SELECT SUM(edd_oi.total / edd_oi.rate) AS earnings, %1s
|
769 |
FROM {$wpdb->edd_order_items} edd_oi
|
770 |
WHERE edd_oi.product_id = %d %1s AND edd_oi.date_created >= %s AND edd_oi.date_created <= %s AND edd_oi.status IN ( 'complete', 'refunded', 'partially_refunded' )
|
771 |
+
GROUP BY {$sql_clauses['groupby']}
|
772 |
+
ORDER BY {$sql_clauses['orderby']} ASC",
|
773 |
$sql_clauses['select'],
|
774 |
$download_data['download_id'],
|
775 |
$price_id,
|
776 |
$dates['start']->copy()->format( 'mysql' ),
|
777 |
+
$dates['end']->copy()->format( 'mysql' )
|
|
|
|
|
778 |
)
|
779 |
);
|
780 |
|
792 |
FROM {$wpdb->edd_order_items} edd_oi
|
793 |
{$join}
|
794 |
WHERE edd_oi.product_id = %d %1s AND edd_oi.date_created >= %s AND edd_oi.date_created <= %s AND edd_oi.status IN ( 'complete', 'refunded', 'partially_refunded' )
|
795 |
+
GROUP BY {$sql_clauses['groupby']}
|
796 |
+
ORDER BY {$sql_clauses['orderby']} ASC",
|
797 |
$sql_clauses['select'],
|
798 |
$download_data['download_id'],
|
799 |
$price_id,
|
800 |
$dates['start']->copy()->format( 'mysql' ),
|
801 |
+
$dates['end']->copy()->format( 'mysql' )
|
|
|
|
|
802 |
)
|
803 |
);
|
804 |
|
806 |
$earnings = array();
|
807 |
|
808 |
// Initialise all arrays with timestamps and set values to 0.
|
809 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
810 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
811 |
+
$date_on_chart = $chart_dates['start'];
|
|
|
|
|
|
|
812 |
|
813 |
+
$sales[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
814 |
+
$sales[ $timestamp ][1] = 0;
|
815 |
|
816 |
+
$earnings[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
817 |
+
$earnings[ $timestamp ][1] = 0.00;
|
818 |
|
819 |
+
// Loop through each date there were sales/earnings, which we queried from the database.
|
820 |
+
foreach ( $earnings_results as $earnings_result ) {
|
821 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $earnings_result->date ) );
|
|
|
|
|
|
|
|
|
|
|
822 |
|
823 |
+
// Add any sales/earnings that happened during this hour.
|
824 |
+
if ( $hour_by_hour ) {
|
825 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
826 |
+
if ( $date_of_db_value->format( 'Y-m-d H' ) === $date_on_chart->format( 'Y-m-d H' ) ) {
|
827 |
+
$earnings[ $timestamp ][1] += $earnings_result->earnings;
|
828 |
+
}
|
829 |
+
// Add any sales/earnings that happened during this day.
|
830 |
+
} elseif ( $day_by_day ) {
|
831 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
832 |
+
if ( $date_of_db_value->format( 'Y-m-d' ) === $date_on_chart->format( 'Y-m-d' ) ) {
|
833 |
+
$earnings[ $timestamp ][1] += $earnings_result->earnings;
|
834 |
+
}
|
835 |
+
// Add any sales/earnings that happened during this month.
|
836 |
} else {
|
837 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
838 |
+
if ( $date_of_db_value->format( 'Y-m' ) === $date_on_chart->format( 'Y-m' ) ) {
|
839 |
+
$earnings[ $timestamp ][1] += $earnings_result->earnings;
|
840 |
+
}
|
841 |
}
|
842 |
}
|
|
|
843 |
|
844 |
+
// Loop through each date there were sales/earnings, which we queried from the database.
|
845 |
+
foreach ( $sales_results as $sales_result ) {
|
846 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $sales_result->date ) );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
847 |
|
848 |
+
// Add any sales/earnings that happened during this hour.
|
849 |
+
if ( $hour_by_hour ) {
|
850 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
851 |
+
if ( $date_of_db_value->format( 'Y-m-d H' ) === $date_on_chart->format( 'Y-m-d H' ) ) {
|
852 |
+
$sales[ $timestamp ][1] += $sales_result->sales;
|
853 |
+
}
|
854 |
+
// Add any sales/earnings that happened during this day.
|
855 |
+
} elseif ( $day_by_day ) {
|
856 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
857 |
+
if ( $date_of_db_value->format( 'Y-m-d' ) === $date_on_chart->format( 'Y-m-d' ) ) {
|
858 |
+
$sales[ $timestamp ][1] += $sales_result->sales;
|
859 |
+
}
|
860 |
+
// Add any sales/earnings that happened during this month.
|
861 |
+
} else {
|
862 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
863 |
+
if ( $date_of_db_value->format( 'Y-m' ) === $date_on_chart->format( 'Y-m' ) ) {
|
864 |
+
$sales[ $timestamp ][1] += $sales_result->sales;
|
865 |
+
}
|
866 |
+
}
|
867 |
}
|
|
|
868 |
|
869 |
+
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
870 |
if ( $hour_by_hour ) {
|
871 |
+
$chart_dates['start']->addHour( 1 );
|
872 |
+
} elseif ( $day_by_day ) {
|
873 |
+
$chart_dates['start']->addDays( 1 );
|
|
|
|
|
|
|
874 |
} else {
|
875 |
+
$chart_dates['start']->addMonth( 1 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
876 |
}
|
877 |
}
|
878 |
|
1520 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
1521 |
|
1522 |
$sql_clauses = array(
|
1523 |
+
'select' => 'date_created AS date',
|
1524 |
+
'where' => '',
|
|
|
1525 |
);
|
1526 |
|
1527 |
+
// Default to 'monthly'.
|
1528 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'MONTH', 'date_created' );
|
1529 |
+
$sql_clauses['orderby'] = 'MONTH(date_created)';
|
1530 |
+
|
1531 |
+
// Now drill down to the smallest unit.
|
1532 |
if ( $hour_by_hour ) {
|
1533 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'HOUR', 'date_created' );
|
1534 |
+
$sql_clauses['orderby'] = 'HOUR(date_created)';
|
1535 |
+
} elseif ( $day_by_day ) {
|
1536 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'DATE', 'date_created' );
|
1537 |
+
$sql_clauses['orderby'] = 'DATE(date_created)';
|
|
|
|
|
|
|
|
|
|
|
|
|
1538 |
}
|
1539 |
|
1540 |
$gateway = Reports\get_filter_value( 'gateways' );
|
1561 |
$sales = array();
|
1562 |
$earnings = array();
|
1563 |
|
1564 |
+
/**
|
1565 |
+
* Initialise all arrays with timestamps and set values to 0.
|
1566 |
+
*
|
1567 |
+
* We use the Chart based dates for this loop, so the graph shows in the proper date ranges while the actual DB queries are all UTC based.
|
1568 |
+
*/
|
1569 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
1570 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
1571 |
+
$date_on_chart = $chart_dates['start'];
|
1572 |
|
1573 |
+
$sales[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
1574 |
+
$sales[ $timestamp ][1] = 0;
|
1575 |
|
1576 |
+
$earnings[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
1577 |
+
$earnings[ $timestamp ][1] = 0.00;
|
1578 |
|
1579 |
+
// Loop through each date there were sales/earnings, which we queried from the database.
|
1580 |
+
foreach ( $results as $result ) {
|
1581 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $result->date ) );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1582 |
|
1583 |
+
// Add any sales/earnings that happened during this hour.
|
1584 |
+
if ( $hour_by_hour ) {
|
1585 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
1586 |
+
if ( $date_of_db_value->format( 'Y-m-d H' ) === $date_on_chart->format( 'Y-m-d H' ) ) {
|
1587 |
+
$sales[ $timestamp ][1] += $result->sales;
|
1588 |
+
$earnings[ $timestamp ][1] += $result->earnings;
|
1589 |
+
}
|
1590 |
+
// Add any sales/earnings that happened during this day.
|
1591 |
+
} elseif ( $day_by_day ) {
|
1592 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
1593 |
+
if ( $date_of_db_value->format( 'Y-m-d' ) === $date_on_chart->format( 'Y-m-d' ) ) {
|
1594 |
+
$sales[ $timestamp ][1] += $result->sales;
|
1595 |
+
$earnings[ $timestamp ][1] += $result->earnings;
|
1596 |
+
}
|
1597 |
+
// Add any sales/earnings that happened during this month.
|
1598 |
} else {
|
1599 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
1600 |
+
if ( $date_of_db_value->format( 'Y-m' ) === $date_on_chart->format( 'Y-m' ) ) {
|
1601 |
+
$sales[ $timestamp ][1] += $result->sales;
|
1602 |
+
$earnings[ $timestamp ][1] += $result->earnings;
|
1603 |
+
}
|
1604 |
}
|
1605 |
}
|
|
|
1606 |
|
1607 |
+
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
1608 |
if ( $hour_by_hour ) {
|
1609 |
+
$chart_dates['start']->addHour( 1 );
|
1610 |
+
} elseif ( $day_by_day ) {
|
1611 |
+
$chart_dates['start']->addDays( 1 );
|
|
|
|
|
|
|
1612 |
} else {
|
1613 |
+
$chart_dates['start']->addMonth( 1 );
|
|
|
|
|
|
|
|
|
1614 |
}
|
|
|
|
|
|
|
1615 |
}
|
1616 |
|
1617 |
$sales = array_values( $sales );
|
2019 |
$hour_by_hour = Reports\get_dates_filter_hour_by_hour();
|
2020 |
|
2021 |
$sql_clauses = array(
|
2022 |
+
'select' => 'date_created AS date',
|
2023 |
+
'where' => '',
|
2024 |
+
'groupby' => '',
|
2025 |
);
|
2026 |
|
2027 |
// Default to 'monthly'.
|
2028 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'MONTH', 'date_created' );
|
2029 |
$sql_clauses['orderby'] = 'MONTH(date_created)';
|
2030 |
|
2031 |
// Now drill down to the smallest unit.
|
2032 |
if ( $hour_by_hour ) {
|
2033 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'HOUR', 'date_created' );
|
2034 |
$sql_clauses['orderby'] = 'HOUR(date_created)';
|
2035 |
} elseif ( $day_by_day ) {
|
2036 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'DATE', 'date_created' );
|
2037 |
$sql_clauses['orderby'] = 'DATE(date_created)';
|
2038 |
}
|
2039 |
|
2059 |
$file_downloads = array();
|
2060 |
|
2061 |
// Initialise all arrays with timestamps and set values to 0.
|
2062 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
2063 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
2064 |
+
$date_on_chart = $chart_dates['start'];
|
|
|
|
|
|
|
2065 |
|
2066 |
$file_downloads[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2067 |
$file_downloads[ $timestamp ][1] = 0;
|
2068 |
|
2069 |
foreach ( $results as $result ) {
|
2070 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $result->date ) );
|
|
|
2071 |
|
2072 |
// Add any file downloads that happened during this hour.
|
2073 |
if ( $hour_by_hour ) {
|
2092 |
|
2093 |
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
2094 |
if ( $hour_by_hour ) {
|
|
|
2095 |
$chart_dates['start']->addHour( 1 );
|
2096 |
} elseif ( $day_by_day ) {
|
|
|
2097 |
$chart_dates['start']->addDays( 1 );
|
2098 |
} else {
|
|
|
2099 |
$chart_dates['start']->addMonth( 1 );
|
2100 |
}
|
2101 |
}
|
2113 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2114 |
'fill' => true,
|
2115 |
'borderWidth' => 2,
|
|
|
2116 |
'pointRadius' => 4,
|
2117 |
'pointHoverRadius' => 6,
|
2118 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
2119 |
+
'yAxisID' => 'file-downloads-y',
|
2120 |
),
|
2121 |
),
|
2122 |
'scales' => array(
|
2123 |
'yAxes' => array(
|
2124 |
array(
|
2125 |
+
'id' => 'file-downloads-y',
|
2126 |
'type' => 'linear',
|
2127 |
'display' => true,
|
2128 |
'position' => 'left',
|
2357 |
$hour_by_hour = Reports\get_dates_filter_hour_by_hour();
|
2358 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
2359 |
|
2360 |
+
|
2361 |
$sql_clauses = array(
|
2362 |
+
'select' => 'edd_oa.date_created AS date',
|
2363 |
+
'where' => '',
|
|
|
2364 |
);
|
2365 |
|
2366 |
+
// Default to 'monthly'.
|
2367 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'MONTH', 'edd_oa.date_created' );
|
2368 |
+
$sql_clauses['orderby'] = 'MONTH(edd_oa.date_created)';
|
2369 |
+
|
2370 |
+
// Now drill down to the smallest unit.
|
2371 |
if ( $hour_by_hour ) {
|
2372 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'HOUR', 'edd_oa.date_created' );
|
2373 |
+
$sql_clauses['orderby'] = 'HOUR(edd_oa.date_created)';
|
2374 |
+
} elseif ( $day_by_day ) {
|
2375 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'DATE', 'edd_oa.date_created' );
|
2376 |
+
$sql_clauses['orderby'] = 'DATE(edd_oa.date_created)';
|
|
|
|
|
|
|
|
|
|
|
|
|
2377 |
}
|
2378 |
|
2379 |
$discount_code = ! empty( $d->code )
|
2391 |
$discount_usage = array();
|
2392 |
|
2393 |
// Initialise all arrays with timestamps and set values to 0.
|
2394 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
2395 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
2396 |
+
$date_on_chart = $chart_dates['start'];
|
2397 |
+
|
2398 |
+
$discount_usage[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2399 |
+
$discount_usage[ $timestamp ][1] = 0;
|
2400 |
+
|
2401 |
+
// Loop through each date in which there were discount codes used, which we queried from the database.
|
2402 |
+
foreach ( $results as $result ) {
|
2403 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $result->date ) );
|
2404 |
+
|
2405 |
+
// Add any discount codes that were used during this hour.
|
2406 |
+
if ( $hour_by_hour ) {
|
2407 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2408 |
+
if ( $date_of_db_value->format( 'Y-m-d H' ) === $date_on_chart->format( 'Y-m-d H' ) ) {
|
2409 |
+
$discount_usage[ $timestamp ][1] += abs( $result->total );
|
2410 |
+
}
|
2411 |
+
// Add any discount codes that were used during this day.
|
2412 |
+
} elseif ( $day_by_day ) {
|
2413 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2414 |
+
if ( $date_of_db_value->format( 'Y-m-d' ) === $date_on_chart->format( 'Y-m-d' ) ) {
|
2415 |
+
$discount_usage[ $timestamp ][1] += abs( $result->total );
|
2416 |
+
}
|
2417 |
+
// Add any discount codes that were used during this month.
|
|
|
2418 |
} else {
|
2419 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2420 |
+
if ( $date_of_db_value->format( 'Y-m' ) === $date_on_chart->format( 'Y-m' ) ) {
|
2421 |
+
$discount_usage[ $timestamp ][1] += abs( $result->total );
|
2422 |
+
}
|
2423 |
}
|
2424 |
}
|
|
|
2425 |
|
2426 |
+
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
2427 |
if ( $hour_by_hour ) {
|
2428 |
+
$chart_dates['start']->addHour( 1 );
|
2429 |
+
} elseif ( $day_by_day ) {
|
2430 |
+
$chart_dates['start']->addDays( 1 );
|
|
|
|
|
|
|
2431 |
} else {
|
2432 |
+
$chart_dates['start']->addMonth( 1 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2433 |
}
|
2434 |
}
|
2435 |
|
2446 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2447 |
'fill' => true,
|
2448 |
'borderWidth' => 2,
|
|
|
2449 |
'pointRadius' => 4,
|
2450 |
'pointHoverRadius' => 6,
|
2451 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
2602 |
$chart_dates = Reports\parse_dates_for_range( null, 'now', false );
|
2603 |
|
2604 |
$sql_clauses = array(
|
2605 |
+
'select' => 'date_created AS date',
|
2606 |
+
'groupby' => Reports\get_groupby_date_string( 'MONTH', 'date_created' ),
|
2607 |
+
'orderby' => 'MONTH(date_created)',
|
2608 |
);
|
2609 |
|
2610 |
if ( $hour_by_hour ) {
|
2611 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'HOUR', 'date_created' );
|
2612 |
+
$sql_clauses['orderby'] = 'HOUR(date_created)';
|
2613 |
+
} elseif ( $day_by_day ) {
|
2614 |
+
$sql_clauses['groupby'] = Reports\get_groupby_date_string( 'DATE', 'date_created' );
|
2615 |
+
$sql_clauses['orderby'] = 'DATE(date_created)';
|
|
|
|
|
|
|
|
|
|
|
|
|
2616 |
}
|
2617 |
|
2618 |
$results = $wpdb->get_results( $wpdb->prepare(
|
2626 |
$customers = array();
|
2627 |
|
2628 |
// Initialise all arrays with timestamps and set values to 0.
|
2629 |
+
while ( strtotime( $chart_dates['start']->copy()->format( 'mysql' ) ) <= strtotime( $chart_dates['end']->copy()->format( 'mysql' ) ) ) {
|
2630 |
+
$timestamp = $chart_dates['start']->copy()->format( 'U' );
|
2631 |
+
$date_on_chart = $chart_dates['start'];
|
2632 |
|
2633 |
+
$customers[ $timestamp ][0] = $date_on_chart->format( 'Y-m-d H:i:s' );
|
2634 |
+
$customers[ $timestamp ][1] = 0;
|
2635 |
|
2636 |
+
foreach ( $results as $result ) {
|
2637 |
+
$date_of_db_value = edd_get_edd_timezone_equivalent_date_from_utc( EDD()->utils->date( $result->date ) );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2638 |
|
2639 |
+
// Add any new customers that were created during this hour.
|
2640 |
+
if ( $hour_by_hour ) {
|
2641 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2642 |
+
if ( $date_of_db_value->format( 'Y-m-d H' ) === $date_on_chart->format( 'Y-m-d H' ) ) {
|
2643 |
+
$customers[ $timestamp ][1] += $result->total;
|
2644 |
+
}
|
2645 |
+
// Add any new customers that were created during this day.
|
2646 |
+
} elseif ( $day_by_day ) {
|
2647 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2648 |
+
if ( $date_of_db_value->format( 'Y-m-d' ) === $date_on_chart->format( 'Y-m-d' ) ) {
|
2649 |
+
$customers[ $timestamp ][1] += $result->total;
|
2650 |
+
}
|
2651 |
+
// Add any new customers that were created during this month.
|
2652 |
} else {
|
2653 |
+
// If the date of this db value matches the date on this line graph/chart, set the y axis value for the chart to the number in the DB result.
|
2654 |
+
if ( $date_of_db_value->format( 'Y-m' ) === $date_on_chart->format( 'Y-m' ) ) {
|
2655 |
+
$customers[ $timestamp ][1] += $result->total;
|
2656 |
+
}
|
2657 |
}
|
2658 |
}
|
|
|
2659 |
|
2660 |
+
// Move the chart along to the next hour/day/month to get ready for the next loop.
|
2661 |
if ( $hour_by_hour ) {
|
2662 |
+
$chart_dates['start']->addHour( 1 );
|
2663 |
+
} elseif ( $day_by_day ) {
|
2664 |
+
$chart_dates['start']->addDays( 1 );
|
|
|
|
|
|
|
2665 |
} else {
|
2666 |
+
$chart_dates['start']->addMonth( 1 );
|
|
|
|
|
|
|
|
|
2667 |
}
|
|
|
|
|
2668 |
}
|
2669 |
|
|
|
|
|
2670 |
return array(
|
2671 |
+
'customers' => array_values( $customers ),
|
2672 |
);
|
2673 |
},
|
2674 |
'type' => 'line',
|
2680 |
'backgroundColor' => 'rgba(24,126,244,0.1)',
|
2681 |
'fill' => true,
|
2682 |
'borderWidth' => 2,
|
|
|
2683 |
'pointRadius' => 4,
|
2684 |
'pointHoverRadius' => 6,
|
2685 |
'pointBackgroundColor' => 'rgb(255,255,255)',
|
includes/admin/tools.php
CHANGED
@@ -1350,6 +1350,8 @@ function edd_tools_sysinfo_get() {
|
|
1350 |
$return .= 'Language: ' . ( ! empty( $locale ) ? $locale : 'en_US' ) . "\n";
|
1351 |
$return .= 'Permalink Structure: ' . ( get_option( 'permalink_structure' ) ? get_option( 'permalink_structure' ) : 'Default' ) . "\n";
|
1352 |
$return .= 'Active Theme: ' . $theme . "\n";
|
|
|
|
|
1353 |
if ( $parent_theme !== $theme ) {
|
1354 |
$return .= 'Parent Theme: ' . $parent_theme . "\n";
|
1355 |
}
|
1350 |
$return .= 'Language: ' . ( ! empty( $locale ) ? $locale : 'en_US' ) . "\n";
|
1351 |
$return .= 'Permalink Structure: ' . ( get_option( 'permalink_structure' ) ? get_option( 'permalink_structure' ) : 'Default' ) . "\n";
|
1352 |
$return .= 'Active Theme: ' . $theme . "\n";
|
1353 |
+
$return .= 'WP Timezone: ' . wp_timezone_string() . "\n";
|
1354 |
+
$return .= 'EDD Timezone: ' . edd_get_timezone_abbr() . "\n";
|
1355 |
if ( $parent_theme !== $theme ) {
|
1356 |
$return .= 'Parent Theme: ' . $parent_theme . "\n";
|
1357 |
}
|
includes/admin/upgrades/v3/class-data-migrator.php
CHANGED
@@ -175,17 +175,39 @@ class Data_Migrator {
|
|
175 |
$args = array();
|
176 |
$meta = get_post_custom( $data->ID );
|
177 |
$meta_to_migrate = array();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
178 |
|
179 |
foreach ( $meta as $key => $value ) {
|
|
|
180 |
if ( false === strpos( $key, '_edd_discount' ) ) {
|
181 |
|
182 |
// This is custom meta from another plugin that needs to be migrated to the new meta table.
|
183 |
-
$meta_to_migrate[ $key ] =
|
|
|
|
|
|
|
|
|
|
|
184 |
continue;
|
185 |
}
|
186 |
|
187 |
-
$
|
188 |
-
$args[ str_replace( '_edd_discount_', '', $key ) ] = $value;
|
189 |
}
|
190 |
|
191 |
// If the discount name was not stored in post_meta, use value from the WP_Post object.
|
175 |
$args = array();
|
176 |
$meta = get_post_custom( $data->ID );
|
177 |
$meta_to_migrate = array();
|
178 |
+
$core_meta = array(
|
179 |
+
'code',
|
180 |
+
'name',
|
181 |
+
'status',
|
182 |
+
'uses',
|
183 |
+
'max_uses',
|
184 |
+
'amount',
|
185 |
+
'start',
|
186 |
+
'expiration',
|
187 |
+
'type',
|
188 |
+
'min_price',
|
189 |
+
'product_reqs',
|
190 |
+
'product_condition',
|
191 |
+
'excluded_products',
|
192 |
+
'is_not_global',
|
193 |
+
'is_single_use',
|
194 |
+
);
|
195 |
|
196 |
foreach ( $meta as $key => $value ) {
|
197 |
+
$value = maybe_unserialize( $value[0] );
|
198 |
if ( false === strpos( $key, '_edd_discount' ) ) {
|
199 |
|
200 |
// This is custom meta from another plugin that needs to be migrated to the new meta table.
|
201 |
+
$meta_to_migrate[ $key ] = $value;
|
202 |
+
continue;
|
203 |
+
}
|
204 |
+
$meta_key = str_replace( '_edd_discount_', '', $key );
|
205 |
+
if ( ! in_array( $meta_key, $core_meta, true ) ) {
|
206 |
+
$meta_to_migrate[ $meta_key ] = $value;
|
207 |
continue;
|
208 |
}
|
209 |
|
210 |
+
$args[ $meta_key ] = $value;
|
|
|
211 |
}
|
212 |
|
213 |
// If the discount name was not stored in post_meta, use value from the WP_Post object.
|
includes/blocks/edd-blocks.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Description: Core blocks for Easy Digital Downloads.
|
5 |
* Requires at least: 5.8
|
6 |
* Requires PHP: 7.0
|
7 |
-
* Version: 2.0.
|
8 |
* Author: Easy Digital Downloads
|
9 |
* License: GPL-2.0-or-later
|
10 |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
4 |
* Description: Core blocks for Easy Digital Downloads.
|
5 |
* Requires at least: 5.8
|
6 |
* Requires PHP: 7.0
|
7 |
+
* Version: 2.0.2
|
8 |
* Author: Easy Digital Downloads
|
9 |
* License: GPL-2.0-or-later
|
10 |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
includes/blocks/includes/checkout/checkout.php
CHANGED
@@ -287,7 +287,7 @@ function get_customer() {
|
|
287 |
)
|
288 |
);
|
289 |
|
290 |
-
if ( is_user_logged_in()
|
291 |
$user_data = get_userdata( get_current_user_id() );
|
292 |
foreach ( $customer as $key => $field ) {
|
293 |
if ( 'email' === $key && empty( $field ) ) {
|
@@ -296,8 +296,6 @@ function get_customer() {
|
|
296 |
$customer[ $key ] = $user_data->$key;
|
297 |
}
|
298 |
}
|
299 |
-
|
300 |
-
EDD()->session->set( 'customer', $customer );
|
301 |
}
|
302 |
|
303 |
return array_map( 'sanitize_text_field', $customer );
|
287 |
)
|
288 |
);
|
289 |
|
290 |
+
if ( is_user_logged_in() ) {
|
291 |
$user_data = get_userdata( get_current_user_id() );
|
292 |
foreach ( $customer as $key => $field ) {
|
293 |
if ( 'email' === $key && empty( $field ) ) {
|
296 |
$customer[ $key ] = $user_data->$key;
|
297 |
}
|
298 |
}
|
|
|
|
|
299 |
}
|
300 |
|
301 |
return array_map( 'sanitize_text_field', $customer );
|
includes/blocks/includes/checkout/forms.php
CHANGED
@@ -17,12 +17,13 @@ defined( 'ABSPATH' ) || exit;
|
|
17 |
* Gets the array of personal info forms for the checkout form.
|
18 |
*
|
19 |
* @since 2.0
|
20 |
-
* @param array $block_attributes
|
|
|
21 |
* @return array
|
22 |
*/
|
23 |
-
function get_personal_info_forms( $block_attributes ) {
|
24 |
$forms = array();
|
25 |
-
if ( is_user_logged_in() ) {
|
26 |
return $forms;
|
27 |
}
|
28 |
$options = array(
|
@@ -39,18 +40,26 @@ function get_personal_info_forms( $block_attributes ) {
|
|
39 |
'view' => EDD_BLOCKS_DIR . 'views/checkout/purchase-form/personal-info.php',
|
40 |
),
|
41 |
);
|
42 |
-
if ( ! edd_no_guest_checkout() ) {
|
43 |
$forms['guest'] = $options['guest'];
|
44 |
}
|
45 |
if ( ! empty( $block_attributes['show_register_form'] ) ) {
|
46 |
-
|
|
|
47 |
$forms['login'] = $options['login'];
|
48 |
$forms['register'] = $options['register'];
|
49 |
-
} elseif (
|
50 |
-
$forms[
|
|
|
|
|
51 |
}
|
52 |
}
|
53 |
|
|
|
|
|
|
|
|
|
|
|
54 |
return $forms;
|
55 |
}
|
56 |
|
@@ -62,15 +71,20 @@ function get_personal_info_forms( $block_attributes ) {
|
|
62 |
* @return void
|
63 |
*/
|
64 |
function do_personal_info_forms( $block_attributes ) {
|
65 |
-
$customer
|
|
|
66 |
if ( is_user_logged_in() ) {
|
67 |
include EDD_BLOCKS_DIR . 'views/checkout/purchase-form/logged-in.php';
|
68 |
-
|
|
|
|
|
|
|
|
|
69 |
}
|
70 |
?>
|
71 |
<div class="edd-blocks__checkout-user">
|
72 |
<?php
|
73 |
-
$forms = get_personal_info_forms( $block_attributes );
|
74 |
if ( ! empty( $forms ) && count( $forms ) > 1 ) {
|
75 |
$i = 0;
|
76 |
echo '<div class="edd-blocks__checkout-forms">';
|
17 |
* Gets the array of personal info forms for the checkout form.
|
18 |
*
|
19 |
* @since 2.0
|
20 |
+
* @param array $block_attributes The block attributes.
|
21 |
+
* @param bool $customer_info_complete Whether the logged in customer information is complete.
|
22 |
* @return array
|
23 |
*/
|
24 |
+
function get_personal_info_forms( $block_attributes, $customer_info_complete = true ) {
|
25 |
$forms = array();
|
26 |
+
if ( is_user_logged_in() && $customer_info_complete ) {
|
27 |
return $forms;
|
28 |
}
|
29 |
$options = array(
|
40 |
'view' => EDD_BLOCKS_DIR . 'views/checkout/purchase-form/personal-info.php',
|
41 |
),
|
42 |
);
|
43 |
+
if ( ! edd_no_guest_checkout() || ( ! $customer_info_complete && is_user_logged_in() ) ) {
|
44 |
$forms['guest'] = $options['guest'];
|
45 |
}
|
46 |
if ( ! empty( $block_attributes['show_register_form'] ) ) {
|
47 |
+
$setting = $block_attributes['show_register_form'];
|
48 |
+
if ( 'both' === $setting ) {
|
49 |
$forms['login'] = $options['login'];
|
50 |
$forms['register'] = $options['register'];
|
51 |
+
} elseif ( 'registration' === $setting ) {
|
52 |
+
$forms['register'] = $options['register'];
|
53 |
+
} elseif ( ! empty( $options[ $setting ] ) ) {
|
54 |
+
$forms[ $setting ] = $options[ $setting ];
|
55 |
}
|
56 |
}
|
57 |
|
58 |
+
// If no forms have been set, add the registration form (guest checkout is disabled).
|
59 |
+
if ( empty( $forms ) ) {
|
60 |
+
$forms['register'] = $options['register'];
|
61 |
+
}
|
62 |
+
|
63 |
return $forms;
|
64 |
}
|
65 |
|
71 |
* @return void
|
72 |
*/
|
73 |
function do_personal_info_forms( $block_attributes ) {
|
74 |
+
$customer = \EDD\Blocks\Checkout\get_customer();
|
75 |
+
$customer_info_complete = true;
|
76 |
if ( is_user_logged_in() ) {
|
77 |
include EDD_BLOCKS_DIR . 'views/checkout/purchase-form/logged-in.php';
|
78 |
+
|
79 |
+
if ( ! empty( $customer['email'] ) && ! empty( $customer['first_name'] ) ) {
|
80 |
+
return;
|
81 |
+
}
|
82 |
+
$customer_info_complete = false;
|
83 |
}
|
84 |
?>
|
85 |
<div class="edd-blocks__checkout-user">
|
86 |
<?php
|
87 |
+
$forms = get_personal_info_forms( $block_attributes, $customer_info_complete );
|
88 |
if ( ! empty( $forms ) && count( $forms ) > 1 ) {
|
89 |
$i = 0;
|
90 |
echo '<div class="edd-blocks__checkout-forms">';
|
includes/blocks/includes/orders/functions.php
CHANGED
@@ -91,10 +91,11 @@ function get_order_history_args( $block_attributes ) {
|
|
91 |
$number = (int) $block_attributes['number'];
|
92 |
$current_page = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1;
|
93 |
$args = array(
|
94 |
-
'user_id'
|
95 |
-
'type'
|
96 |
-
'number'
|
97 |
-
'offset'
|
|
|
98 |
);
|
99 |
if ( ! empty( $block_attributes['recurring'] ) ) {
|
100 |
$args['status__not_in'] = array( 'edd_subscription' );
|
91 |
$number = (int) $block_attributes['number'];
|
92 |
$current_page = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1;
|
93 |
$args = array(
|
94 |
+
'user_id' => get_current_user_id(),
|
95 |
+
'type' => 'sale',
|
96 |
+
'number' => $number,
|
97 |
+
'offset' => $number * ( intval( $current_page ) - 1 ),
|
98 |
+
'status__not_in' => array( 'trash' )
|
99 |
);
|
100 |
if ( ! empty( $block_attributes['recurring'] ) ) {
|
101 |
$args['status__not_in'] = array( 'edd_subscription' );
|
includes/blocks/includes/orders/orders.php
CHANGED
@@ -253,7 +253,7 @@ function show_no_access_message( $order ) {
|
|
253 |
'<p>%s</p>',
|
254 |
esc_html__( 'Please log in to view your order.', 'easy-digital-downloads' )
|
255 |
);
|
256 |
-
echo \EDD\Blocks\Forms\login( array( '
|
257 |
}
|
258 |
|
259 |
/**
|
253 |
'<p>%s</p>',
|
254 |
esc_html__( 'Please log in to view your order.', 'easy-digital-downloads' )
|
255 |
);
|
256 |
+
echo \EDD\Blocks\Forms\login( array( 'redirect' => edd_get_receipt_page_uri( $order->id ) ) );
|
257 |
}
|
258 |
|
259 |
/**
|
includes/blocks/views/checkout/purchase-form/logged-in.php
CHANGED
@@ -3,6 +3,12 @@ if ( function_exists( 'EDD_CFM' ) ) {
|
|
3 |
return;
|
4 |
}
|
5 |
?>
|
6 |
-
|
7 |
-
<input type="hidden" name="
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
3 |
return;
|
4 |
}
|
5 |
?>
|
6 |
+
<?php if ( ! empty( $customer['email'] ) ) : ?>
|
7 |
+
<input type="hidden" name="edd_email" id="edd-email" value="<?php echo esc_attr( $customer['email'] ); ?>" required/>
|
8 |
+
<?php endif; ?>
|
9 |
+
<?php if ( ! empty( $customer['first_name'] ) ) : ?>
|
10 |
+
<input type="hidden" name="edd_first" id="edd-first" value="<?php echo esc_attr( $customer['first_name'] ); ?>"/>
|
11 |
+
<?php endif; ?>
|
12 |
+
<?php if ( ! empty( $customer['last_name'] ) ) : ?>
|
13 |
+
<input type="hidden" name="edd_last" id="edd-last" value="<?php echo esc_attr( $customer['last_name'] ); ?>"/>
|
14 |
+
<?php endif; ?>
|
includes/blocks/views/checkout/purchase-form/personal-info.php
CHANGED
@@ -5,38 +5,44 @@ if ( function_exists( 'EDD_CFM' ) ) {
|
|
5 |
?>
|
6 |
<fieldset id="edd_checkout_user_info" class="edd-blocks-form">
|
7 |
<legend><?php esc_html_e( 'Personal Info', 'easy-digital-downloads' ); ?></legend>
|
8 |
-
|
9 |
-
<
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
?>
|
14 |
-
</label>
|
15 |
-
<input class="edd-input required" type="email" name="edd_email" placeholder="<?php esc_html_e( 'Email address', 'easy-digital-downloads' ); ?>" id="edd-email" value="<?php echo esc_attr( $customer['email'] ); ?>" aria-describedby="edd-email-description" required/>
|
16 |
-
<p class="edd-description" id="edd-email-description"><?php esc_html_e( 'We will send the purchase receipt to this address.', 'easy-digital-downloads' ); ?></p>
|
17 |
-
</div>
|
18 |
-
<div id="edd-first-name-wrap">
|
19 |
-
<label class="edd-label" for="edd-first">
|
20 |
-
<?php
|
21 |
-
esc_html_e( 'First name', 'easy-digital-downloads' );
|
22 |
-
if ( edd_field_is_required( 'edd_first' ) ) {
|
23 |
echo EDD()->html->show_required();
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
<
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
42 |
</fieldset>
|
5 |
?>
|
6 |
<fieldset id="edd_checkout_user_info" class="edd-blocks-form">
|
7 |
<legend><?php esc_html_e( 'Personal Info', 'easy-digital-downloads' ); ?></legend>
|
8 |
+
<?php if ( empty( $customer['email'] ) ) : ?>
|
9 |
+
<div id="edd-email-wrap">
|
10 |
+
<label class="edd-label" for="edd-email">
|
11 |
+
<?php
|
12 |
+
esc_html_e( 'Email address', 'easy-digital-downloads' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
echo EDD()->html->show_required();
|
14 |
+
?>
|
15 |
+
</label>
|
16 |
+
<input class="edd-input required" type="email" name="edd_email" placeholder="<?php esc_html_e( 'Email address', 'easy-digital-downloads' ); ?>" id="edd-email" value="<?php echo esc_attr( $customer['email'] ); ?>" aria-describedby="edd-email-description" required/>
|
17 |
+
<p class="edd-description" id="edd-email-description"><?php esc_html_e( 'We will send the purchase receipt to this address.', 'easy-digital-downloads' ); ?></p>
|
18 |
+
</div>
|
19 |
+
<?php endif; ?>
|
20 |
+
<?php if ( empty( $customer['first_name'] ) ) : ?>
|
21 |
+
<div id="edd-first-name-wrap">
|
22 |
+
<label class="edd-label" for="edd-first">
|
23 |
+
<?php
|
24 |
+
esc_html_e( 'First name', 'easy-digital-downloads' );
|
25 |
+
if ( edd_field_is_required( 'edd_first' ) ) {
|
26 |
+
echo EDD()->html->show_required();
|
27 |
+
}
|
28 |
+
?>
|
29 |
+
</label>
|
30 |
+
<input class="edd-input required" type="text" name="edd_first" placeholder="<?php esc_html_e( 'First name', 'easy-digital-downloads' ); ?>" id="edd-first" value="<?php echo esc_attr( $customer['first_name'] ); ?>" aria-describedby="edd-first-description" <?php EDD\Blocks\Functions\mark_field_required( 'edd_first' ); ?>/>
|
31 |
+
<p class="edd-description" id="edd-first-description"><?php esc_html_e( 'We will use this to personalize your account experience.', 'easy-digital-downloads' ); ?></p>
|
32 |
+
</div>
|
33 |
+
<?php endif; ?>
|
34 |
+
<?php if ( empty( $customer['last_name'] ) ) : ?>
|
35 |
+
<div id="edd-last-name-wrap">
|
36 |
+
<label class="edd-label" for="edd-last">
|
37 |
+
<?php
|
38 |
+
esc_html_e( 'Last name', 'easy-digital-downloads' );
|
39 |
+
if ( edd_field_is_required( 'edd_last' ) ) {
|
40 |
+
echo EDD()->html->show_required();
|
41 |
+
}
|
42 |
+
?>
|
43 |
+
</label>
|
44 |
+
<input class="edd-input" type="text" name="edd_last" id="edd-last" placeholder="<?php esc_html_e( 'Last name', 'easy-digital-downloads' ); ?>" value="<?php echo esc_attr( $customer['last_name'] ); ?>" aria-describedby="edd-last-description" <?php EDD\Blocks\Functions\mark_field_required( 'edd_last' ); ?>/>
|
45 |
+
<p class="edd-description" id="edd-last-description"><?php esc_html_e( 'We will use this as well to personalize your account experience.', 'easy-digital-downloads' ); ?></p>
|
46 |
+
</div>
|
47 |
+
<?php endif; ?>
|
48 |
</fieldset>
|
includes/class-easy-digital-downloads.php
CHANGED
@@ -325,7 +325,7 @@ final class Easy_Digital_Downloads {
|
|
325 |
|
326 |
// Plugin version.
|
327 |
if ( ! defined( 'EDD_VERSION' ) ) {
|
328 |
-
define( 'EDD_VERSION', '3.1.0.
|
329 |
}
|
330 |
|
331 |
// Plugin Root File.
|
325 |
|
326 |
// Plugin version.
|
327 |
if ( ! defined( 'EDD_VERSION' ) ) {
|
328 |
+
define( 'EDD_VERSION', '3.1.0.3' );
|
329 |
}
|
330 |
|
331 |
// Plugin Root File.
|
includes/class-edd-cli.php
CHANGED
@@ -893,6 +893,12 @@ class EDD_CLI extends WP_CLI_Command {
|
|
893 |
? true
|
894 |
: false;
|
895 |
|
|
|
|
|
|
|
|
|
|
|
|
|
896 |
$upgrade_completed = edd_has_upgrade_completed( 'migrate_discounts' );
|
897 |
|
898 |
if ( ! $force && $upgrade_completed ) {
|
@@ -908,6 +914,9 @@ class EDD_CLI extends WP_CLI_Command {
|
|
908 |
$progress = new \cli\progress\Bar( 'Migrating Discounts', $total );
|
909 |
|
910 |
foreach ( $results as $result ) {
|
|
|
|
|
|
|
911 |
\EDD\Admin\Upgrades\v3\Data_Migrator::discounts( $result );
|
912 |
|
913 |
$progress->tick();
|
893 |
? true
|
894 |
: false;
|
895 |
|
896 |
+
$destroy = (bool) ( $force && isset( $assoc_args['destroy'] ) );
|
897 |
+
|
898 |
+
if ( $destroy ) {
|
899 |
+
WP_CLI::confirm( __( 'This process will remove and recreate discounts in your database. Please make sure you\'ve backed up your EDD database tables. Are you sure you want to delete discounts that have already been migrated and run the migration again?', 'easy-digital-downloads' ) );
|
900 |
+
}
|
901 |
+
|
902 |
$upgrade_completed = edd_has_upgrade_completed( 'migrate_discounts' );
|
903 |
|
904 |
if ( ! $force && $upgrade_completed ) {
|
914 |
$progress = new \cli\progress\Bar( 'Migrating Discounts', $total );
|
915 |
|
916 |
foreach ( $results as $result ) {
|
917 |
+
if ( $destroy ) {
|
918 |
+
edd_delete_discount( $result->ID );
|
919 |
+
}
|
920 |
\EDD\Admin\Upgrades\v3\Data_Migrator::discounts( $result );
|
921 |
|
922 |
$progress->tick();
|
includes/class-edd-download.php
CHANGED
@@ -873,7 +873,7 @@ class EDD_Download {
|
|
873 |
public function can_purchase() {
|
874 |
$can_purchase = true;
|
875 |
|
876 |
-
if ( ! current_user_can( 'edit_post', $this->ID )
|
877 |
$can_purchase = false;
|
878 |
}
|
879 |
|
873 |
public function can_purchase() {
|
874 |
$can_purchase = true;
|
875 |
|
876 |
+
if ( 'publish' !== $this->post_status && ! current_user_can( 'edit_post', $this->ID ) ) {
|
877 |
$can_purchase = false;
|
878 |
}
|
879 |
|
includes/compat-functions.php
CHANGED
@@ -71,3 +71,32 @@ if ( ! function_exists( 'getallheaders' ) ) :
|
|
71 |
return $headers;
|
72 |
}
|
73 |
endif;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
71 |
return $headers;
|
72 |
}
|
73 |
endif;
|
74 |
+
|
75 |
+
if ( ! function_exists( 'wp_timezone_string' ) ) :
|
76 |
+
/**
|
77 |
+
* Polyfill for wp_timezone_string() function added in WP 5.3.0
|
78 |
+
*
|
79 |
+
* Retrieves the timezone of the site as a string.
|
80 |
+
*
|
81 |
+
* @since 3.1.0.3
|
82 |
+
* @return string PHP timezone name or a ±HH:MM offset.
|
83 |
+
*/
|
84 |
+
function wp_timezone_string() {
|
85 |
+
$timezone_string = get_option( 'timezone_string' );
|
86 |
+
|
87 |
+
if ( $timezone_string ) {
|
88 |
+
return $timezone_string;
|
89 |
+
}
|
90 |
+
|
91 |
+
$offset = (float) get_option( 'gmt_offset' );
|
92 |
+
$hours = (int) $offset;
|
93 |
+
$minutes = ( $offset - $hours );
|
94 |
+
|
95 |
+
$sign = ( $offset < 0 ) ? '-' : '+';
|
96 |
+
$abs_hour = abs( $hours );
|
97 |
+
$abs_mins = abs( $minutes * 60 );
|
98 |
+
$tz_offset = sprintf( '%s%02d:%02d', $sign, $abs_hour, $abs_mins );
|
99 |
+
|
100 |
+
return $tz_offset;
|
101 |
+
}
|
102 |
+
endif;
|
includes/deprecated-functions.php
CHANGED
@@ -1934,3 +1934,185 @@ function edd_plugin_row_meta( $links = array(), $file = '' ) {
|
|
1934 |
_edd_deprecated_function( __FUNCTION__, '3.1' );
|
1935 |
return $links;
|
1936 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1934 |
_edd_deprecated_function( __FUNCTION__, '3.1' );
|
1935 |
return $links;
|
1936 |
}
|
1937 |
+
|
1938 |
+
/**
|
1939 |
+
* Listens to the updated_postmeta hook for our backwards compatible payment_meta updates, and runs through them
|
1940 |
+
*
|
1941 |
+
* Previously hooked into: updated_postmeta
|
1942 |
+
*
|
1943 |
+
* @since 2.3
|
1944 |
+
* @deprecated 3.1.0.3
|
1945 |
+
* @param int $meta_id The Meta ID that was updated
|
1946 |
+
* @param int $object_id The Object ID that was updated (post ID)
|
1947 |
+
* @param string $meta_key The Meta key that was updated
|
1948 |
+
* @param string|int|float $meta_value The Value being updated
|
1949 |
+
* @return bool|int If successful the number of rows updated, if it fails, false
|
1950 |
+
*/
|
1951 |
+
function edd_update_payment_backwards_compat( $meta_id, $object_id, $meta_key, $meta_value ) {
|
1952 |
+
|
1953 |
+
_edd_deprecated_function( __FUNCTION__, '3.1.0.3' );
|
1954 |
+
|
1955 |
+
$meta_keys = array( '_edd_payment_meta', '_edd_payment_tax' );
|
1956 |
+
|
1957 |
+
if ( ! in_array( $meta_key, $meta_keys ) ) {
|
1958 |
+
return;
|
1959 |
+
}
|
1960 |
+
|
1961 |
+
global $wpdb;
|
1962 |
+
switch( $meta_key ) {
|
1963 |
+
|
1964 |
+
case '_edd_payment_meta':
|
1965 |
+
$meta_value = maybe_unserialize( $meta_value );
|
1966 |
+
|
1967 |
+
if( ! isset( $meta_value['tax'] ) ){
|
1968 |
+
return;
|
1969 |
+
}
|
1970 |
+
|
1971 |
+
$tax_value = $meta_value['tax'];
|
1972 |
+
|
1973 |
+
$data = array( 'meta_value' => $tax_value );
|
1974 |
+
$where = array( 'post_id' => $object_id, 'meta_key' => '_edd_payment_tax' );
|
1975 |
+
$data_format = array( '%f' );
|
1976 |
+
$where_format = array( '%d', '%s' );
|
1977 |
+
break;
|
1978 |
+
|
1979 |
+
case '_edd_payment_tax':
|
1980 |
+
$tax_value = ! empty( $meta_value ) ? $meta_value : 0;
|
1981 |
+
$current_meta = edd_get_payment_meta( $object_id, '_edd_payment_meta', true );
|
1982 |
+
|
1983 |
+
$current_meta['tax'] = $tax_value;
|
1984 |
+
$new_meta = maybe_serialize( $current_meta );
|
1985 |
+
|
1986 |
+
$data = array( 'meta_value' => $new_meta );
|
1987 |
+
$where = array( 'post_id' => $object_id, 'meta_key' => '_edd_payment_meta' );
|
1988 |
+
$data_format = array( '%s' );
|
1989 |
+
$where_format = array( '%d', '%s' );
|
1990 |
+
|
1991 |
+
break;
|
1992 |
+
|
1993 |
+
}
|
1994 |
+
|
1995 |
+
$updated = $wpdb->update( $wpdb->postmeta, $data, $where, $data_format, $where_format );
|
1996 |
+
|
1997 |
+
if ( ! empty( $updated ) ) {
|
1998 |
+
// Since we did a direct DB query, clear the postmeta cache.
|
1999 |
+
wp_cache_delete( $object_id, 'post_meta' );
|
2000 |
+
}
|
2001 |
+
|
2002 |
+
return $updated;
|
2003 |
+
|
2004 |
+
}
|
2005 |
+
|
2006 |
+
/**
|
2007 |
+
* Deletes edd_stats_ transients that have expired to prevent database clogs
|
2008 |
+
*
|
2009 |
+
* Previously hooked into: edd_daily_scheduled_events
|
2010 |
+
*
|
2011 |
+
* @since 2.6.7
|
2012 |
+
* @deprecated 3.1.0.3
|
2013 |
+
* @return void
|
2014 |
+
*/
|
2015 |
+
function edd_cleanup_stats_transients() {
|
2016 |
+
|
2017 |
+
_edd_deprecated_function( __FUNCTION__, '3.1.0.3' );
|
2018 |
+
|
2019 |
+
global $wpdb;
|
2020 |
+
|
2021 |
+
if ( defined( 'WP_SETUP_CONFIG' ) ) {
|
2022 |
+
return;
|
2023 |
+
}
|
2024 |
+
|
2025 |
+
if ( defined( 'WP_INSTALLING' ) ) {
|
2026 |
+
return;
|
2027 |
+
}
|
2028 |
+
|
2029 |
+
$now = current_time( 'timestamp' );
|
2030 |
+
$transients = $wpdb->get_results( "SELECT option_name, option_value FROM $wpdb->options WHERE option_name LIKE '%\_transient_timeout\_edd\_stats\_%' AND option_value+0 < $now LIMIT 0, 200;" );
|
2031 |
+
$to_delete = array();
|
2032 |
+
|
2033 |
+
if( ! empty( $transients ) ) {
|
2034 |
+
|
2035 |
+
foreach( $transients as $transient ) {
|
2036 |
+
|
2037 |
+
$to_delete[] = $transient->option_name;
|
2038 |
+
$to_delete[] = str_replace( '_timeout', '', $transient->option_name );
|
2039 |
+
|
2040 |
+
}
|
2041 |
+
|
2042 |
+
}
|
2043 |
+
|
2044 |
+
if ( ! empty( $to_delete ) ) {
|
2045 |
+
|
2046 |
+
$option_names = implode( "','", $to_delete );
|
2047 |
+
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name IN ('$option_names')" );
|
2048 |
+
|
2049 |
+
}
|
2050 |
+
|
2051 |
+
}
|
2052 |
+
|
2053 |
+
/**
|
2054 |
+
* Updates all old payments, prior to 1.2, with new
|
2055 |
+
* meta for the total purchase amount
|
2056 |
+
*
|
2057 |
+
* This is so that payments can be queried by their totals
|
2058 |
+
*
|
2059 |
+
* Prevsiouly hooked into: edd_upgrade_payments
|
2060 |
+
*
|
2061 |
+
* @since 1.2
|
2062 |
+
* @deprecated 3.1.0.3
|
2063 |
+
* @param array $data Arguments passed
|
2064 |
+
* @return void
|
2065 |
+
*/
|
2066 |
+
function edd_update_old_payments_with_totals( $data ) {
|
2067 |
+
_edd_deprecated_function( __FUNCTION__, '3.1.0.3' );
|
2068 |
+
|
2069 |
+
if ( ! wp_verify_nonce( $data['_wpnonce'], 'edd_upgrade_payments_nonce' ) ) {
|
2070 |
+
return;
|
2071 |
+
}
|
2072 |
+
|
2073 |
+
if ( get_option( 'edd_payment_totals_upgraded' ) ) {
|
2074 |
+
return;
|
2075 |
+
}
|
2076 |
+
|
2077 |
+
$payments = edd_get_payments( array(
|
2078 |
+
'offset' => 0,
|
2079 |
+
'number' => 9999999,
|
2080 |
+
'mode' => 'all',
|
2081 |
+
) );
|
2082 |
+
|
2083 |
+
if ( $payments ) {
|
2084 |
+
foreach ( $payments as $payment ) {
|
2085 |
+
|
2086 |
+
$payment = new EDD_Payment( $payment->ID );
|
2087 |
+
$meta = $payment->get_meta();
|
2088 |
+
|
2089 |
+
$payment->total = $meta['amount'];
|
2090 |
+
$payment->save();
|
2091 |
+
}
|
2092 |
+
}
|
2093 |
+
|
2094 |
+
add_option( 'edd_payment_totals_upgraded', 1 );
|
2095 |
+
}
|
2096 |
+
|
2097 |
+
/**
|
2098 |
+
* Flushes the current user's purchase history transient when a payment status
|
2099 |
+
* is updated
|
2100 |
+
*
|
2101 |
+
* Previously hooked into: edd_update_payment_status
|
2102 |
+
*
|
2103 |
+
* @since 1.2.2
|
2104 |
+
* @deprecated 3.1.0.3
|
2105 |
+
* @param int $payment_id the ID number of the payment
|
2106 |
+
* @param string $new_status the status of the payment, probably "publish"
|
2107 |
+
* @param string $old_status the status of the payment prior to being marked as "complete", probably "pending"
|
2108 |
+
*/
|
2109 |
+
function edd_clear_user_history_cache( $payment_id, $new_status, $old_status ) {
|
2110 |
+
|
2111 |
+
_edd_deprecated_function( __FUNCTION__, '3.1.0.3' );
|
2112 |
+
|
2113 |
+
$payment = new EDD_Payment( $payment_id );
|
2114 |
+
|
2115 |
+
if( ! empty( $payment->user_id ) ) {
|
2116 |
+
delete_transient( 'edd_user_' . $payment->user_id . '_purchases' );
|
2117 |
+
}
|
2118 |
+
}
|
includes/discount-functions.php
CHANGED
@@ -58,7 +58,7 @@ function edd_add_discount( $data = array() ) {
|
|
58 |
}
|
59 |
|
60 |
if ( is_array( $product_requirements ) ) {
|
61 |
-
foreach ( $product_requirements as $product_requirement ) {
|
62 |
edd_add_adjustment_meta( $discount_id, 'product_requirement', $product_requirement );
|
63 |
}
|
64 |
}
|
@@ -71,7 +71,7 @@ function edd_add_discount( $data = array() ) {
|
|
71 |
}
|
72 |
|
73 |
if ( is_array( $excluded_products ) ) {
|
74 |
-
foreach ( $excluded_products as $excluded_product ) {
|
75 |
edd_add_adjustment_meta( $discount_id, 'excluded_product', $excluded_product );
|
76 |
}
|
77 |
}
|
@@ -1120,9 +1120,13 @@ function edd_get_item_discount_amount( $item, $items, $discounts, $item_unit_pri
|
|
1120 |
$items_amount = 0;
|
1121 |
|
1122 |
foreach ( $items as $i ) {
|
|
|
1123 |
if ( ! in_array( $i['id'], $excluded_products ) ) {
|
|
|
|
|
1124 |
if ( edd_has_variable_prices( $i['id'] ) ) {
|
1125 |
-
$
|
|
|
1126 |
} else {
|
1127 |
$i_amount = edd_get_download_price( $i['id'] );
|
1128 |
}
|
58 |
}
|
59 |
|
60 |
if ( is_array( $product_requirements ) ) {
|
61 |
+
foreach ( array_filter( $product_requirements ) as $product_requirement ) {
|
62 |
edd_add_adjustment_meta( $discount_id, 'product_requirement', $product_requirement );
|
63 |
}
|
64 |
}
|
71 |
}
|
72 |
|
73 |
if ( is_array( $excluded_products ) ) {
|
74 |
+
foreach ( array_filter( $excluded_products ) as $excluded_product ) {
|
75 |
edd_add_adjustment_meta( $discount_id, 'excluded_product', $excluded_product );
|
76 |
}
|
77 |
}
|
1120 |
$items_amount = 0;
|
1121 |
|
1122 |
foreach ( $items as $i ) {
|
1123 |
+
|
1124 |
if ( ! in_array( $i['id'], $excluded_products ) ) {
|
1125 |
+
$i_amount = 0;
|
1126 |
+
|
1127 |
if ( edd_has_variable_prices( $i['id'] ) ) {
|
1128 |
+
$price_id = isset( $i['options']['price_id'] ) ? $i['options']['price_id'] : $i['item_number']['options']['price_id'];
|
1129 |
+
$i_amount = edd_get_price_option_amount( $i['id'], $price_id );
|
1130 |
} else {
|
1131 |
$i_amount = edd_get_download_price( $i['id'] );
|
1132 |
}
|
includes/emails/template.php
CHANGED
@@ -234,13 +234,18 @@ function edd_get_sale_notification_body_content( $payment_id = 0, $payment_data
|
|
234 |
*
|
235 |
* @since 1.5
|
236 |
* @author Sunny Ratilal
|
|
|
237 |
*/
|
238 |
-
function edd_render_receipt_in_browser() {
|
239 |
-
if ( ! isset( $
|
240 |
wp_die( __( 'Missing purchase key.', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ) );
|
241 |
}
|
242 |
|
243 |
-
$
|
|
|
|
|
|
|
|
|
244 |
|
245 |
ob_start();
|
246 |
|
@@ -254,15 +259,41 @@ function edd_render_receipt_in_browser() {
|
|
254 |
<!DOCTYPE html>
|
255 |
<html lang="en">
|
256 |
<head>
|
257 |
-
<title><?php
|
258 |
<meta charset="utf-8" />
|
259 |
<meta name="robots" content="noindex, nofollow" />
|
260 |
<?php wp_head(); ?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
261 |
</head>
|
262 |
-
<body class="<?php echo apply_filters('edd_receipt_page_body_class', 'edd_receipt_page' ); ?>">
|
263 |
<div id="edd_receipt_wrapper">
|
264 |
<?php do_action( 'edd_render_receipt_in_browser_before' ); ?>
|
265 |
-
<?php echo do_shortcode('[edd_receipt payment_key='. $key .']'); ?>
|
266 |
<?php do_action( 'edd_render_receipt_in_browser_after' ); ?>
|
267 |
</div>
|
268 |
<?php wp_footer(); ?>
|
234 |
*
|
235 |
* @since 1.5
|
236 |
* @author Sunny Ratilal
|
237 |
+
* @param array $data The request data.
|
238 |
*/
|
239 |
+
function edd_render_receipt_in_browser( $data ) {
|
240 |
+
if ( ! isset( $data['payment_key'] ) ) {
|
241 |
wp_die( __( 'Missing purchase key.', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ) );
|
242 |
}
|
243 |
|
244 |
+
if ( ! empty( $_POST['edd_action'] ) && ! empty( $_POST['edd_user_login'] ) && ! empty( $_POST['edd_login_nonce'] ) ) {
|
245 |
+
return;
|
246 |
+
}
|
247 |
+
|
248 |
+
$key = urlencode( $data['payment_key'] );
|
249 |
|
250 |
ob_start();
|
251 |
|
259 |
<!DOCTYPE html>
|
260 |
<html lang="en">
|
261 |
<head>
|
262 |
+
<title><?php esc_html_e( 'Receipt', 'easy-digital-downloads' ); ?></title>
|
263 |
<meta charset="utf-8" />
|
264 |
<meta name="robots" content="noindex, nofollow" />
|
265 |
<?php wp_head(); ?>
|
266 |
+
<style>
|
267 |
+
body.edd_receipt_page {
|
268 |
+
margin: 12px auto;
|
269 |
+
align-items: center;
|
270 |
+
border: 1px solid #cfcfcf;
|
271 |
+
max-width: fit-content;
|
272 |
+
padding: 12px 24px;
|
273 |
+
border-radius: 8px;
|
274 |
+
}
|
275 |
+
|
276 |
+
.edd_receipt_page #edd_login_form fieldset {
|
277 |
+
border: none;
|
278 |
+
display: grid;
|
279 |
+
}
|
280 |
+
|
281 |
+
.edd_receipt_page #edd_login_form label,
|
282 |
+
.edd_receipt_page #edd_login_form input[type=text],
|
283 |
+
.edd_receipt_page #edd_login_form input[type=password]{
|
284 |
+
display: block;
|
285 |
+
width: 100%;
|
286 |
+
}
|
287 |
+
|
288 |
+
.edd_receipt_page th {
|
289 |
+
text-align: left;
|
290 |
+
}
|
291 |
+
</style>
|
292 |
</head>
|
293 |
+
<body class="<?php echo esc_attr( apply_filters( 'edd_receipt_page_body_class', 'edd_receipt_page' ) ); ?>">
|
294 |
<div id="edd_receipt_wrapper">
|
295 |
<?php do_action( 'edd_render_receipt_in_browser_before' ); ?>
|
296 |
+
<?php echo do_shortcode( '[edd_receipt payment_key=' . $key . ']' ); ?>
|
297 |
<?php do_action( 'edd_render_receipt_in_browser_after' ); ?>
|
298 |
</div>
|
299 |
<?php wp_footer(); ?>
|
includes/gateways/paypal/admin/connect.php
CHANGED
@@ -30,7 +30,6 @@ if ( ! defined( 'EDD_PAYPAL_PARTNER_CONNECT_URL' ) ) {
|
|
30 |
function connect_settings_field() {
|
31 |
$is_connected = PayPal\has_rest_api_connection();
|
32 |
$mode = edd_is_test_mode() ? __( 'sandbox', 'easy-digital-downloads' ) : __( 'live', 'easy-digital-downloads' );
|
33 |
-
|
34 |
ob_start();
|
35 |
|
36 |
if ( ! $is_connected ) {
|
@@ -81,9 +80,7 @@ function connect_settings_field() {
|
|
81 |
<span class="spinner is-active"></span>
|
82 |
</p>
|
83 |
</div>
|
84 |
-
<div id="edd-paypal-disconnect">
|
85 |
-
<a href="<?php echo esc_url( get_disconnect_url() ); ?>"><?php esc_html_e( 'Disconnect from PayPal', 'easy-digital-downloads' ); ?></a>
|
86 |
-
</div>
|
87 |
<?php
|
88 |
}
|
89 |
?>
|
@@ -152,6 +149,46 @@ function process_connect() {
|
|
152 |
|
153 |
add_action( 'wp_ajax_edd_paypal_commerce_connect', __NAMESPACE__ . '\process_connect' );
|
154 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
155 |
/**
|
156 |
* Retrieves partner Connect details for the given mode.
|
157 |
*
|
@@ -163,7 +200,6 @@ function get_partner_details( $mode = '' ) {
|
|
163 |
if ( ! $mode ) {
|
164 |
$mode = edd_is_test_mode() ? API::MODE_SANDBOX : API::MODE_LIVE;
|
165 |
}
|
166 |
-
|
167 |
return json_decode( get_option( 'edd_paypal_commerce_connect_details_' . $mode ) );
|
168 |
}
|
169 |
|
@@ -300,6 +336,11 @@ function get_account_info() {
|
|
300 |
'webhook' => '<button type="button" class="button edd-paypal-connect-action" data-nonce="' . esc_attr( wp_create_nonce( 'edd_update_paypal_webhook' ) ) . '" data-action="edd_paypal_commerce_update_webhook">' . esc_html__( 'Sync Webhook', 'easy-digital-downloads' ) . '</button>'
|
301 |
);
|
302 |
|
|
|
|
|
|
|
|
|
|
|
303 |
$validator = new AccountStatusValidator();
|
304 |
$validator->check();
|
305 |
|
@@ -372,9 +413,11 @@ function get_account_info() {
|
|
372 |
$webhook_message .= $validator->errors_for_webhook->get_error_message();
|
373 |
|
374 |
if ( in_array( 'webhook_missing', $validator->errors_for_webhook->get_error_codes() ) ) {
|
375 |
-
$
|
|
|
376 |
}
|
377 |
} else {
|
|
|
378 |
$webhook_dashicon = 'yes';
|
379 |
$webhook_message .= __( 'Webhook successfully configured for the following events:', 'easy-digital-downloads' );
|
380 |
}
|
@@ -411,10 +454,11 @@ function get_account_info() {
|
|
411 |
}
|
412 |
|
413 |
wp_send_json_success( array(
|
414 |
-
'status'
|
415 |
-
'account_status'
|
416 |
-
'webhook_object'
|
417 |
-
'actions'
|
|
|
418 |
) );
|
419 |
} catch ( \Exception $e ) {
|
420 |
wp_send_json_error( array(
|
@@ -444,6 +488,24 @@ function get_disconnect_url() {
|
|
444 |
);
|
445 |
}
|
446 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
447 |
/**
|
448 |
* Disconnects from PayPal in the current mode.
|
449 |
*
|
@@ -467,6 +529,54 @@ function process_disconnect() {
|
|
467 |
try {
|
468 |
// Disconnect the webhook.
|
469 |
// This is in another try/catch because we want to delete the token cache (below) even if this fails.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
470 |
PayPal\Webhooks\delete_webhook( $mode );
|
471 |
} catch ( \Exception $e ) {
|
472 |
|
@@ -478,6 +588,9 @@ function process_disconnect() {
|
|
478 |
|
479 |
}
|
480 |
|
|
|
|
|
|
|
481 |
// Delete API credentials.
|
482 |
$edd_settings_to_delete = array(
|
483 |
'paypal_' . $mode . '_client_id',
|
@@ -487,17 +600,11 @@ function process_disconnect() {
|
|
487 |
edd_delete_option( $option_name );
|
488 |
}
|
489 |
|
490 |
-
// Delete merchant information.
|
491 |
-
delete_option( 'edd_paypal_' . $mode . '_merchant_details' );
|
492 |
-
|
493 |
-
// Delete partner connect information.
|
494 |
-
delete_option( 'edd_paypal_commerce_connect_details_' . $mode );
|
495 |
-
|
496 |
wp_safe_redirect( esc_url_raw( get_settings_url() ) );
|
497 |
exit;
|
498 |
}
|
499 |
|
500 |
-
add_action( '
|
501 |
|
502 |
/**
|
503 |
* AJAX callback for refreshing payment status.
|
30 |
function connect_settings_field() {
|
31 |
$is_connected = PayPal\has_rest_api_connection();
|
32 |
$mode = edd_is_test_mode() ? __( 'sandbox', 'easy-digital-downloads' ) : __( 'live', 'easy-digital-downloads' );
|
|
|
33 |
ob_start();
|
34 |
|
35 |
if ( ! $is_connected ) {
|
80 |
<span class="spinner is-active"></span>
|
81 |
</p>
|
82 |
</div>
|
83 |
+
<div id="edd-paypal-disconnect"></div>
|
|
|
|
|
84 |
<?php
|
85 |
}
|
86 |
?>
|
149 |
|
150 |
add_action( 'wp_ajax_edd_paypal_commerce_connect', __NAMESPACE__ . '\process_connect' );
|
151 |
|
152 |
+
/**
|
153 |
+
* AJAX handler for processing the PayPal Reconnect.
|
154 |
+
*
|
155 |
+
* @since 3.1.0.3
|
156 |
+
* @return void
|
157 |
+
*/
|
158 |
+
function process_reconnect() {
|
159 |
+
// This validates the nonce.
|
160 |
+
check_ajax_referer( 'edd_process_paypal_connect' );
|
161 |
+
|
162 |
+
if ( ! current_user_can( 'manage_options' ) ) {
|
163 |
+
wp_send_json_error( __( 'You do not have permission to perform this action.', 'easy-digital-downloads' ) );
|
164 |
+
}
|
165 |
+
|
166 |
+
$mode = edd_is_test_mode() ? API::MODE_SANDBOX : API::MODE_LIVE;
|
167 |
+
|
168 |
+
/**
|
169 |
+
* Make sure we still have connection details from the previously connected site.
|
170 |
+
*/
|
171 |
+
$connection_details = get_option( 'edd_paypal_commerce_connect_details_' . $mode );
|
172 |
+
|
173 |
+
if ( empty( $connection_details ) ) {
|
174 |
+
// Somehow we ended up here, but now that we're in an invalid state, remove all settings so we can fully reset.
|
175 |
+
delete_option( 'edd_paypal_commerce_connect_details_' . $mode );
|
176 |
+
delete_option( 'edd_paypal_commerce_webhook_id_' . $mode );
|
177 |
+
delete_option( 'edd_paypal_' . $mode . '_merchant_details' );
|
178 |
+
wp_send_json_error( __( 'Failure reconnecting to PayPal. Please try again', 'easy-digital-downloads' ) );
|
179 |
+
}
|
180 |
+
|
181 |
+
try {
|
182 |
+
PayPal\Webhooks\create_webhook( $mode );
|
183 |
+
} catch ( \Exception $e ) {
|
184 |
+
$message = esc_html__( 'Your account has been successfully reconnected, but an error occurred while creating a webhook.', 'easy-digital-downloads' );
|
185 |
+
}
|
186 |
+
|
187 |
+
wp_safe_redirect( esc_url_raw( get_settings_url() ) );
|
188 |
+
}
|
189 |
+
|
190 |
+
add_action( 'wp_ajax_edd_paypal_commerce_reconnect', __NAMESPACE__ . '\process_reconnect' );
|
191 |
+
|
192 |
/**
|
193 |
* Retrieves partner Connect details for the given mode.
|
194 |
*
|
200 |
if ( ! $mode ) {
|
201 |
$mode = edd_is_test_mode() ? API::MODE_SANDBOX : API::MODE_LIVE;
|
202 |
}
|
|
|
203 |
return json_decode( get_option( 'edd_paypal_commerce_connect_details_' . $mode ) );
|
204 |
}
|
205 |
|
336 |
'webhook' => '<button type="button" class="button edd-paypal-connect-action" data-nonce="' . esc_attr( wp_create_nonce( 'edd_update_paypal_webhook' ) ) . '" data-action="edd_paypal_commerce_update_webhook">' . esc_html__( 'Sync Webhook', 'easy-digital-downloads' ) . '</button>'
|
337 |
);
|
338 |
|
339 |
+
$disconnect_links = array(
|
340 |
+
'disconnect' => '<a class="button-secondary" id="edd-paypal-disconnect-link" href="' . esc_url( get_disconnect_url() ) . '">' . __( "Disconnect webhooks from PayPal", "easy-digital-downloads" ) . '</a>',
|
341 |
+
'delete' => '<a class="button-secondary" id="edd-paypal-delete-link" href="' . esc_url( get_delete_url() ) . '">' . __( "Delete connection with PayPal", "easy-digital-downloads" ) . '</a>',
|
342 |
+
);
|
343 |
+
|
344 |
$validator = new AccountStatusValidator();
|
345 |
$validator->check();
|
346 |
|
413 |
$webhook_message .= $validator->errors_for_webhook->get_error_message();
|
414 |
|
415 |
if ( in_array( 'webhook_missing', $validator->errors_for_webhook->get_error_codes() ) ) {
|
416 |
+
unset( $disconnect_links['disconnect'] );
|
417 |
+
$actions['webhook'] = '<button type="button" class="button edd-paypal-connect-action" data-nonce="' . esc_attr( wp_create_nonce( 'edd_create_paypal_webhook' ) ) . '" data-action="edd_paypal_commerce_create_webhook">' . esc_html__( 'Create Webhooks', 'easy-digital-downloads' ) . '</button>';
|
418 |
}
|
419 |
} else {
|
420 |
+
unset( $disconnect_links['delete'] );
|
421 |
$webhook_dashicon = 'yes';
|
422 |
$webhook_message .= __( 'Webhook successfully configured for the following events:', 'easy-digital-downloads' );
|
423 |
}
|
454 |
}
|
455 |
|
456 |
wp_send_json_success( array(
|
457 |
+
'status' => $status,
|
458 |
+
'account_status' => '<ul class="edd-paypal-account-status">' . $account_status . '</ul>',
|
459 |
+
'webhook_object' => isset( $validator ) ? $validator->webhook : null,
|
460 |
+
'actions' => array_values( $actions ),
|
461 |
+
'disconnect_links' => array_values( $disconnect_links ),
|
462 |
) );
|
463 |
} catch ( \Exception $e ) {
|
464 |
wp_send_json_error( array(
|
488 |
);
|
489 |
}
|
490 |
|
491 |
+
/**
|
492 |
+
* Returns the URL for deleting the app PayPal Commerce.
|
493 |
+
*
|
494 |
+
* @since 3.1.0.3
|
495 |
+
* @return string
|
496 |
+
*/
|
497 |
+
function get_delete_url() {
|
498 |
+
return wp_nonce_url(
|
499 |
+
add_query_arg(
|
500 |
+
array(
|
501 |
+
'edd_action' => 'delete_paypal_commerce'
|
502 |
+
),
|
503 |
+
admin_url()
|
504 |
+
),
|
505 |
+
'edd_delete_paypal_commerce'
|
506 |
+
);
|
507 |
+
}
|
508 |
+
|
509 |
/**
|
510 |
* Disconnects from PayPal in the current mode.
|
511 |
*
|
529 |
try {
|
530 |
// Disconnect the webhook.
|
531 |
// This is in another try/catch because we want to delete the token cache (below) even if this fails.
|
532 |
+
// This only deletes the webhooks in PayPal, we do not remove the webhook ID in EDD until we delete the connection.
|
533 |
+
PayPal\Webhooks\delete_webhook( $mode );
|
534 |
+
} catch ( \Exception $e ) {
|
535 |
+
|
536 |
+
}
|
537 |
+
|
538 |
+
// Also delete the token cache key, to ensure we fetch a fresh one if they connect to a different account later.
|
539 |
+
delete_option( $api->token_cache_key );
|
540 |
+
} catch ( \Exception $e ) {
|
541 |
+
|
542 |
+
}
|
543 |
+
|
544 |
+
wp_safe_redirect( esc_url_raw( get_settings_url() ) );
|
545 |
+
exit;
|
546 |
+
}
|
547 |
+
|
548 |
+
add_action( 'edd_disconnect_paypal_commerce', __NAMESPACE__ . '\process_disconnect' );
|
549 |
+
|
550 |
+
/**
|
551 |
+
* Fully deletes past Merchant Information from PayPal in the current mode.
|
552 |
+
*
|
553 |
+
* @since 3.1.0.3
|
554 |
+
* @return void
|
555 |
+
*/
|
556 |
+
function process_delete() {
|
557 |
+
if ( ! current_user_can( 'manage_options' ) ) {
|
558 |
+
wp_die( esc_html__( 'You do not have permission to perform this action.', 'easy-digital-downloads' ), esc_html__( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
559 |
+
}
|
560 |
+
|
561 |
+
if ( empty( $_GET['_wpnonce'] ) || ! wp_verify_nonce( $_GET['_wpnonce'], 'edd_delete_paypal_commerce' ) ) {
|
562 |
+
wp_die( esc_html__( 'You do not have permission to perform this action.', 'easy-digital-downloads' ), esc_html__( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
563 |
+
}
|
564 |
+
|
565 |
+
$mode = edd_is_test_mode() ? PayPal\API::MODE_SANDBOX : PayPal\API::MODE_LIVE;
|
566 |
+
|
567 |
+
// Delete merchant information.
|
568 |
+
delete_option( 'edd_paypal_' . $mode . '_merchant_details' );
|
569 |
+
|
570 |
+
// Delete partner connect information.
|
571 |
+
delete_option( 'edd_paypal_commerce_connect_details_' . $mode );
|
572 |
+
|
573 |
+
try {
|
574 |
+
$api = new PayPal\API();
|
575 |
+
|
576 |
+
try {
|
577 |
+
// Disconnect the webhook.
|
578 |
+
// This is in another try/catch because we want to delete the token cache (below) even if this fails.
|
579 |
+
// This only deletes the webhooks in PayPal, we do not remove the webhook ID in EDD until we delete the connection.
|
580 |
PayPal\Webhooks\delete_webhook( $mode );
|
581 |
} catch ( \Exception $e ) {
|
582 |
|
588 |
|
589 |
}
|
590 |
|
591 |
+
// Now delete our webhook ID.
|
592 |
+
delete_option( sanitize_key( 'edd_paypal_commerce_webhook_id_' . $mode ) );
|
593 |
+
|
594 |
// Delete API credentials.
|
595 |
$edd_settings_to_delete = array(
|
596 |
'paypal_' . $mode . '_client_id',
|
600 |
edd_delete_option( $option_name );
|
601 |
}
|
602 |
|
|
|
|
|
|
|
|
|
|
|
|
|
603 |
wp_safe_redirect( esc_url_raw( get_settings_url() ) );
|
604 |
exit;
|
605 |
}
|
606 |
|
607 |
+
add_action( 'edd_delete_paypal_commerce', __NAMESPACE__ . '\process_delete' );
|
608 |
|
609 |
/**
|
610 |
* AJAX callback for refreshing payment status.
|
includes/gateways/paypal/ipn.php
ADDED
@@ -0,0 +1,405 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* IPN Functions
|
4 |
+
*
|
5 |
+
* This serves as a fallback for the webhooks in the event that the app becomes disconnected.
|
6 |
+
*
|
7 |
+
* @package easy-digital-downloads
|
8 |
+
* @subpackage Gateways\PayPal\Webhooks
|
9 |
+
* @copyright Copyright (c) 2021, Sandhills Development, LLC
|
10 |
+
* @license GPL2+
|
11 |
+
* @since 2.11
|
12 |
+
*/
|
13 |
+
|
14 |
+
namespace EDD\Gateways\PayPal\IPN;
|
15 |
+
|
16 |
+
/**
|
17 |
+
* Listens for an IPN call from PayPal
|
18 |
+
*
|
19 |
+
* This is intended to be a 'backup' listener, for if the webhook is no longer connected for a specific PayPal object.
|
20 |
+
*
|
21 |
+
* @since 3.1.0.3
|
22 |
+
*/
|
23 |
+
function listen_for_ipn() {
|
24 |
+
if ( empty( $_GET['edd-listener'] ) || 'eppe' !== $_GET['edd-listener'] ) {
|
25 |
+
return;
|
26 |
+
}
|
27 |
+
|
28 |
+
ipn_debug_log( 'IPN Backup Loaded' );
|
29 |
+
|
30 |
+
// Moving this up in the load order so we can check some things before even getting to verification.
|
31 |
+
$posted = $_POST;
|
32 |
+
$ignored_txn_types = array( 'recurring_payment_profile_created' );
|
33 |
+
|
34 |
+
if ( isset( $posted['txn_type'] ) && in_array( $posted['txn_type'], $ignored_txn_types ) ) {
|
35 |
+
ipn_debug_log( 'Transaction Type ' . $posted['txn_type'] . ' is ignored by the PayPal Commerce IPN.' );
|
36 |
+
return;
|
37 |
+
}
|
38 |
+
|
39 |
+
nocache_headers();
|
40 |
+
|
41 |
+
$verified = false;
|
42 |
+
|
43 |
+
// Set initial post data to empty string.
|
44 |
+
$post_data = '';
|
45 |
+
|
46 |
+
// Fallback just in case post_max_size is lower than needed.
|
47 |
+
if ( ini_get( 'allow_url_fopen' ) ) {
|
48 |
+
$post_data = file_get_contents( 'php://input' );
|
49 |
+
} else {
|
50 |
+
// If allow_url_fopen is not enabled, then make sure that post_max_size is large enough.
|
51 |
+
ini_set( 'post_max_size', '12M' );
|
52 |
+
}
|
53 |
+
|
54 |
+
// Start the encoded data collection with notification command.
|
55 |
+
$encoded_data = 'cmd=_notify-validate';
|
56 |
+
|
57 |
+
// Get current arg separator.
|
58 |
+
$arg_separator = edd_get_php_arg_separator_output();
|
59 |
+
|
60 |
+
// Verify there is a post_data.
|
61 |
+
if ( $post_data || strlen( $post_data ) > 0 ) {
|
62 |
+
|
63 |
+
// Append the data.
|
64 |
+
$encoded_data .= $arg_separator . $post_data;
|
65 |
+
|
66 |
+
} else {
|
67 |
+
|
68 |
+
// Check if POST is empty.
|
69 |
+
if ( empty( $_POST ) ) {
|
70 |
+
|
71 |
+
// Nothing to do.
|
72 |
+
ipn_debug_log( 'post data not detected, bailing' );
|
73 |
+
return;
|
74 |
+
|
75 |
+
} else {
|
76 |
+
|
77 |
+
// Loop through each POST.
|
78 |
+
foreach ( $_POST as $key => $value ) {
|
79 |
+
|
80 |
+
// Encode the value and append the data.
|
81 |
+
$encoded_data .= $arg_separator . "$key=" . urlencode( $value );
|
82 |
+
|
83 |
+
}
|
84 |
+
|
85 |
+
}
|
86 |
+
|
87 |
+
}
|
88 |
+
|
89 |
+
// Convert collected post data to an array.
|
90 |
+
parse_str( $encoded_data, $encoded_data_array );
|
91 |
+
|
92 |
+
// We're always going to validate the IPN here...
|
93 |
+
if ( ! edd_is_test_mode() ) {
|
94 |
+
|
95 |
+
ipn_debug_log( 'preparing to verify IPN data' );
|
96 |
+
|
97 |
+
// Validate the IPN.
|
98 |
+
$remote_post_vars = array(
|
99 |
+
'method' => 'POST',
|
100 |
+
'timeout' => 45,
|
101 |
+
'redirection' => 5,
|
102 |
+
'httpversion' => '1.1',
|
103 |
+
'blocking' => true,
|
104 |
+
'body' => $encoded_data_array,
|
105 |
+
'headers' => array(
|
106 |
+
'host' => 'www.paypal.com',
|
107 |
+
'connection' => 'close',
|
108 |
+
'content-type' => 'application/x-www-form-urlencoded',
|
109 |
+
'post' => '/cgi-bin/webscr HTTP/1.1',
|
110 |
+
|
111 |
+
),
|
112 |
+
);
|
113 |
+
|
114 |
+
// Get response.
|
115 |
+
$api_response = wp_remote_post( edd_get_paypal_redirect(), $remote_post_vars );
|
116 |
+
$body = wp_remote_retrieve_body( $api_response );
|
117 |
+
|
118 |
+
if ( is_wp_error( $api_response ) ) {
|
119 |
+
/* Translators: %s - IPN Verification response */
|
120 |
+
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid PayPal Commerce/Express IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
121 |
+
ipn_debug_log( 'verification failed. Data: ' . var_export( $body, true ) );
|
122 |
+
status_header( 401 );
|
123 |
+
return; // Something went wrong.
|
124 |
+
}
|
125 |
+
|
126 |
+
if ( 'VERIFIED' !== $body ) {
|
127 |
+
/* Translators: %s - IPN Verification response */
|
128 |
+
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid PayPal Commerce/Express IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
129 |
+
ipn_debug_log( 'verification failed. Data: ' . var_export( $body, true ) );
|
130 |
+
status_header( 401 );
|
131 |
+
return; // Response not okay.
|
132 |
+
}
|
133 |
+
|
134 |
+
// We've verified that the IPN Check passed, we can proceed with processing the IPN data sent to us.
|
135 |
+
$verified = true;
|
136 |
+
|
137 |
+
}
|
138 |
+
|
139 |
+
/**
|
140 |
+
* The processIpn() method returned true if the IPN was "VERIFIED" and false if it was "INVALID".
|
141 |
+
*/
|
142 |
+
if ( ( $verified || edd_get_option( 'disable_paypal_verification' ) ) || isset( $_POST['verification_override'] ) || edd_is_test_mode() ) {
|
143 |
+
|
144 |
+
status_header( 200 );
|
145 |
+
|
146 |
+
/**
|
147 |
+
* Note: Amounts get more properly sanitized on insert.
|
148 |
+
*
|
149 |
+
* @see EDD_Subscription::add_payment()
|
150 |
+
*/
|
151 |
+
if ( isset( $posted['amount'] ) ) {
|
152 |
+
$amount = (float) $posted['amount'];
|
153 |
+
} elseif ( isset( $posted['mc_gross'] ) ) {
|
154 |
+
$amount = (float) $posted['mc_gross'];
|
155 |
+
} else {
|
156 |
+
$amount = 0;
|
157 |
+
}
|
158 |
+
|
159 |
+
$txn_type = isset( $posted['txn_type'] ) ? strtolower( $posted['txn_type'] ) : '';
|
160 |
+
$payment_status = isset( $posted['payment_status'] ) ? strtolower( $posted['payment_status'] ) : '';
|
161 |
+
$currency_code = isset( $posted['mc_currency'] ) ? $posted['mc_currency'] : $posted['currency_code'];
|
162 |
+
$transaction_id = isset( $posted['txn_id'] ) ? $posted['txn_id'] : '';
|
163 |
+
|
164 |
+
if ( empty( $txn_type ) && empty( $payment_status ) ) {
|
165 |
+
ipn_debug_log( 'No txn_type or payment_status in the IPN, bailing' );
|
166 |
+
return;
|
167 |
+
}
|
168 |
+
|
169 |
+
// Process webhooks from recurring first, as that is where most of the missing actions will come from.
|
170 |
+
if ( class_exists( 'EDD_Recurring' ) && isset( $posted['recurring_payment_id'] ) ) {
|
171 |
+
$posted = apply_filters( 'edd_recurring_ipn_post', $_POST ); // allow $_POST to be modified.
|
172 |
+
|
173 |
+
$subscription = new \EDD_Subscription( $posted['recurring_payment_id'], true );
|
174 |
+
|
175 |
+
|
176 |
+
// Bail if this is the very first payment.
|
177 |
+
if ( date( 'Y-n-d', strtotime( $subscription->created ) ) == date( 'Y-n-d', strtotime( $posted['payment_date'] ) ) ) {
|
178 |
+
ipn_debug_log( 'IPN for subscription ' . $subscription->id . ': processing stopped because this is the initial payment.' );
|
179 |
+
return;
|
180 |
+
}
|
181 |
+
|
182 |
+
$parent_payment = edd_get_payment( $subscription->parent_payment_id );
|
183 |
+
if ( 'paypal_commerce' !== $parent_payment->gateway ) {
|
184 |
+
ipn_debug_log( 'This is not for PayPal Commerce - bailing' );
|
185 |
+
return;
|
186 |
+
}
|
187 |
+
|
188 |
+
if ( empty( $subscription->id ) || $subscription->id < 1 ) {
|
189 |
+
ipn_debug_log( 'no matching subscription found detected, bailing. Data: ' . var_export( $posted, true ) );
|
190 |
+
die( 'No subscription found' );
|
191 |
+
}
|
192 |
+
|
193 |
+
ipn_debug_log( 'Processing ' . $txn_type . ' IPN for subscription ' . $subscription->id );
|
194 |
+
|
195 |
+
// Subscriptions.
|
196 |
+
switch ( $txn_type ) :
|
197 |
+
|
198 |
+
case 'recurring_payment':
|
199 |
+
case 'recurring_payment_outstanding_payment':
|
200 |
+
$transaction_exists = edd_get_order_transaction_by( 'transaction_id', $transaction_id );
|
201 |
+
if ( ! empty( $transaction_exists ) ) {
|
202 |
+
ipn_debug_log( 'Transaction ID ' . $transaction_id . ' arlready processed.' );
|
203 |
+
return;
|
204 |
+
}
|
205 |
+
|
206 |
+
$sub_currency = edd_get_payment_currency_code( $subscription->parent_payment_id );
|
207 |
+
|
208 |
+
// verify details.
|
209 |
+
if ( ! empty( $sub_currency ) && strtolower( $currency_code ) != strtolower( $sub_currency ) ) {
|
210 |
+
|
211 |
+
// the currency code is invalid
|
212 |
+
// @TODO: Does this need a parent_id for better error organization?
|
213 |
+
/* Translators: %s - The payment data sent via the IPN */
|
214 |
+
edd_record_gateway_error( __( 'Invalid Currency Code', 'easy-digital-downloads' ), sprintf( __( 'The currency code in an IPN request did not match the site currency code. Payment data: %s', 'easy-digital-downloads' ), json_encode( $posted ) ) );
|
215 |
+
|
216 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': invalid currency code detected in IPN data: ' . var_export( $posted, true ) );
|
217 |
+
|
218 |
+
die( 'invalid currency code' );
|
219 |
+
|
220 |
+
}
|
221 |
+
|
222 |
+
if ( 'failed' === $payment_status ) {
|
223 |
+
if ( 'failing' === $subscription->status ) {
|
224 |
+
ipn_debug_log( 'Subscription ID ' . $subscription->id . ' arlready failing.' );
|
225 |
+
return;
|
226 |
+
}
|
227 |
+
|
228 |
+
$transaction_link = '<a href="https://www.paypal.com/activity/payment/' . $transaction_id . '" target="_blank">' . $transaction_id . '</a>';
|
229 |
+
/* Translators: %s - The transaction ID of the failed payment */
|
230 |
+
$subscription->add_note( sprintf( __( 'Transaction ID %s failed in PayPal', 'easy-digital-downloads' ), $transaction_link ) );
|
231 |
+
$subscription->failing();
|
232 |
+
|
233 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': payment failed in PayPal' );
|
234 |
+
|
235 |
+
die( 'Subscription payment failed' );
|
236 |
+
|
237 |
+
}
|
238 |
+
|
239 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': preparing to insert renewal payment' );
|
240 |
+
|
241 |
+
// when a user makes a recurring payment.
|
242 |
+
$payment_id = $subscription->add_payment(
|
243 |
+
array(
|
244 |
+
'amount' => $amount,
|
245 |
+
'transaction_id' => $transaction_id,
|
246 |
+
)
|
247 |
+
);
|
248 |
+
|
249 |
+
if ( ! empty( $payment_id ) ) {
|
250 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': renewal payment was recorded successfully, preparing to renew subscription' );
|
251 |
+
$subscription->renew( $payment_id );
|
252 |
+
|
253 |
+
if ( 'recurring_payment_outstanding_payment' === $txn_type ) {
|
254 |
+
/* Translators: %s - The collected outstanding balance of the subscription */
|
255 |
+
$subscription->add_note( sprintf( __( 'Outstanding subscription balance of %s collected successfully.', 'easy-digital-downloads' ), $amount ) );
|
256 |
+
}
|
257 |
+
} else {
|
258 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': renewal payment creation appeared to fail.' );
|
259 |
+
}
|
260 |
+
|
261 |
+
die( 'Subscription payment successful' );
|
262 |
+
|
263 |
+
break;
|
264 |
+
|
265 |
+
case 'recurring_payment_profile_cancel':
|
266 |
+
case 'recurring_payment_suspended':
|
267 |
+
case 'recurring_payment_suspended_due_to_max_failed_payment':
|
268 |
+
if ( 'cancelled' === $subscription->status ) {
|
269 |
+
ipn_debug_log( 'Subscription ID ' . $subscription->id . ' arlready cancelled.' );
|
270 |
+
return;
|
271 |
+
}
|
272 |
+
|
273 |
+
$subscription->cancel();
|
274 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': subscription cancelled.' );
|
275 |
+
|
276 |
+
|
277 |
+
die( 'Subscription cancelled' );
|
278 |
+
|
279 |
+
break;
|
280 |
+
|
281 |
+
case 'recurring_payment_failed':
|
282 |
+
if ( 'failing' === $subscription->status ) {
|
283 |
+
ipn_debug_log( 'Subscription ID ' . $subscription->id . ' arlready failing.' );
|
284 |
+
return;
|
285 |
+
}
|
286 |
+
|
287 |
+
$subscription->failing();
|
288 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': subscription failing.' );
|
289 |
+
do_action( 'edd_recurring_payment_failed', $subscription );
|
290 |
+
|
291 |
+
break;
|
292 |
+
|
293 |
+
case 'recurring_payment_expired':
|
294 |
+
if ( 'completed' === $subscription->status ) {
|
295 |
+
ipn_debug_log( 'Subscription ID ' . $subscription->id . ' arlready completed.' );
|
296 |
+
return;
|
297 |
+
}
|
298 |
+
|
299 |
+
$subscription->complete();
|
300 |
+
ipn_debug_log( 'subscription ' . $subscription->id . ': subscription completed.' );
|
301 |
+
|
302 |
+
die( 'Subscription completed' );
|
303 |
+
break;
|
304 |
+
|
305 |
+
endswitch;
|
306 |
+
}
|
307 |
+
|
308 |
+
// We've processed recurring, now let's handle non-recurring IPNs.
|
309 |
+
|
310 |
+
// First, if this isn't a refund or reversal, we don't need to process anything.
|
311 |
+
$statuses_to_process = array( 'refunded', 'reversed' );
|
312 |
+
if ( ! in_array( $payment_status, $statuses_to_process, true ) ) {
|
313 |
+
ipn_debug_log( 'Payment Status was not a status we need to process: ' . $payment_status );
|
314 |
+
return;
|
315 |
+
}
|
316 |
+
|
317 |
+
$order_id = 0;
|
318 |
+
|
319 |
+
if ( ! empty( $posted['parent_txn_id'] ) ) {
|
320 |
+
$order_id = edd_get_order_id_from_transaction_id( $posted['parent_txn_id'] );
|
321 |
+
}
|
322 |
+
|
323 |
+
/**
|
324 |
+
* This section of the IPN should only affect processing refunds or returns on orders made previous, not new
|
325 |
+
* orders, so we can just look for the parent_txn_id, and if it's not here, bail as this is a new order that
|
326 |
+
* should be handeled with webhooks.
|
327 |
+
*/
|
328 |
+
if ( empty( $order_id ) ) {
|
329 |
+
ipn_debug_log( 'IPN Track ID ' . $posted['ipn_track_id'] . ' does not need to be processed as it does not belong to an existing record.' );
|
330 |
+
return;
|
331 |
+
}
|
332 |
+
|
333 |
+
$order = edd_get_order( $order_id );
|
334 |
+
if ( 'paypal_commerce' !== $order->gateway ) {
|
335 |
+
ipn_debug_log( 'Order ' . $order_id . ' was not with PayPal Commerce' );
|
336 |
+
return;
|
337 |
+
}
|
338 |
+
|
339 |
+
if ( 'refunded' === $order->status ) {
|
340 |
+
ipn_debug_log( 'Order ' . $order_id . ' is already refunded' );
|
341 |
+
}
|
342 |
+
|
343 |
+
$transaction_exists = edd_get_order_transaction_by( 'transaction_id', $transaction_id );
|
344 |
+
if ( ! empty( $transaction_exists ) ) {
|
345 |
+
ipn_debug_log( 'Refund transaction for ' . $transaction_id . ' already exists' );
|
346 |
+
return;
|
347 |
+
}
|
348 |
+
|
349 |
+
$order_amount = edd_get_payment_amount( $order->id );
|
350 |
+
$refunded_amount = ! empty( $amount ) ? $amount : $order_amount;
|
351 |
+
$currency = ! empty( $currency_code ) ? $currency_code : $order->currency;
|
352 |
+
|
353 |
+
ipn_debug_log( 'Processing a refund for original transaction ' . $order->get_transaction_id() );
|
354 |
+
|
355 |
+
/* Translators: %1$s - Amount refunded; %2$s - Original payment ID; %3$s - Refund transaction ID */
|
356 |
+
$payment_note = sprintf(
|
357 |
+
esc_html__( 'Amount: %1$s; Payment transaction ID: %2$s; Refund transaction ID: %3$s', 'easy-digital-downloads' ),
|
358 |
+
edd_currency_filter( edd_format_amount( $refunded_amount ), $currency ),
|
359 |
+
esc_html( $order->get_transaction_id() ),
|
360 |
+
esc_html( $transaction_id )
|
361 |
+
);
|
362 |
+
|
363 |
+
// Partial refund.
|
364 |
+
if ( (float) $refunded_amount < (float) $order_amount ) {
|
365 |
+
edd_add_note(
|
366 |
+
array(
|
367 |
+
'object_type' => 'order',
|
368 |
+
'object_id' => $order->id,
|
369 |
+
'content' => __( 'Partial refund processed in PayPal.', 'easy-digital-downloads' ) . ' ' . $payment_note,
|
370 |
+
)
|
371 |
+
);
|
372 |
+
edd_update_order_status( $order->id, 'partially_refunded' );
|
373 |
+
} else {
|
374 |
+
// Full refund.
|
375 |
+
edd_add_note(
|
376 |
+
array(
|
377 |
+
'object_type' => 'order',
|
378 |
+
'object_id' => $order->id,
|
379 |
+
'content' => __( 'Full refund processed in PayPal.', 'easy-digital-downloads' ) . ' ' . $payment_note,
|
380 |
+
)
|
381 |
+
);
|
382 |
+
edd_update_order_status( $order->id, 'refunded' );
|
383 |
+
}
|
384 |
+
|
385 |
+
die( 'Refund processed' );
|
386 |
+
} else {
|
387 |
+
ipn_debug_log( 'verification failed, bailing.' );
|
388 |
+
status_header( 400 );
|
389 |
+
die( 'invalid IPN' );
|
390 |
+
|
391 |
+
}
|
392 |
+
}
|
393 |
+
add_action( 'init', __NAMESPACE__ . '\listen_for_ipn' );
|
394 |
+
|
395 |
+
/**
|
396 |
+
* Helper method to prefix any calls to edd_debug_log
|
397 |
+
*
|
398 |
+
* @since 3.1.0.3
|
399 |
+
* @uses edd_debug_log
|
400 |
+
*
|
401 |
+
* @param string $message The message to send to the debug logging.
|
402 |
+
*/
|
403 |
+
function ipn_debug_log( $message ) {
|
404 |
+
edd_debug_log( 'PayPal Commerce IPN: ' . $message );
|
405 |
+
}
|
includes/gateways/paypal/paypal.php
CHANGED
@@ -69,6 +69,7 @@ require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/webhooks/events/class-pa
|
|
69 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/webhooks/events/class-payment-capture-denied.php';
|
70 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php';
|
71 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/integrations.php';
|
|
|
72 |
|
73 |
if ( is_admin() ) {
|
74 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/admin/connect.php';
|
69 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/webhooks/events/class-payment-capture-denied.php';
|
70 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php';
|
71 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/integrations.php';
|
72 |
+
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/ipn.php';
|
73 |
|
74 |
if ( is_admin() ) {
|
75 |
require_once EDD_PLUGIN_DIR . 'includes/gateways/paypal/admin/connect.php';
|
includes/gateways/paypal/webhooks/functions.php
CHANGED
@@ -221,11 +221,17 @@ function get_webhook_details( $mode = '' ) {
|
|
221 |
$api = new API( $mode );
|
222 |
$response = $api->make_request( 'v1/notifications/webhooks/' . urlencode( $webhook_id ), array(), array(), 'GET' );
|
223 |
if ( 200 !== $api->last_response_code ) {
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
229 |
}
|
230 |
|
231 |
if ( empty( $response->id ) ) {
|
@@ -262,9 +268,6 @@ function delete_webhook( $mode = '' ) {
|
|
262 |
|
263 |
$api->make_request( 'v1/notifications/webhooks/' . urlencode( $webhook_id ), array(), array(), 'DELETE' );
|
264 |
|
265 |
-
// Delete the webhook ID.
|
266 |
-
delete_option( $webhook_name );
|
267 |
-
|
268 |
if ( 204 !== $api->last_response_code ) {
|
269 |
throw new API_Exception( sprintf(
|
270 |
/* Translators: %d - HTTP response code. */
|
221 |
$api = new API( $mode );
|
222 |
$response = $api->make_request( 'v1/notifications/webhooks/' . urlencode( $webhook_id ), array(), array(), 'GET' );
|
223 |
if ( 200 !== $api->last_response_code ) {
|
224 |
+
if ( 404 === $api->last_response_code ) {
|
225 |
+
throw new API_Exception(
|
226 |
+
__( 'Your store is currently not receiving webhook notifications, create the webhooks to reconnect.', 'easy-digital-downloads' )
|
227 |
+
);
|
228 |
+
} else {
|
229 |
+
throw new API_Exception( sprintf(
|
230 |
+
/* Translators: %d - HTTP response code. */
|
231 |
+
__( 'Invalid response code %d while retrieving webhook details.', 'easy-digital-downloads' ),
|
232 |
+
$api->last_response_code
|
233 |
+
) );
|
234 |
+
}
|
235 |
}
|
236 |
|
237 |
if ( empty( $response->id ) ) {
|
268 |
|
269 |
$api->make_request( 'v1/notifications/webhooks/' . urlencode( $webhook_id ), array(), array(), 'DELETE' );
|
270 |
|
|
|
|
|
|
|
271 |
if ( 204 !== $api->last_response_code ) {
|
272 |
throw new API_Exception( sprintf(
|
273 |
/* Translators: %d - HTTP response code. */
|
includes/gateways/stripe/vendor/autoload.php
CHANGED
@@ -3,10 +3,23 @@
|
|
3 |
// autoload.php @generated by Composer
|
4 |
|
5 |
if (PHP_VERSION_ID < 50600) {
|
6 |
-
|
7 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
}
|
9 |
|
10 |
require_once __DIR__ . '/composer/autoload_real.php';
|
11 |
|
12 |
-
return
|
3 |
// autoload.php @generated by Composer
|
4 |
|
5 |
if (PHP_VERSION_ID < 50600) {
|
6 |
+
if (!headers_sent()) {
|
7 |
+
header('HTTP/1.1 500 Internal Server Error');
|
8 |
+
}
|
9 |
+
$err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
|
10 |
+
if (!ini_get('display_errors')) {
|
11 |
+
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
12 |
+
fwrite(STDERR, $err);
|
13 |
+
} elseif (!headers_sent()) {
|
14 |
+
echo $err;
|
15 |
+
}
|
16 |
+
}
|
17 |
+
trigger_error(
|
18 |
+
$err,
|
19 |
+
E_USER_ERROR
|
20 |
+
);
|
21 |
}
|
22 |
|
23 |
require_once __DIR__ . '/composer/autoload_real.php';
|
24 |
|
25 |
+
return ComposerAutoloaderInita1abe13511edc0d0d2f910910593934f::getLoader();
|
includes/gateways/stripe/vendor/composer/autoload_psr4.php
CHANGED
@@ -7,5 +7,4 @@ $baseDir = dirname($vendorDir);
|
|
7 |
|
8 |
return array(
|
9 |
'Stripe\\' => array($vendorDir . '/stripe/stripe-php/lib'),
|
10 |
-
'Composer\\Installers\\' => array($vendorDir . '/composer/installers/src/Composer/Installers'),
|
11 |
);
|
7 |
|
8 |
return array(
|
9 |
'Stripe\\' => array($vendorDir . '/stripe/stripe-php/lib'),
|
|
|
10 |
);
|
includes/gateways/stripe/vendor/composer/autoload_real.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
-
class
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
@@ -22,14 +22,12 @@ class ComposerAutoloaderInitce2073d68aa3da842e5b37a3b60e999a
|
|
22 |
return self::$loader;
|
23 |
}
|
24 |
|
25 |
-
|
26 |
-
|
27 |
-
spl_autoload_register(array('ComposerAutoloaderInitce2073d68aa3da842e5b37a3b60e999a', 'loadClassLoader'), true, true);
|
28 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
29 |
-
spl_autoload_unregister(array('
|
30 |
|
31 |
require __DIR__ . '/autoload_static.php';
|
32 |
-
call_user_func(\Composer\Autoload\
|
33 |
|
34 |
$loader->register(true);
|
35 |
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
+
class ComposerAutoloaderInita1abe13511edc0d0d2f910910593934f
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
22 |
return self::$loader;
|
23 |
}
|
24 |
|
25 |
+
spl_autoload_register(array('ComposerAutoloaderInita1abe13511edc0d0d2f910910593934f', 'loadClassLoader'), true, true);
|
|
|
|
|
26 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
27 |
+
spl_autoload_unregister(array('ComposerAutoloaderInita1abe13511edc0d0d2f910910593934f', 'loadClassLoader'));
|
28 |
|
29 |
require __DIR__ . '/autoload_static.php';
|
30 |
+
call_user_func(\Composer\Autoload\ComposerStaticInita1abe13511edc0d0d2f910910593934f::getInitializer($loader));
|
31 |
|
32 |
$loader->register(true);
|
33 |
|
includes/gateways/stripe/vendor/composer/autoload_static.php
CHANGED
@@ -4,17 +4,13 @@
|
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
-
class
|
8 |
{
|
9 |
public static $prefixLengthsPsr4 = array (
|
10 |
'S' =>
|
11 |
array (
|
12 |
'Stripe\\' => 7,
|
13 |
),
|
14 |
-
'C' =>
|
15 |
-
array (
|
16 |
-
'Composer\\Installers\\' => 20,
|
17 |
-
),
|
18 |
);
|
19 |
|
20 |
public static $prefixDirsPsr4 = array (
|
@@ -22,10 +18,6 @@ class ComposerStaticInitce2073d68aa3da842e5b37a3b60e999a
|
|
22 |
array (
|
23 |
0 => __DIR__ . '/..' . '/stripe/stripe-php/lib',
|
24 |
),
|
25 |
-
'Composer\\Installers\\' =>
|
26 |
-
array (
|
27 |
-
0 => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers',
|
28 |
-
),
|
29 |
);
|
30 |
|
31 |
public static $classMap = array (
|
@@ -35,9 +27,9 @@ class ComposerStaticInitce2073d68aa3da842e5b37a3b60e999a
|
|
35 |
public static function getInitializer(ClassLoader $loader)
|
36 |
{
|
37 |
return \Closure::bind(function () use ($loader) {
|
38 |
-
$loader->prefixLengthsPsr4 =
|
39 |
-
$loader->prefixDirsPsr4 =
|
40 |
-
$loader->classMap =
|
41 |
|
42 |
}, null, ClassLoader::class);
|
43 |
}
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
+
class ComposerStaticInita1abe13511edc0d0d2f910910593934f
|
8 |
{
|
9 |
public static $prefixLengthsPsr4 = array (
|
10 |
'S' =>
|
11 |
array (
|
12 |
'Stripe\\' => 7,
|
13 |
),
|
|
|
|
|
|
|
|
|
14 |
);
|
15 |
|
16 |
public static $prefixDirsPsr4 = array (
|
18 |
array (
|
19 |
0 => __DIR__ . '/..' . '/stripe/stripe-php/lib',
|
20 |
),
|
|
|
|
|
|
|
|
|
21 |
);
|
22 |
|
23 |
public static $classMap = array (
|
27 |
public static function getInitializer(ClassLoader $loader)
|
28 |
{
|
29 |
return \Closure::bind(function () use ($loader) {
|
30 |
+
$loader->prefixLengthsPsr4 = ComposerStaticInita1abe13511edc0d0d2f910910593934f::$prefixLengthsPsr4;
|
31 |
+
$loader->prefixDirsPsr4 = ComposerStaticInita1abe13511edc0d0d2f910910593934f::$prefixDirsPsr4;
|
32 |
+
$loader->classMap = ComposerStaticInita1abe13511edc0d0d2f910910593934f::$classMap;
|
33 |
|
34 |
}, null, ClassLoader::class);
|
35 |
}
|
includes/gateways/stripe/vendor/composer/installed.json
CHANGED
@@ -1,158 +1,5 @@
|
|
1 |
{
|
2 |
"packages": [
|
3 |
-
{
|
4 |
-
"name": "composer/installers",
|
5 |
-
"version": "v1.11.0",
|
6 |
-
"version_normalized": "1.11.0.0",
|
7 |
-
"source": {
|
8 |
-
"type": "git",
|
9 |
-
"url": "https://github.com/composer/installers.git",
|
10 |
-
"reference": "ae03311f45dfe194412081526be2e003960df74b"
|
11 |
-
},
|
12 |
-
"dist": {
|
13 |
-
"type": "zip",
|
14 |
-
"url": "https://api.github.com/repos/composer/installers/zipball/ae03311f45dfe194412081526be2e003960df74b",
|
15 |
-
"reference": "ae03311f45dfe194412081526be2e003960df74b",
|
16 |
-
"shasum": ""
|
17 |
-
},
|
18 |
-
"require": {
|
19 |
-
"composer-plugin-api": "^1.0 || ^2.0"
|
20 |
-
},
|
21 |
-
"replace": {
|
22 |
-
"roundcube/plugin-installer": "*",
|
23 |
-
"shama/baton": "*"
|
24 |
-
},
|
25 |
-
"require-dev": {
|
26 |
-
"composer/composer": "1.6.* || ^2.0",
|
27 |
-
"composer/semver": "^1 || ^3",
|
28 |
-
"phpstan/phpstan": "^0.12.55",
|
29 |
-
"phpstan/phpstan-phpunit": "^0.12.16",
|
30 |
-
"symfony/phpunit-bridge": "^4.2 || ^5",
|
31 |
-
"symfony/process": "^2.3"
|
32 |
-
},
|
33 |
-
"time": "2021-04-28T06:42:17+00:00",
|
34 |
-
"type": "composer-plugin",
|
35 |
-
"extra": {
|
36 |
-
"class": "Composer\\Installers\\Plugin",
|
37 |
-
"branch-alias": {
|
38 |
-
"dev-main": "1.x-dev"
|
39 |
-
}
|
40 |
-
},
|
41 |
-
"installation-source": "dist",
|
42 |
-
"autoload": {
|
43 |
-
"psr-4": {
|
44 |
-
"Composer\\Installers\\": "src/Composer/Installers"
|
45 |
-
}
|
46 |
-
},
|
47 |
-
"notification-url": "https://packagist.org/downloads/",
|
48 |
-
"license": [
|
49 |
-
"MIT"
|
50 |
-
],
|
51 |
-
"authors": [
|
52 |
-
{
|
53 |
-
"name": "Kyle Robinson Young",
|
54 |
-
"email": "kyle@dontkry.com",
|
55 |
-
"homepage": "https://github.com/shama"
|
56 |
-
}
|
57 |
-
],
|
58 |
-
"description": "A multi-framework Composer library installer",
|
59 |
-
"homepage": "https://composer.github.io/installers/",
|
60 |
-
"keywords": [
|
61 |
-
"Craft",
|
62 |
-
"Dolibarr",
|
63 |
-
"Eliasis",
|
64 |
-
"Hurad",
|
65 |
-
"ImageCMS",
|
66 |
-
"Kanboard",
|
67 |
-
"Lan Management System",
|
68 |
-
"MODX Evo",
|
69 |
-
"MantisBT",
|
70 |
-
"Mautic",
|
71 |
-
"Maya",
|
72 |
-
"OXID",
|
73 |
-
"Plentymarkets",
|
74 |
-
"Porto",
|
75 |
-
"RadPHP",
|
76 |
-
"SMF",
|
77 |
-
"Starbug",
|
78 |
-
"Thelia",
|
79 |
-
"Whmcs",
|
80 |
-
"WolfCMS",
|
81 |
-
"agl",
|
82 |
-
"aimeos",
|
83 |
-
"annotatecms",
|
84 |
-
"attogram",
|
85 |
-
"bitrix",
|
86 |
-
"cakephp",
|
87 |
-
"chef",
|
88 |
-
"cockpit",
|
89 |
-
"codeigniter",
|
90 |
-
"concrete5",
|
91 |
-
"croogo",
|
92 |
-
"dokuwiki",
|
93 |
-
"drupal",
|
94 |
-
"eZ Platform",
|
95 |
-
"elgg",
|
96 |
-
"expressionengine",
|
97 |
-
"fuelphp",
|
98 |
-
"grav",
|
99 |
-
"installer",
|
100 |
-
"itop",
|
101 |
-
"joomla",
|
102 |
-
"known",
|
103 |
-
"kohana",
|
104 |
-
"laravel",
|
105 |
-
"lavalite",
|
106 |
-
"lithium",
|
107 |
-
"magento",
|
108 |
-
"majima",
|
109 |
-
"mako",
|
110 |
-
"mediawiki",
|
111 |
-
"miaoxing",
|
112 |
-
"modulework",
|
113 |
-
"modx",
|
114 |
-
"moodle",
|
115 |
-
"osclass",
|
116 |
-
"phpbb",
|
117 |
-
"piwik",
|
118 |
-
"ppi",
|
119 |
-
"processwire",
|
120 |
-
"puppet",
|
121 |
-
"pxcms",
|
122 |
-
"reindex",
|
123 |
-
"roundcube",
|
124 |
-
"shopware",
|
125 |
-
"silverstripe",
|
126 |
-
"sydes",
|
127 |
-
"sylius",
|
128 |
-
"symfony",
|
129 |
-
"tastyigniter",
|
130 |
-
"typo3",
|
131 |
-
"wordpress",
|
132 |
-
"yawik",
|
133 |
-
"zend",
|
134 |
-
"zikula"
|
135 |
-
],
|
136 |
-
"support": {
|
137 |
-
"issues": "https://github.com/composer/installers/issues",
|
138 |
-
"source": "https://github.com/composer/installers/tree/v1.11.0"
|
139 |
-
},
|
140 |
-
"funding": [
|
141 |
-
{
|
142 |
-
"url": "https://packagist.com",
|
143 |
-
"type": "custom"
|
144 |
-
},
|
145 |
-
{
|
146 |
-
"url": "https://github.com/composer",
|
147 |
-
"type": "github"
|
148 |
-
},
|
149 |
-
{
|
150 |
-
"url": "https://tidelift.com/funding/github/packagist/composer/composer",
|
151 |
-
"type": "tidelift"
|
152 |
-
}
|
153 |
-
],
|
154 |
-
"install-path": "./installers"
|
155 |
-
},
|
156 |
{
|
157 |
"name": "stripe/stripe-php",
|
158 |
"version": "v7.47.0",
|
1 |
{
|
2 |
"packages": [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
{
|
4 |
"name": "stripe/stripe-php",
|
5 |
"version": "v7.47.0",
|
includes/gateways/stripe/vendor/composer/installed.php
CHANGED
@@ -3,43 +3,22 @@
|
|
3 |
'name' => 'easy-digital-downloads/edd-stripe',
|
4 |
'pretty_version' => 'dev-master',
|
5 |
'version' => 'dev-master',
|
6 |
-
'reference' => '
|
7 |
'type' => 'wordpress-plugin',
|
8 |
'install_path' => __DIR__ . '/../../',
|
9 |
'aliases' => array(),
|
10 |
'dev' => false,
|
11 |
),
|
12 |
'versions' => array(
|
13 |
-
'composer/installers' => array(
|
14 |
-
'pretty_version' => 'v1.11.0',
|
15 |
-
'version' => '1.11.0.0',
|
16 |
-
'reference' => 'ae03311f45dfe194412081526be2e003960df74b',
|
17 |
-
'type' => 'composer-plugin',
|
18 |
-
'install_path' => __DIR__ . '/./installers',
|
19 |
-
'aliases' => array(),
|
20 |
-
'dev_requirement' => false,
|
21 |
-
),
|
22 |
'easy-digital-downloads/edd-stripe' => array(
|
23 |
'pretty_version' => 'dev-master',
|
24 |
'version' => 'dev-master',
|
25 |
-
'reference' => '
|
26 |
'type' => 'wordpress-plugin',
|
27 |
'install_path' => __DIR__ . '/../../',
|
28 |
'aliases' => array(),
|
29 |
'dev_requirement' => false,
|
30 |
),
|
31 |
-
'roundcube/plugin-installer' => array(
|
32 |
-
'dev_requirement' => false,
|
33 |
-
'replaced' => array(
|
34 |
-
0 => '*',
|
35 |
-
),
|
36 |
-
),
|
37 |
-
'shama/baton' => array(
|
38 |
-
'dev_requirement' => false,
|
39 |
-
'replaced' => array(
|
40 |
-
0 => '*',
|
41 |
-
),
|
42 |
-
),
|
43 |
'stripe/stripe-php' => array(
|
44 |
'pretty_version' => 'v7.47.0',
|
45 |
'version' => '7.47.0.0',
|
3 |
'name' => 'easy-digital-downloads/edd-stripe',
|
4 |
'pretty_version' => 'dev-master',
|
5 |
'version' => 'dev-master',
|
6 |
+
'reference' => '829e436e3e0b91ab69528aebcee3344aa2e91eca',
|
7 |
'type' => 'wordpress-plugin',
|
8 |
'install_path' => __DIR__ . '/../../',
|
9 |
'aliases' => array(),
|
10 |
'dev' => false,
|
11 |
),
|
12 |
'versions' => array(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
'easy-digital-downloads/edd-stripe' => array(
|
14 |
'pretty_version' => 'dev-master',
|
15 |
'version' => 'dev-master',
|
16 |
+
'reference' => '829e436e3e0b91ab69528aebcee3344aa2e91eca',
|
17 |
'type' => 'wordpress-plugin',
|
18 |
'install_path' => __DIR__ . '/../../',
|
19 |
'aliases' => array(),
|
20 |
'dev_requirement' => false,
|
21 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
'stripe/stripe-php' => array(
|
23 |
'pretty_version' => 'v7.47.0',
|
24 |
'version' => '7.47.0.0',
|
includes/gateways/stripe/vendor/composer/installers/LICENSE
DELETED
@@ -1,19 +0,0 @@
|
|
1 |
-
Copyright (c) 2012 Kyle Robinson Young
|
2 |
-
|
3 |
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
4 |
-
of this software and associated documentation files (the "Software"), to deal
|
5 |
-
in the Software without restriction, including without limitation the rights
|
6 |
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
7 |
-
copies of the Software, and to permit persons to whom the Software is furnished
|
8 |
-
to do so, subject to the following conditions:
|
9 |
-
|
10 |
-
The above copyright notice and this permission notice shall be included in all
|
11 |
-
copies or substantial portions of the Software.
|
12 |
-
|
13 |
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
14 |
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
15 |
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
16 |
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
17 |
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
18 |
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
19 |
-
THE SOFTWARE.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/composer.json
DELETED
@@ -1,121 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"name": "composer/installers",
|
3 |
-
"type": "composer-plugin",
|
4 |
-
"license": "MIT",
|
5 |
-
"description": "A multi-framework Composer library installer",
|
6 |
-
"keywords": [
|
7 |
-
"installer",
|
8 |
-
"Aimeos",
|
9 |
-
"AGL",
|
10 |
-
"AnnotateCms",
|
11 |
-
"Attogram",
|
12 |
-
"Bitrix",
|
13 |
-
"CakePHP",
|
14 |
-
"Chef",
|
15 |
-
"Cockpit",
|
16 |
-
"CodeIgniter",
|
17 |
-
"concrete5",
|
18 |
-
"Craft",
|
19 |
-
"Croogo",
|
20 |
-
"DokuWiki",
|
21 |
-
"Dolibarr",
|
22 |
-
"Drupal",
|
23 |
-
"Elgg",
|
24 |
-
"Eliasis",
|
25 |
-
"ExpressionEngine",
|
26 |
-
"eZ Platform",
|
27 |
-
"FuelPHP",
|
28 |
-
"Grav",
|
29 |
-
"Hurad",
|
30 |
-
"ImageCMS",
|
31 |
-
"iTop",
|
32 |
-
"Joomla",
|
33 |
-
"Kanboard",
|
34 |
-
"Known",
|
35 |
-
"Kohana",
|
36 |
-
"Lan Management System",
|
37 |
-
"Laravel",
|
38 |
-
"Lavalite",
|
39 |
-
"Lithium",
|
40 |
-
"Magento",
|
41 |
-
"majima",
|
42 |
-
"Mako",
|
43 |
-
"MantisBT",
|
44 |
-
"Mautic",
|
45 |
-
"Maya",
|
46 |
-
"MODX",
|
47 |
-
"MODX Evo",
|
48 |
-
"MediaWiki",
|
49 |
-
"Miaoxing",
|
50 |
-
"OXID",
|
51 |
-
"osclass",
|
52 |
-
"MODULEWork",
|
53 |
-
"Moodle",
|
54 |
-
"Piwik",
|
55 |
-
"pxcms",
|
56 |
-
"phpBB",
|
57 |
-
"Plentymarkets",
|
58 |
-
"PPI",
|
59 |
-
"Puppet",
|
60 |
-
"Porto",
|
61 |
-
"ProcessWire",
|
62 |
-
"RadPHP",
|
63 |
-
"ReIndex",
|
64 |
-
"Roundcube",
|
65 |
-
"shopware",
|
66 |
-
"SilverStripe",
|
67 |
-
"SMF",
|
68 |
-
"Starbug",
|
69 |
-
"SyDES",
|
70 |
-
"Sylius",
|
71 |
-
"symfony",
|
72 |
-
"TastyIgniter",
|
73 |
-
"Thelia",
|
74 |
-
"TYPO3",
|
75 |
-
"WHMCS",
|
76 |
-
"WolfCMS",
|
77 |
-
"WordPress",
|
78 |
-
"YAWIK",
|
79 |
-
"Zend",
|
80 |
-
"Zikula"
|
81 |
-
],
|
82 |
-
"homepage": "https://composer.github.io/installers/",
|
83 |
-
"authors": [
|
84 |
-
{
|
85 |
-
"name": "Kyle Robinson Young",
|
86 |
-
"email": "kyle@dontkry.com",
|
87 |
-
"homepage": "https://github.com/shama"
|
88 |
-
}
|
89 |
-
],
|
90 |
-
"autoload": {
|
91 |
-
"psr-4": { "Composer\\Installers\\": "src/Composer/Installers" }
|
92 |
-
},
|
93 |
-
"autoload-dev": {
|
94 |
-
"psr-4": { "Composer\\Installers\\Test\\": "tests/Composer/Installers/Test" }
|
95 |
-
},
|
96 |
-
"extra": {
|
97 |
-
"class": "Composer\\Installers\\Plugin",
|
98 |
-
"branch-alias": {
|
99 |
-
"dev-main": "1.x-dev"
|
100 |
-
}
|
101 |
-
},
|
102 |
-
"replace": {
|
103 |
-
"shama/baton": "*",
|
104 |
-
"roundcube/plugin-installer": "*"
|
105 |
-
},
|
106 |
-
"require": {
|
107 |
-
"composer-plugin-api": "^1.0 || ^2.0"
|
108 |
-
},
|
109 |
-
"require-dev": {
|
110 |
-
"composer/composer": "1.6.* || ^2.0",
|
111 |
-
"composer/semver": "^1 || ^3",
|
112 |
-
"symfony/phpunit-bridge": "^4.2 || ^5",
|
113 |
-
"phpstan/phpstan": "^0.12.55",
|
114 |
-
"symfony/process": "^2.3",
|
115 |
-
"phpstan/phpstan-phpunit": "^0.12.16"
|
116 |
-
},
|
117 |
-
"scripts": {
|
118 |
-
"test": "SYMFONY_PHPUNIT_REMOVE_RETURN_TYPEHINT=1 vendor/bin/simple-phpunit",
|
119 |
-
"phpstan": "vendor/bin/phpstan analyse"
|
120 |
-
}
|
121 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/phpstan.neon.dist
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
parameters:
|
2 |
-
level: 5
|
3 |
-
paths:
|
4 |
-
- src
|
5 |
-
- tests
|
6 |
-
excludes_analyse:
|
7 |
-
- tests/Composer/Installers/Test/PolyfillTestCase.php
|
8 |
-
|
9 |
-
includes:
|
10 |
-
- vendor/phpstan/phpstan-phpunit/extension.neon
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AglInstaller.php
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class AglInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'More/{$name}/',
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Format package name to CamelCase
|
12 |
-
*/
|
13 |
-
public function inflectPackageVars($vars)
|
14 |
-
{
|
15 |
-
$vars['name'] = preg_replace_callback('/(?:^|_|-)(.?)/', function ($matches) {
|
16 |
-
return strtoupper($matches[1]);
|
17 |
-
}, $vars['name']);
|
18 |
-
|
19 |
-
return $vars;
|
20 |
-
}
|
21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class AimeosInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'extension' => 'ext/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class AnnotateCmsInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'addons/modules/{$name}/',
|
8 |
-
'component' => 'addons/components/{$name}/',
|
9 |
-
'service' => 'addons/services/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AsgardInstaller.php
DELETED
@@ -1,49 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class AsgardInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'Modules/{$name}/',
|
8 |
-
'theme' => 'Themes/{$name}/'
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name.
|
13 |
-
*
|
14 |
-
* For package type asgard-module, cut off a trailing '-plugin' if present.
|
15 |
-
*
|
16 |
-
* For package type asgard-theme, cut off a trailing '-theme' if present.
|
17 |
-
*
|
18 |
-
*/
|
19 |
-
public function inflectPackageVars($vars)
|
20 |
-
{
|
21 |
-
if ($vars['type'] === 'asgard-module') {
|
22 |
-
return $this->inflectPluginVars($vars);
|
23 |
-
}
|
24 |
-
|
25 |
-
if ($vars['type'] === 'asgard-theme') {
|
26 |
-
return $this->inflectThemeVars($vars);
|
27 |
-
}
|
28 |
-
|
29 |
-
return $vars;
|
30 |
-
}
|
31 |
-
|
32 |
-
protected function inflectPluginVars($vars)
|
33 |
-
{
|
34 |
-
$vars['name'] = preg_replace('/-module$/', '', $vars['name']);
|
35 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
36 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
37 |
-
|
38 |
-
return $vars;
|
39 |
-
}
|
40 |
-
|
41 |
-
protected function inflectThemeVars($vars)
|
42 |
-
{
|
43 |
-
$vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
|
44 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
45 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
46 |
-
|
47 |
-
return $vars;
|
48 |
-
}
|
49 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/AttogramInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class AttogramInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BaseInstaller.php
DELETED
@@ -1,137 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\IO\IOInterface;
|
5 |
-
use Composer\Composer;
|
6 |
-
use Composer\Package\PackageInterface;
|
7 |
-
|
8 |
-
abstract class BaseInstaller
|
9 |
-
{
|
10 |
-
protected $locations = array();
|
11 |
-
protected $composer;
|
12 |
-
protected $package;
|
13 |
-
protected $io;
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Initializes base installer.
|
17 |
-
*
|
18 |
-
* @param PackageInterface $package
|
19 |
-
* @param Composer $composer
|
20 |
-
* @param IOInterface $io
|
21 |
-
*/
|
22 |
-
public function __construct(PackageInterface $package = null, Composer $composer = null, IOInterface $io = null)
|
23 |
-
{
|
24 |
-
$this->composer = $composer;
|
25 |
-
$this->package = $package;
|
26 |
-
$this->io = $io;
|
27 |
-
}
|
28 |
-
|
29 |
-
/**
|
30 |
-
* Return the install path based on package type.
|
31 |
-
*
|
32 |
-
* @param PackageInterface $package
|
33 |
-
* @param string $frameworkType
|
34 |
-
* @return string
|
35 |
-
*/
|
36 |
-
public function getInstallPath(PackageInterface $package, $frameworkType = '')
|
37 |
-
{
|
38 |
-
$type = $this->package->getType();
|
39 |
-
|
40 |
-
$prettyName = $this->package->getPrettyName();
|
41 |
-
if (strpos($prettyName, '/') !== false) {
|
42 |
-
list($vendor, $name) = explode('/', $prettyName);
|
43 |
-
} else {
|
44 |
-
$vendor = '';
|
45 |
-
$name = $prettyName;
|
46 |
-
}
|
47 |
-
|
48 |
-
$availableVars = $this->inflectPackageVars(compact('name', 'vendor', 'type'));
|
49 |
-
|
50 |
-
$extra = $package->getExtra();
|
51 |
-
if (!empty($extra['installer-name'])) {
|
52 |
-
$availableVars['name'] = $extra['installer-name'];
|
53 |
-
}
|
54 |
-
|
55 |
-
if ($this->composer->getPackage()) {
|
56 |
-
$extra = $this->composer->getPackage()->getExtra();
|
57 |
-
if (!empty($extra['installer-paths'])) {
|
58 |
-
$customPath = $this->mapCustomInstallPaths($extra['installer-paths'], $prettyName, $type, $vendor);
|
59 |
-
if ($customPath !== false) {
|
60 |
-
return $this->templatePath($customPath, $availableVars);
|
61 |
-
}
|
62 |
-
}
|
63 |
-
}
|
64 |
-
|
65 |
-
$packageType = substr($type, strlen($frameworkType) + 1);
|
66 |
-
$locations = $this->getLocations();
|
67 |
-
if (!isset($locations[$packageType])) {
|
68 |
-
throw new \InvalidArgumentException(sprintf('Package type "%s" is not supported', $type));
|
69 |
-
}
|
70 |
-
|
71 |
-
return $this->templatePath($locations[$packageType], $availableVars);
|
72 |
-
}
|
73 |
-
|
74 |
-
/**
|
75 |
-
* For an installer to override to modify the vars per installer.
|
76 |
-
*
|
77 |
-
* @param array<string, string> $vars This will normally receive array{name: string, vendor: string, type: string}
|
78 |
-
* @return array<string, string>
|
79 |
-
*/
|
80 |
-
public function inflectPackageVars($vars)
|
81 |
-
{
|
82 |
-
return $vars;
|
83 |
-
}
|
84 |
-
|
85 |
-
/**
|
86 |
-
* Gets the installer's locations
|
87 |
-
*
|
88 |
-
* @return array<string, string> map of package types => install path
|
89 |
-
*/
|
90 |
-
public function getLocations()
|
91 |
-
{
|
92 |
-
return $this->locations;
|
93 |
-
}
|
94 |
-
|
95 |
-
/**
|
96 |
-
* Replace vars in a path
|
97 |
-
*
|
98 |
-
* @param string $path
|
99 |
-
* @param array<string, string> $vars
|
100 |
-
* @return string
|
101 |
-
*/
|
102 |
-
protected function templatePath($path, array $vars = array())
|
103 |
-
{
|
104 |
-
if (strpos($path, '{') !== false) {
|
105 |
-
extract($vars);
|
106 |
-
preg_match_all('@\{\$([A-Za-z0-9_]*)\}@i', $path, $matches);
|
107 |
-
if (!empty($matches[1])) {
|
108 |
-
foreach ($matches[1] as $var) {
|
109 |
-
$path = str_replace('{$' . $var . '}', $$var, $path);
|
110 |
-
}
|
111 |
-
}
|
112 |
-
}
|
113 |
-
|
114 |
-
return $path;
|
115 |
-
}
|
116 |
-
|
117 |
-
/**
|
118 |
-
* Search through a passed paths array for a custom install path.
|
119 |
-
*
|
120 |
-
* @param array $paths
|
121 |
-
* @param string $name
|
122 |
-
* @param string $type
|
123 |
-
* @param string $vendor = NULL
|
124 |
-
* @return string|false
|
125 |
-
*/
|
126 |
-
protected function mapCustomInstallPaths(array $paths, $name, $type, $vendor = NULL)
|
127 |
-
{
|
128 |
-
foreach ($paths as $path => $names) {
|
129 |
-
$names = (array) $names;
|
130 |
-
if (in_array($name, $names) || in_array('type:' . $type, $names) || in_array('vendor:' . $vendor, $names)) {
|
131 |
-
return $path;
|
132 |
-
}
|
133 |
-
}
|
134 |
-
|
135 |
-
return false;
|
136 |
-
}
|
137 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php
DELETED
@@ -1,126 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
use Composer\Util\Filesystem;
|
6 |
-
|
7 |
-
/**
|
8 |
-
* Installer for Bitrix Framework. Supported types of extensions:
|
9 |
-
* - `bitrix-d7-module` — copy the module to directory `bitrix/modules/<vendor>.<name>`.
|
10 |
-
* - `bitrix-d7-component` — copy the component to directory `bitrix/components/<vendor>/<name>`.
|
11 |
-
* - `bitrix-d7-template` — copy the template to directory `bitrix/templates/<vendor>_<name>`.
|
12 |
-
*
|
13 |
-
* You can set custom path to directory with Bitrix kernel in `composer.json`:
|
14 |
-
*
|
15 |
-
* ```json
|
16 |
-
* {
|
17 |
-
* "extra": {
|
18 |
-
* "bitrix-dir": "s1/bitrix"
|
19 |
-
* }
|
20 |
-
* }
|
21 |
-
* ```
|
22 |
-
*
|
23 |
-
* @author Nik Samokhvalov <nik@samokhvalov.info>
|
24 |
-
* @author Denis Kulichkin <onexhovia@gmail.com>
|
25 |
-
*/
|
26 |
-
class BitrixInstaller extends BaseInstaller
|
27 |
-
{
|
28 |
-
protected $locations = array(
|
29 |
-
'module' => '{$bitrix_dir}/modules/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
|
30 |
-
'component' => '{$bitrix_dir}/components/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
|
31 |
-
'theme' => '{$bitrix_dir}/templates/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
|
32 |
-
'd7-module' => '{$bitrix_dir}/modules/{$vendor}.{$name}/',
|
33 |
-
'd7-component' => '{$bitrix_dir}/components/{$vendor}/{$name}/',
|
34 |
-
'd7-template' => '{$bitrix_dir}/templates/{$vendor}_{$name}/',
|
35 |
-
);
|
36 |
-
|
37 |
-
/**
|
38 |
-
* @var array Storage for informations about duplicates at all the time of installation packages.
|
39 |
-
*/
|
40 |
-
private static $checkedDuplicates = array();
|
41 |
-
|
42 |
-
/**
|
43 |
-
* {@inheritdoc}
|
44 |
-
*/
|
45 |
-
public function inflectPackageVars($vars)
|
46 |
-
{
|
47 |
-
if ($this->composer->getPackage()) {
|
48 |
-
$extra = $this->composer->getPackage()->getExtra();
|
49 |
-
|
50 |
-
if (isset($extra['bitrix-dir'])) {
|
51 |
-
$vars['bitrix_dir'] = $extra['bitrix-dir'];
|
52 |
-
}
|
53 |
-
}
|
54 |
-
|
55 |
-
if (!isset($vars['bitrix_dir'])) {
|
56 |
-
$vars['bitrix_dir'] = 'bitrix';
|
57 |
-
}
|
58 |
-
|
59 |
-
return parent::inflectPackageVars($vars);
|
60 |
-
}
|
61 |
-
|
62 |
-
/**
|
63 |
-
* {@inheritdoc}
|
64 |
-
*/
|
65 |
-
protected function templatePath($path, array $vars = array())
|
66 |
-
{
|
67 |
-
$templatePath = parent::templatePath($path, $vars);
|
68 |
-
$this->checkDuplicates($templatePath, $vars);
|
69 |
-
|
70 |
-
return $templatePath;
|
71 |
-
}
|
72 |
-
|
73 |
-
/**
|
74 |
-
* Duplicates search packages.
|
75 |
-
*
|
76 |
-
* @param string $path
|
77 |
-
* @param array $vars
|
78 |
-
*/
|
79 |
-
protected function checkDuplicates($path, array $vars = array())
|
80 |
-
{
|
81 |
-
$packageType = substr($vars['type'], strlen('bitrix') + 1);
|
82 |
-
$localDir = explode('/', $vars['bitrix_dir']);
|
83 |
-
array_pop($localDir);
|
84 |
-
$localDir[] = 'local';
|
85 |
-
$localDir = implode('/', $localDir);
|
86 |
-
|
87 |
-
$oldPath = str_replace(
|
88 |
-
array('{$bitrix_dir}', '{$name}'),
|
89 |
-
array($localDir, $vars['name']),
|
90 |
-
$this->locations[$packageType]
|
91 |
-
);
|
92 |
-
|
93 |
-
if (in_array($oldPath, static::$checkedDuplicates)) {
|
94 |
-
return;
|
95 |
-
}
|
96 |
-
|
97 |
-
if ($oldPath !== $path && file_exists($oldPath) && $this->io && $this->io->isInteractive()) {
|
98 |
-
|
99 |
-
$this->io->writeError(' <error>Duplication of packages:</error>');
|
100 |
-
$this->io->writeError(' <info>Package ' . $oldPath . ' will be called instead package ' . $path . '</info>');
|
101 |
-
|
102 |
-
while (true) {
|
103 |
-
switch ($this->io->ask(' <info>Delete ' . $oldPath . ' [y,n,?]?</info> ', '?')) {
|
104 |
-
case 'y':
|
105 |
-
$fs = new Filesystem();
|
106 |
-
$fs->removeDirectory($oldPath);
|
107 |
-
break 2;
|
108 |
-
|
109 |
-
case 'n':
|
110 |
-
break 2;
|
111 |
-
|
112 |
-
case '?':
|
113 |
-
default:
|
114 |
-
$this->io->writeError(array(
|
115 |
-
' y - delete package ' . $oldPath . ' and to continue with the installation',
|
116 |
-
' n - don\'t delete and to continue with the installation',
|
117 |
-
));
|
118 |
-
$this->io->writeError(' ? - print help');
|
119 |
-
break;
|
120 |
-
}
|
121 |
-
}
|
122 |
-
}
|
123 |
-
|
124 |
-
static::$checkedDuplicates[] = $oldPath;
|
125 |
-
}
|
126 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/BonefishInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class BonefishInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'package' => 'Packages/{$vendor}/{$name}/'
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CakePHPInstaller.php
DELETED
@@ -1,65 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\DependencyResolver\Pool;
|
5 |
-
use Composer\Semver\Constraint\Constraint;
|
6 |
-
|
7 |
-
class CakePHPInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
protected $locations = array(
|
10 |
-
'plugin' => 'Plugin/{$name}/',
|
11 |
-
);
|
12 |
-
|
13 |
-
/**
|
14 |
-
* Format package name to CamelCase
|
15 |
-
*/
|
16 |
-
public function inflectPackageVars($vars)
|
17 |
-
{
|
18 |
-
if ($this->matchesCakeVersion('>=', '3.0.0')) {
|
19 |
-
return $vars;
|
20 |
-
}
|
21 |
-
|
22 |
-
$nameParts = explode('/', $vars['name']);
|
23 |
-
foreach ($nameParts as &$value) {
|
24 |
-
$value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
|
25 |
-
$value = str_replace(array('-', '_'), ' ', $value);
|
26 |
-
$value = str_replace(' ', '', ucwords($value));
|
27 |
-
}
|
28 |
-
$vars['name'] = implode('/', $nameParts);
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
|
33 |
-
/**
|
34 |
-
* Change the default plugin location when cakephp >= 3.0
|
35 |
-
*/
|
36 |
-
public function getLocations()
|
37 |
-
{
|
38 |
-
if ($this->matchesCakeVersion('>=', '3.0.0')) {
|
39 |
-
$this->locations['plugin'] = $this->composer->getConfig()->get('vendor-dir') . '/{$vendor}/{$name}/';
|
40 |
-
}
|
41 |
-
return $this->locations;
|
42 |
-
}
|
43 |
-
|
44 |
-
/**
|
45 |
-
* Check if CakePHP version matches against a version
|
46 |
-
*
|
47 |
-
* @param string $matcher
|
48 |
-
* @param string $version
|
49 |
-
* @return bool
|
50 |
-
*/
|
51 |
-
protected function matchesCakeVersion($matcher, $version)
|
52 |
-
{
|
53 |
-
$repositoryManager = $this->composer->getRepositoryManager();
|
54 |
-
if (! $repositoryManager) {
|
55 |
-
return false;
|
56 |
-
}
|
57 |
-
|
58 |
-
$repos = $repositoryManager->getLocalRepository();
|
59 |
-
if (!$repos) {
|
60 |
-
return false;
|
61 |
-
}
|
62 |
-
|
63 |
-
return $repos->findPackage('cakephp/cakephp', new Constraint($matcher, $version)) !== null;
|
64 |
-
}
|
65 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ChefInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ChefInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'cookbook' => 'Chef/{$vendor}/{$name}/',
|
8 |
-
'role' => 'Chef/roles/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
11 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CiviCrmInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class CiviCrmInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'ext' => 'ext/{$name}/'
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ClanCatsFrameworkInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'ship' => 'CCF/orbit/{$name}/',
|
8 |
-
'theme' => 'CCF/app/themes/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php
DELETED
@@ -1,32 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class CockpitInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'cockpit/modules/addons/{$name}/',
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Format module name.
|
12 |
-
*
|
13 |
-
* Strip `module-` prefix from package name.
|
14 |
-
*
|
15 |
-
* {@inheritDoc}
|
16 |
-
*/
|
17 |
-
public function inflectPackageVars($vars)
|
18 |
-
{
|
19 |
-
if ($vars['type'] == 'cockpit-module') {
|
20 |
-
return $this->inflectModuleVars($vars);
|
21 |
-
}
|
22 |
-
|
23 |
-
return $vars;
|
24 |
-
}
|
25 |
-
|
26 |
-
public function inflectModuleVars($vars)
|
27 |
-
{
|
28 |
-
$vars['name'] = ucfirst(preg_replace('/cockpit-/i', '', $vars['name']));
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class CodeIgniterInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'library' => 'application/libraries/{$name}/',
|
8 |
-
'third-party' => 'application/third_party/{$name}/',
|
9 |
-
'module' => 'application/modules/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Concrete5Installer.php
DELETED
@@ -1,13 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class Concrete5Installer extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'core' => 'concrete/',
|
8 |
-
'block' => 'application/blocks/{$name}/',
|
9 |
-
'package' => 'packages/{$name}/',
|
10 |
-
'theme' => 'application/themes/{$name}/',
|
11 |
-
'update' => 'updates/{$name}/',
|
12 |
-
);
|
13 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CraftInstaller.php
DELETED
@@ -1,35 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Installer for Craft Plugins
|
6 |
-
*/
|
7 |
-
class CraftInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
const NAME_PREFIX = 'craft';
|
10 |
-
const NAME_SUFFIX = 'plugin';
|
11 |
-
|
12 |
-
protected $locations = array(
|
13 |
-
'plugin' => 'craft/plugins/{$name}/',
|
14 |
-
);
|
15 |
-
|
16 |
-
/**
|
17 |
-
* Strip `craft-` prefix and/or `-plugin` suffix from package names
|
18 |
-
*
|
19 |
-
* @param array $vars
|
20 |
-
*
|
21 |
-
* @return array
|
22 |
-
*/
|
23 |
-
final public function inflectPackageVars($vars)
|
24 |
-
{
|
25 |
-
return $this->inflectPluginVars($vars);
|
26 |
-
}
|
27 |
-
|
28 |
-
private function inflectPluginVars($vars)
|
29 |
-
{
|
30 |
-
$vars['name'] = preg_replace('/-' . self::NAME_SUFFIX . '$/i', '', $vars['name']);
|
31 |
-
$vars['name'] = preg_replace('/^' . self::NAME_PREFIX . '-/i', '', $vars['name']);
|
32 |
-
|
33 |
-
return $vars;
|
34 |
-
}
|
35 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/CroogoInstaller.php
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class CroogoInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'Plugin/{$name}/',
|
8 |
-
'theme' => 'View/Themed/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name to CamelCase
|
13 |
-
*/
|
14 |
-
public function inflectPackageVars($vars)
|
15 |
-
{
|
16 |
-
$vars['name'] = strtolower(str_replace(array('-', '_'), ' ', $vars['name']));
|
17 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
18 |
-
|
19 |
-
return $vars;
|
20 |
-
}
|
21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class DecibelInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
/** @var array */
|
7 |
-
protected $locations = array(
|
8 |
-
'app' => 'app/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DframeInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class DframeInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'module' => 'modules/{$vendor}/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DokuWikiInstaller.php
DELETED
@@ -1,50 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class DokuWikiInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'lib/plugins/{$name}/',
|
8 |
-
'template' => 'lib/tpl/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name.
|
13 |
-
*
|
14 |
-
* For package type dokuwiki-plugin, cut off a trailing '-plugin',
|
15 |
-
* or leading dokuwiki_ if present.
|
16 |
-
*
|
17 |
-
* For package type dokuwiki-template, cut off a trailing '-template' if present.
|
18 |
-
*
|
19 |
-
*/
|
20 |
-
public function inflectPackageVars($vars)
|
21 |
-
{
|
22 |
-
|
23 |
-
if ($vars['type'] === 'dokuwiki-plugin') {
|
24 |
-
return $this->inflectPluginVars($vars);
|
25 |
-
}
|
26 |
-
|
27 |
-
if ($vars['type'] === 'dokuwiki-template') {
|
28 |
-
return $this->inflectTemplateVars($vars);
|
29 |
-
}
|
30 |
-
|
31 |
-
return $vars;
|
32 |
-
}
|
33 |
-
|
34 |
-
protected function inflectPluginVars($vars)
|
35 |
-
{
|
36 |
-
$vars['name'] = preg_replace('/-plugin$/', '', $vars['name']);
|
37 |
-
$vars['name'] = preg_replace('/^dokuwiki_?-?/', '', $vars['name']);
|
38 |
-
|
39 |
-
return $vars;
|
40 |
-
}
|
41 |
-
|
42 |
-
protected function inflectTemplateVars($vars)
|
43 |
-
{
|
44 |
-
$vars['name'] = preg_replace('/-template$/', '', $vars['name']);
|
45 |
-
$vars['name'] = preg_replace('/^dokuwiki_?-?/', '', $vars['name']);
|
46 |
-
|
47 |
-
return $vars;
|
48 |
-
}
|
49 |
-
|
50 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DolibarrInstaller.php
DELETED
@@ -1,16 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Class DolibarrInstaller
|
6 |
-
*
|
7 |
-
* @package Composer\Installers
|
8 |
-
* @author Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
9 |
-
*/
|
10 |
-
class DolibarrInstaller extends BaseInstaller
|
11 |
-
{
|
12 |
-
//TODO: Add support for scripts and themes
|
13 |
-
protected $locations = array(
|
14 |
-
'module' => 'htdocs/custom/{$name}/',
|
15 |
-
);
|
16 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/DrupalInstaller.php
DELETED
@@ -1,22 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class DrupalInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'core' => 'core/',
|
8 |
-
'module' => 'modules/{$name}/',
|
9 |
-
'theme' => 'themes/{$name}/',
|
10 |
-
'library' => 'libraries/{$name}/',
|
11 |
-
'profile' => 'profiles/{$name}/',
|
12 |
-
'database-driver' => 'drivers/lib/Drupal/Driver/Database/{$name}/',
|
13 |
-
'drush' => 'drush/{$name}/',
|
14 |
-
'custom-theme' => 'themes/custom/{$name}/',
|
15 |
-
'custom-module' => 'modules/custom/{$name}/',
|
16 |
-
'custom-profile' => 'profiles/custom/{$name}/',
|
17 |
-
'drupal-multisite' => 'sites/{$name}/',
|
18 |
-
'console' => 'console/{$name}/',
|
19 |
-
'console-language' => 'console/language/{$name}/',
|
20 |
-
'config' => 'config/sync/',
|
21 |
-
);
|
22 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ElggInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ElggInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'mod/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/EliasisInstaller.php
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class EliasisInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'component' => 'components/{$name}/',
|
8 |
-
'module' => 'modules/{$name}/',
|
9 |
-
'plugin' => 'plugins/{$name}/',
|
10 |
-
'template' => 'templates/{$name}/',
|
11 |
-
);
|
12 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php
DELETED
@@ -1,29 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\Package\PackageInterface;
|
5 |
-
|
6 |
-
class ExpressionEngineInstaller extends BaseInstaller
|
7 |
-
{
|
8 |
-
|
9 |
-
protected $locations = array();
|
10 |
-
|
11 |
-
private $ee2Locations = array(
|
12 |
-
'addon' => 'system/expressionengine/third_party/{$name}/',
|
13 |
-
'theme' => 'themes/third_party/{$name}/',
|
14 |
-
);
|
15 |
-
|
16 |
-
private $ee3Locations = array(
|
17 |
-
'addon' => 'system/user/addons/{$name}/',
|
18 |
-
'theme' => 'themes/user/{$name}/',
|
19 |
-
);
|
20 |
-
|
21 |
-
public function getInstallPath(PackageInterface $package, $frameworkType = '')
|
22 |
-
{
|
23 |
-
|
24 |
-
$version = "{$frameworkType}Locations";
|
25 |
-
$this->locations = $this->$version;
|
26 |
-
|
27 |
-
return parent::getInstallPath($package, $frameworkType);
|
28 |
-
}
|
29 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/EzPlatformInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class EzPlatformInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'meta-assets' => 'web/assets/ezplatform/',
|
8 |
-
'assets' => 'web/assets/ezplatform/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/FuelInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class FuelInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'fuel/app/modules/{$name}/',
|
8 |
-
'package' => 'fuel/packages/{$name}/',
|
9 |
-
'theme' => 'fuel/app/themes/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/FuelphpInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class FuelphpInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'component' => 'components/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/GravInstaller.php
DELETED
@@ -1,30 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class GravInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'user/plugins/{$name}/',
|
8 |
-
'theme' => 'user/themes/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name
|
13 |
-
*
|
14 |
-
* @param array $vars
|
15 |
-
*
|
16 |
-
* @return array
|
17 |
-
*/
|
18 |
-
public function inflectPackageVars($vars)
|
19 |
-
{
|
20 |
-
$restrictedWords = implode('|', array_keys($this->locations));
|
21 |
-
|
22 |
-
$vars['name'] = strtolower($vars['name']);
|
23 |
-
$vars['name'] = preg_replace('/^(?:grav-)?(?:(?:'.$restrictedWords.')-)?(.*?)(?:-(?:'.$restrictedWords.'))?$/ui',
|
24 |
-
'$1',
|
25 |
-
$vars['name']
|
26 |
-
);
|
27 |
-
|
28 |
-
return $vars;
|
29 |
-
}
|
30 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/HuradInstaller.php
DELETED
@@ -1,25 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class HuradInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'plugins/{$name}/',
|
8 |
-
'theme' => 'plugins/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name to CamelCase
|
13 |
-
*/
|
14 |
-
public function inflectPackageVars($vars)
|
15 |
-
{
|
16 |
-
$nameParts = explode('/', $vars['name']);
|
17 |
-
foreach ($nameParts as &$value) {
|
18 |
-
$value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
|
19 |
-
$value = str_replace(array('-', '_'), ' ', $value);
|
20 |
-
$value = str_replace(' ', '', ucwords($value));
|
21 |
-
}
|
22 |
-
$vars['name'] = implode('/', $nameParts);
|
23 |
-
return $vars;
|
24 |
-
}
|
25 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ImageCMSInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ImageCMSInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'template' => 'templates/{$name}/',
|
8 |
-
'module' => 'application/modules/{$name}/',
|
9 |
-
'library' => 'application/libraries/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Installer.php
DELETED
@@ -1,297 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
use Composer\Composer;
|
6 |
-
use Composer\Installer\BinaryInstaller;
|
7 |
-
use Composer\Installer\LibraryInstaller;
|
8 |
-
use Composer\IO\IOInterface;
|
9 |
-
use Composer\Package\PackageInterface;
|
10 |
-
use Composer\Repository\InstalledRepositoryInterface;
|
11 |
-
use Composer\Util\Filesystem;
|
12 |
-
use React\Promise\PromiseInterface;
|
13 |
-
|
14 |
-
class Installer extends LibraryInstaller
|
15 |
-
{
|
16 |
-
|
17 |
-
/**
|
18 |
-
* Package types to installer class map
|
19 |
-
*
|
20 |
-
* @var array
|
21 |
-
*/
|
22 |
-
private $supportedTypes = array(
|
23 |
-
'aimeos' => 'AimeosInstaller',
|
24 |
-
'asgard' => 'AsgardInstaller',
|
25 |
-
'attogram' => 'AttogramInstaller',
|
26 |
-
'agl' => 'AglInstaller',
|
27 |
-
'annotatecms' => 'AnnotateCmsInstaller',
|
28 |
-
'bitrix' => 'BitrixInstaller',
|
29 |
-
'bonefish' => 'BonefishInstaller',
|
30 |
-
'cakephp' => 'CakePHPInstaller',
|
31 |
-
'chef' => 'ChefInstaller',
|
32 |
-
'civicrm' => 'CiviCrmInstaller',
|
33 |
-
'ccframework' => 'ClanCatsFrameworkInstaller',
|
34 |
-
'cockpit' => 'CockpitInstaller',
|
35 |
-
'codeigniter' => 'CodeIgniterInstaller',
|
36 |
-
'concrete5' => 'Concrete5Installer',
|
37 |
-
'craft' => 'CraftInstaller',
|
38 |
-
'croogo' => 'CroogoInstaller',
|
39 |
-
'dframe' => 'DframeInstaller',
|
40 |
-
'dokuwiki' => 'DokuWikiInstaller',
|
41 |
-
'dolibarr' => 'DolibarrInstaller',
|
42 |
-
'decibel' => 'DecibelInstaller',
|
43 |
-
'drupal' => 'DrupalInstaller',
|
44 |
-
'elgg' => 'ElggInstaller',
|
45 |
-
'eliasis' => 'EliasisInstaller',
|
46 |
-
'ee3' => 'ExpressionEngineInstaller',
|
47 |
-
'ee2' => 'ExpressionEngineInstaller',
|
48 |
-
'ezplatform' => 'EzPlatformInstaller',
|
49 |
-
'fuel' => 'FuelInstaller',
|
50 |
-
'fuelphp' => 'FuelphpInstaller',
|
51 |
-
'grav' => 'GravInstaller',
|
52 |
-
'hurad' => 'HuradInstaller',
|
53 |
-
'tastyigniter' => 'TastyIgniterInstaller',
|
54 |
-
'imagecms' => 'ImageCMSInstaller',
|
55 |
-
'itop' => 'ItopInstaller',
|
56 |
-
'joomla' => 'JoomlaInstaller',
|
57 |
-
'kanboard' => 'KanboardInstaller',
|
58 |
-
'kirby' => 'KirbyInstaller',
|
59 |
-
'known' => 'KnownInstaller',
|
60 |
-
'kodicms' => 'KodiCMSInstaller',
|
61 |
-
'kohana' => 'KohanaInstaller',
|
62 |
-
'lms' => 'LanManagementSystemInstaller',
|
63 |
-
'laravel' => 'LaravelInstaller',
|
64 |
-
'lavalite' => 'LavaLiteInstaller',
|
65 |
-
'lithium' => 'LithiumInstaller',
|
66 |
-
'magento' => 'MagentoInstaller',
|
67 |
-
'majima' => 'MajimaInstaller',
|
68 |
-
'mantisbt' => 'MantisBTInstaller',
|
69 |
-
'mako' => 'MakoInstaller',
|
70 |
-
'maya' => 'MayaInstaller',
|
71 |
-
'mautic' => 'MauticInstaller',
|
72 |
-
'mediawiki' => 'MediaWikiInstaller',
|
73 |
-
'miaoxing' => 'MiaoxingInstaller',
|
74 |
-
'microweber' => 'MicroweberInstaller',
|
75 |
-
'modulework' => 'MODULEWorkInstaller',
|
76 |
-
'modx' => 'ModxInstaller',
|
77 |
-
'modxevo' => 'MODXEvoInstaller',
|
78 |
-
'moodle' => 'MoodleInstaller',
|
79 |
-
'october' => 'OctoberInstaller',
|
80 |
-
'ontowiki' => 'OntoWikiInstaller',
|
81 |
-
'oxid' => 'OxidInstaller',
|
82 |
-
'osclass' => 'OsclassInstaller',
|
83 |
-
'pxcms' => 'PxcmsInstaller',
|
84 |
-
'phpbb' => 'PhpBBInstaller',
|
85 |
-
'pimcore' => 'PimcoreInstaller',
|
86 |
-
'piwik' => 'PiwikInstaller',
|
87 |
-
'plentymarkets'=> 'PlentymarketsInstaller',
|
88 |
-
'ppi' => 'PPIInstaller',
|
89 |
-
'puppet' => 'PuppetInstaller',
|
90 |
-
'radphp' => 'RadPHPInstaller',
|
91 |
-
'phifty' => 'PhiftyInstaller',
|
92 |
-
'porto' => 'PortoInstaller',
|
93 |
-
'processwire' => 'ProcessWireInstaller',
|
94 |
-
'redaxo' => 'RedaxoInstaller',
|
95 |
-
'redaxo5' => 'Redaxo5Installer',
|
96 |
-
'reindex' => 'ReIndexInstaller',
|
97 |
-
'roundcube' => 'RoundcubeInstaller',
|
98 |
-
'shopware' => 'ShopwareInstaller',
|
99 |
-
'sitedirect' => 'SiteDirectInstaller',
|
100 |
-
'silverstripe' => 'SilverStripeInstaller',
|
101 |
-
'smf' => 'SMFInstaller',
|
102 |
-
'starbug' => 'StarbugInstaller',
|
103 |
-
'sydes' => 'SyDESInstaller',
|
104 |
-
'sylius' => 'SyliusInstaller',
|
105 |
-
'symfony1' => 'Symfony1Installer',
|
106 |
-
'tao' => 'TaoInstaller',
|
107 |
-
'thelia' => 'TheliaInstaller',
|
108 |
-
'tusk' => 'TuskInstaller',
|
109 |
-
'typo3-cms' => 'TYPO3CmsInstaller',
|
110 |
-
'typo3-flow' => 'TYPO3FlowInstaller',
|
111 |
-
'userfrosting' => 'UserFrostingInstaller',
|
112 |
-
'vanilla' => 'VanillaInstaller',
|
113 |
-
'whmcs' => 'WHMCSInstaller',
|
114 |
-
'winter' => 'WinterInstaller',
|
115 |
-
'wolfcms' => 'WolfCMSInstaller',
|
116 |
-
'wordpress' => 'WordPressInstaller',
|
117 |
-
'yawik' => 'YawikInstaller',
|
118 |
-
'zend' => 'ZendInstaller',
|
119 |
-
'zikula' => 'ZikulaInstaller',
|
120 |
-
'prestashop' => 'PrestashopInstaller'
|
121 |
-
);
|
122 |
-
|
123 |
-
/**
|
124 |
-
* Installer constructor.
|
125 |
-
*
|
126 |
-
* Disables installers specified in main composer extra installer-disable
|
127 |
-
* list
|
128 |
-
*
|
129 |
-
* @param IOInterface $io
|
130 |
-
* @param Composer $composer
|
131 |
-
* @param string $type
|
132 |
-
* @param Filesystem|null $filesystem
|
133 |
-
* @param BinaryInstaller|null $binaryInstaller
|
134 |
-
*/
|
135 |
-
public function __construct(
|
136 |
-
IOInterface $io,
|
137 |
-
Composer $composer,
|
138 |
-
$type = 'library',
|
139 |
-
Filesystem $filesystem = null,
|
140 |
-
BinaryInstaller $binaryInstaller = null
|
141 |
-
) {
|
142 |
-
parent::__construct($io, $composer, $type, $filesystem,
|
143 |
-
$binaryInstaller);
|
144 |
-
$this->removeDisabledInstallers();
|
145 |
-
}
|
146 |
-
|
147 |
-
/**
|
148 |
-
* {@inheritDoc}
|
149 |
-
*/
|
150 |
-
public function getInstallPath(PackageInterface $package)
|
151 |
-
{
|
152 |
-
$type = $package->getType();
|
153 |
-
$frameworkType = $this->findFrameworkType($type);
|
154 |
-
|
155 |
-
if ($frameworkType === false) {
|
156 |
-
throw new \InvalidArgumentException(
|
157 |
-
'Sorry the package type of this package is not yet supported.'
|
158 |
-
);
|
159 |
-
}
|
160 |
-
|
161 |
-
$class = 'Composer\\Installers\\' . $this->supportedTypes[$frameworkType];
|
162 |
-
$installer = new $class($package, $this->composer, $this->getIO());
|
163 |
-
|
164 |
-
return $installer->getInstallPath($package, $frameworkType);
|
165 |
-
}
|
166 |
-
|
167 |
-
public function uninstall(InstalledRepositoryInterface $repo, PackageInterface $package)
|
168 |
-
{
|
169 |
-
$installPath = $this->getPackageBasePath($package);
|
170 |
-
$io = $this->io;
|
171 |
-
$outputStatus = function () use ($io, $installPath) {
|
172 |
-
$io->write(sprintf('Deleting %s - %s', $installPath, !file_exists($installPath) ? '<comment>deleted</comment>' : '<error>not deleted</error>'));
|
173 |
-
};
|
174 |
-
|
175 |
-
$promise = parent::uninstall($repo, $package);
|
176 |
-
|
177 |
-
// Composer v2 might return a promise here
|
178 |
-
if ($promise instanceof PromiseInterface) {
|
179 |
-
return $promise->then($outputStatus);
|
180 |
-
}
|
181 |
-
|
182 |
-
// If not, execute the code right away as parent::uninstall executed synchronously (composer v1, or v2 without async)
|
183 |
-
$outputStatus();
|
184 |
-
|
185 |
-
return null;
|
186 |
-
}
|
187 |
-
|
188 |
-
/**
|
189 |
-
* {@inheritDoc}
|
190 |
-
*/
|
191 |
-
public function supports($packageType)
|
192 |
-
{
|
193 |
-
$frameworkType = $this->findFrameworkType($packageType);
|
194 |
-
|
195 |
-
if ($frameworkType === false) {
|
196 |
-
return false;
|
197 |
-
}
|
198 |
-
|
199 |
-
$locationPattern = $this->getLocationPattern($frameworkType);
|
200 |
-
|
201 |
-
return preg_match('#' . $frameworkType . '-' . $locationPattern . '#', $packageType, $matches) === 1;
|
202 |
-
}
|
203 |
-
|
204 |
-
/**
|
205 |
-
* Finds a supported framework type if it exists and returns it
|
206 |
-
*
|
207 |
-
* @param string $type
|
208 |
-
* @return string|false
|
209 |
-
*/
|
210 |
-
protected function findFrameworkType($type)
|
211 |
-
{
|
212 |
-
krsort($this->supportedTypes);
|
213 |
-
|
214 |
-
foreach ($this->supportedTypes as $key => $val) {
|
215 |
-
if ($key === substr($type, 0, strlen($key))) {
|
216 |
-
return substr($type, 0, strlen($key));
|
217 |
-
}
|
218 |
-
}
|
219 |
-
|
220 |
-
return false;
|
221 |
-
}
|
222 |
-
|
223 |
-
/**
|
224 |
-
* Get the second part of the regular expression to check for support of a
|
225 |
-
* package type
|
226 |
-
*
|
227 |
-
* @param string $frameworkType
|
228 |
-
* @return string
|
229 |
-
*/
|
230 |
-
protected function getLocationPattern($frameworkType)
|
231 |
-
{
|
232 |
-
$pattern = false;
|
233 |
-
if (!empty($this->supportedTypes[$frameworkType])) {
|
234 |
-
$frameworkClass = 'Composer\\Installers\\' . $this->supportedTypes[$frameworkType];
|
235 |
-
/** @var BaseInstaller $framework */
|
236 |
-
$framework = new $frameworkClass(null, $this->composer, $this->getIO());
|
237 |
-
$locations = array_keys($framework->getLocations());
|
238 |
-
$pattern = $locations ? '(' . implode('|', $locations) . ')' : false;
|
239 |
-
}
|
240 |
-
|
241 |
-
return $pattern ? : '(\w+)';
|
242 |
-
}
|
243 |
-
|
244 |
-
/**
|
245 |
-
* Get I/O object
|
246 |
-
*
|
247 |
-
* @return IOInterface
|
248 |
-
*/
|
249 |
-
private function getIO()
|
250 |
-
{
|
251 |
-
return $this->io;
|
252 |
-
}
|
253 |
-
|
254 |
-
/**
|
255 |
-
* Look for installers set to be disabled in composer's extra config and
|
256 |
-
* remove them from the list of supported installers.
|
257 |
-
*
|
258 |
-
* Globals:
|
259 |
-
* - true, "all", and "*" - disable all installers.
|
260 |
-
* - false - enable all installers (useful with
|
261 |
-
* wikimedia/composer-merge-plugin or similar)
|
262 |
-
*
|
263 |
-
* @return void
|
264 |
-
*/
|
265 |
-
protected function removeDisabledInstallers()
|
266 |
-
{
|
267 |
-
$extra = $this->composer->getPackage()->getExtra();
|
268 |
-
|
269 |
-
if (!isset($extra['installer-disable']) || $extra['installer-disable'] === false) {
|
270 |
-
// No installers are disabled
|
271 |
-
return;
|
272 |
-
}
|
273 |
-
|
274 |
-
// Get installers to disable
|
275 |
-
$disable = $extra['installer-disable'];
|
276 |
-
|
277 |
-
// Ensure $disabled is an array
|
278 |
-
if (!is_array($disable)) {
|
279 |
-
$disable = array($disable);
|
280 |
-
}
|
281 |
-
|
282 |
-
// Check which installers should be disabled
|
283 |
-
$all = array(true, "all", "*");
|
284 |
-
$intersect = array_intersect($all, $disable);
|
285 |
-
if (!empty($intersect)) {
|
286 |
-
// Disable all installers
|
287 |
-
$this->supportedTypes = array();
|
288 |
-
} else {
|
289 |
-
// Disable specified installers
|
290 |
-
foreach ($disable as $key => $installer) {
|
291 |
-
if (is_string($installer) && key_exists($installer, $this->supportedTypes)) {
|
292 |
-
unset($this->supportedTypes[$installer]);
|
293 |
-
}
|
294 |
-
}
|
295 |
-
}
|
296 |
-
}
|
297 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ItopInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ItopInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'extension' => 'extensions/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/JoomlaInstaller.php
DELETED
@@ -1,15 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class JoomlaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'component' => 'components/{$name}/',
|
8 |
-
'module' => 'modules/{$name}/',
|
9 |
-
'template' => 'templates/{$name}/',
|
10 |
-
'plugin' => 'plugins/{$name}/',
|
11 |
-
'library' => 'libraries/{$name}/',
|
12 |
-
);
|
13 |
-
|
14 |
-
// TODO: Add inflector for mod_ and com_ names
|
15 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KanboardInstaller.php
DELETED
@@ -1,18 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
*
|
6 |
-
* Installer for kanboard plugins
|
7 |
-
*
|
8 |
-
* kanboard.net
|
9 |
-
*
|
10 |
-
* Class KanboardInstaller
|
11 |
-
* @package Composer\Installers
|
12 |
-
*/
|
13 |
-
class KanboardInstaller extends BaseInstaller
|
14 |
-
{
|
15 |
-
protected $locations = array(
|
16 |
-
'plugin' => 'plugins/{$name}/',
|
17 |
-
);
|
18 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KirbyInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class KirbyInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'site/plugins/{$name}/',
|
8 |
-
'field' => 'site/fields/{$name}/',
|
9 |
-
'tag' => 'site/tags/{$name}/'
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KnownInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class KnownInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'IdnoPlugins/{$name}/',
|
8 |
-
'theme' => 'Themes/{$name}/',
|
9 |
-
'console' => 'ConsolePlugins/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KodiCMSInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class KodiCMSInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'cms/plugins/{$name}/',
|
8 |
-
'media' => 'cms/media/vendor/{$name}/'
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/KohanaInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class KohanaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php
DELETED
@@ -1,27 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class LanManagementSystemInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
|
8 |
-
protected $locations = array(
|
9 |
-
'plugin' => 'plugins/{$name}/',
|
10 |
-
'template' => 'templates/{$name}/',
|
11 |
-
'document-template' => 'documents/templates/{$name}/',
|
12 |
-
'userpanel-module' => 'userpanel/modules/{$name}/',
|
13 |
-
);
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Format package name to CamelCase
|
17 |
-
*/
|
18 |
-
public function inflectPackageVars($vars)
|
19 |
-
{
|
20 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
21 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
22 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
23 |
-
|
24 |
-
return $vars;
|
25 |
-
}
|
26 |
-
|
27 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LaravelInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class LaravelInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'library' => 'libraries/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LavaLiteInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class LavaLiteInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'package' => 'packages/{$vendor}/{$name}/',
|
8 |
-
'theme' => 'public/themes/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/LithiumInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class LithiumInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'library' => 'libraries/{$name}/',
|
8 |
-
'source' => 'libraries/_source/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MODULEWorkInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MODXEvoInstaller.php
DELETED
@@ -1,16 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* An installer to handle MODX Evolution specifics when installing packages.
|
6 |
-
*/
|
7 |
-
class MODXEvoInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
protected $locations = array(
|
10 |
-
'snippet' => 'assets/snippets/{$name}/',
|
11 |
-
'plugin' => 'assets/plugins/{$name}/',
|
12 |
-
'module' => 'assets/modules/{$name}/',
|
13 |
-
'template' => 'assets/templates/{$name}/',
|
14 |
-
'lib' => 'assets/lib/{$name}/'
|
15 |
-
);
|
16 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MagentoInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MagentoInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'theme' => 'app/design/frontend/{$name}/',
|
8 |
-
'skin' => 'skin/frontend/default/{$name}/',
|
9 |
-
'library' => 'lib/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MajimaInstaller.php
DELETED
@@ -1,37 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Plugin/theme installer for majima
|
6 |
-
* @author David Neustadt
|
7 |
-
*/
|
8 |
-
class MajimaInstaller extends BaseInstaller
|
9 |
-
{
|
10 |
-
protected $locations = array(
|
11 |
-
'plugin' => 'plugins/{$name}/',
|
12 |
-
);
|
13 |
-
|
14 |
-
/**
|
15 |
-
* Transforms the names
|
16 |
-
* @param array $vars
|
17 |
-
* @return array
|
18 |
-
*/
|
19 |
-
public function inflectPackageVars($vars)
|
20 |
-
{
|
21 |
-
return $this->correctPluginName($vars);
|
22 |
-
}
|
23 |
-
|
24 |
-
/**
|
25 |
-
* Change hyphenated names to camelcase
|
26 |
-
* @param array $vars
|
27 |
-
* @return array
|
28 |
-
*/
|
29 |
-
private function correctPluginName($vars)
|
30 |
-
{
|
31 |
-
$camelCasedName = preg_replace_callback('/(-[a-z])/', function ($matches) {
|
32 |
-
return strtoupper($matches[0][1]);
|
33 |
-
}, $vars['name']);
|
34 |
-
$vars['name'] = ucfirst($camelCasedName);
|
35 |
-
return $vars;
|
36 |
-
}
|
37 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MakoInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MakoInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'package' => 'app/packages/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MantisBTInstaller.php
DELETED
@@ -1,23 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\DependencyResolver\Pool;
|
5 |
-
|
6 |
-
class MantisBTInstaller extends BaseInstaller
|
7 |
-
{
|
8 |
-
protected $locations = array(
|
9 |
-
'plugin' => 'plugins/{$name}/',
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name to CamelCase
|
14 |
-
*/
|
15 |
-
public function inflectPackageVars($vars)
|
16 |
-
{
|
17 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
18 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
19 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
20 |
-
|
21 |
-
return $vars;
|
22 |
-
}
|
23 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MauticInstaller.php
DELETED
@@ -1,48 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\Package\PackageInterface;
|
5 |
-
|
6 |
-
class MauticInstaller extends BaseInstaller
|
7 |
-
{
|
8 |
-
protected $locations = array(
|
9 |
-
'plugin' => 'plugins/{$name}/',
|
10 |
-
'theme' => 'themes/{$name}/',
|
11 |
-
'core' => 'app/',
|
12 |
-
);
|
13 |
-
|
14 |
-
private function getDirectoryName()
|
15 |
-
{
|
16 |
-
$extra = $this->package->getExtra();
|
17 |
-
if (!empty($extra['install-directory-name'])) {
|
18 |
-
return $extra['install-directory-name'];
|
19 |
-
}
|
20 |
-
|
21 |
-
return $this->toCamelCase($this->package->getPrettyName());
|
22 |
-
}
|
23 |
-
|
24 |
-
/**
|
25 |
-
* @param string $packageName
|
26 |
-
*
|
27 |
-
* @return string
|
28 |
-
*/
|
29 |
-
private function toCamelCase($packageName)
|
30 |
-
{
|
31 |
-
return str_replace(' ', '', ucwords(str_replace('-', ' ', basename($packageName))));
|
32 |
-
}
|
33 |
-
|
34 |
-
/**
|
35 |
-
* Format package name of mautic-plugins to CamelCase
|
36 |
-
*/
|
37 |
-
public function inflectPackageVars($vars)
|
38 |
-
{
|
39 |
-
|
40 |
-
if ($vars['type'] == 'mautic-plugin' || $vars['type'] == 'mautic-theme') {
|
41 |
-
$directoryName = $this->getDirectoryName();
|
42 |
-
$vars['name'] = $directoryName;
|
43 |
-
}
|
44 |
-
|
45 |
-
return $vars;
|
46 |
-
}
|
47 |
-
|
48 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MayaInstaller.php
DELETED
@@ -1,33 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MayaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Format package name.
|
12 |
-
*
|
13 |
-
* For package type maya-module, cut off a trailing '-module' if present.
|
14 |
-
*
|
15 |
-
*/
|
16 |
-
public function inflectPackageVars($vars)
|
17 |
-
{
|
18 |
-
if ($vars['type'] === 'maya-module') {
|
19 |
-
return $this->inflectModuleVars($vars);
|
20 |
-
}
|
21 |
-
|
22 |
-
return $vars;
|
23 |
-
}
|
24 |
-
|
25 |
-
protected function inflectModuleVars($vars)
|
26 |
-
{
|
27 |
-
$vars['name'] = preg_replace('/-module$/', '', $vars['name']);
|
28 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
29 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
30 |
-
|
31 |
-
return $vars;
|
32 |
-
}
|
33 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MediaWikiInstaller.php
DELETED
@@ -1,51 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MediaWikiInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'core' => 'core/',
|
8 |
-
'extension' => 'extensions/{$name}/',
|
9 |
-
'skin' => 'skins/{$name}/',
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name.
|
14 |
-
*
|
15 |
-
* For package type mediawiki-extension, cut off a trailing '-extension' if present and transform
|
16 |
-
* to CamelCase keeping existing uppercase chars.
|
17 |
-
*
|
18 |
-
* For package type mediawiki-skin, cut off a trailing '-skin' if present.
|
19 |
-
*
|
20 |
-
*/
|
21 |
-
public function inflectPackageVars($vars)
|
22 |
-
{
|
23 |
-
|
24 |
-
if ($vars['type'] === 'mediawiki-extension') {
|
25 |
-
return $this->inflectExtensionVars($vars);
|
26 |
-
}
|
27 |
-
|
28 |
-
if ($vars['type'] === 'mediawiki-skin') {
|
29 |
-
return $this->inflectSkinVars($vars);
|
30 |
-
}
|
31 |
-
|
32 |
-
return $vars;
|
33 |
-
}
|
34 |
-
|
35 |
-
protected function inflectExtensionVars($vars)
|
36 |
-
{
|
37 |
-
$vars['name'] = preg_replace('/-extension$/', '', $vars['name']);
|
38 |
-
$vars['name'] = str_replace('-', ' ', $vars['name']);
|
39 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
40 |
-
|
41 |
-
return $vars;
|
42 |
-
}
|
43 |
-
|
44 |
-
protected function inflectSkinVars($vars)
|
45 |
-
{
|
46 |
-
$vars['name'] = preg_replace('/-skin$/', '', $vars['name']);
|
47 |
-
|
48 |
-
return $vars;
|
49 |
-
}
|
50 |
-
|
51 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MiaoxingInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class MiaoxingInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'plugin' => 'plugins/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MicroweberInstaller.php
DELETED
@@ -1,119 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MicroweberInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'userfiles/modules/{$install_item_dir}/',
|
8 |
-
'module-skin' => 'userfiles/modules/{$install_item_dir}/templates/',
|
9 |
-
'template' => 'userfiles/templates/{$install_item_dir}/',
|
10 |
-
'element' => 'userfiles/elements/{$install_item_dir}/',
|
11 |
-
'vendor' => 'vendor/{$install_item_dir}/',
|
12 |
-
'components' => 'components/{$install_item_dir}/'
|
13 |
-
);
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Format package name.
|
17 |
-
*
|
18 |
-
* For package type microweber-module, cut off a trailing '-module' if present
|
19 |
-
*
|
20 |
-
* For package type microweber-template, cut off a trailing '-template' if present.
|
21 |
-
*
|
22 |
-
*/
|
23 |
-
public function inflectPackageVars($vars)
|
24 |
-
{
|
25 |
-
|
26 |
-
|
27 |
-
if ($this->package->getTargetDir()) {
|
28 |
-
$vars['install_item_dir'] = $this->package->getTargetDir();
|
29 |
-
} else {
|
30 |
-
$vars['install_item_dir'] = $vars['name'];
|
31 |
-
if ($vars['type'] === 'microweber-template') {
|
32 |
-
return $this->inflectTemplateVars($vars);
|
33 |
-
}
|
34 |
-
if ($vars['type'] === 'microweber-templates') {
|
35 |
-
return $this->inflectTemplatesVars($vars);
|
36 |
-
}
|
37 |
-
if ($vars['type'] === 'microweber-core') {
|
38 |
-
return $this->inflectCoreVars($vars);
|
39 |
-
}
|
40 |
-
if ($vars['type'] === 'microweber-adapter') {
|
41 |
-
return $this->inflectCoreVars($vars);
|
42 |
-
}
|
43 |
-
if ($vars['type'] === 'microweber-module') {
|
44 |
-
return $this->inflectModuleVars($vars);
|
45 |
-
}
|
46 |
-
if ($vars['type'] === 'microweber-modules') {
|
47 |
-
return $this->inflectModulesVars($vars);
|
48 |
-
}
|
49 |
-
if ($vars['type'] === 'microweber-skin') {
|
50 |
-
return $this->inflectSkinVars($vars);
|
51 |
-
}
|
52 |
-
if ($vars['type'] === 'microweber-element' or $vars['type'] === 'microweber-elements') {
|
53 |
-
return $this->inflectElementVars($vars);
|
54 |
-
}
|
55 |
-
}
|
56 |
-
|
57 |
-
|
58 |
-
return $vars;
|
59 |
-
}
|
60 |
-
|
61 |
-
protected function inflectTemplateVars($vars)
|
62 |
-
{
|
63 |
-
$vars['install_item_dir'] = preg_replace('/-template$/', '', $vars['install_item_dir']);
|
64 |
-
$vars['install_item_dir'] = preg_replace('/template-$/', '', $vars['install_item_dir']);
|
65 |
-
|
66 |
-
return $vars;
|
67 |
-
}
|
68 |
-
|
69 |
-
protected function inflectTemplatesVars($vars)
|
70 |
-
{
|
71 |
-
$vars['install_item_dir'] = preg_replace('/-templates$/', '', $vars['install_item_dir']);
|
72 |
-
$vars['install_item_dir'] = preg_replace('/templates-$/', '', $vars['install_item_dir']);
|
73 |
-
|
74 |
-
return $vars;
|
75 |
-
}
|
76 |
-
|
77 |
-
protected function inflectCoreVars($vars)
|
78 |
-
{
|
79 |
-
$vars['install_item_dir'] = preg_replace('/-providers$/', '', $vars['install_item_dir']);
|
80 |
-
$vars['install_item_dir'] = preg_replace('/-provider$/', '', $vars['install_item_dir']);
|
81 |
-
$vars['install_item_dir'] = preg_replace('/-adapter$/', '', $vars['install_item_dir']);
|
82 |
-
|
83 |
-
return $vars;
|
84 |
-
}
|
85 |
-
|
86 |
-
protected function inflectModuleVars($vars)
|
87 |
-
{
|
88 |
-
$vars['install_item_dir'] = preg_replace('/-module$/', '', $vars['install_item_dir']);
|
89 |
-
$vars['install_item_dir'] = preg_replace('/module-$/', '', $vars['install_item_dir']);
|
90 |
-
|
91 |
-
return $vars;
|
92 |
-
}
|
93 |
-
|
94 |
-
protected function inflectModulesVars($vars)
|
95 |
-
{
|
96 |
-
$vars['install_item_dir'] = preg_replace('/-modules$/', '', $vars['install_item_dir']);
|
97 |
-
$vars['install_item_dir'] = preg_replace('/modules-$/', '', $vars['install_item_dir']);
|
98 |
-
|
99 |
-
return $vars;
|
100 |
-
}
|
101 |
-
|
102 |
-
protected function inflectSkinVars($vars)
|
103 |
-
{
|
104 |
-
$vars['install_item_dir'] = preg_replace('/-skin$/', '', $vars['install_item_dir']);
|
105 |
-
$vars['install_item_dir'] = preg_replace('/skin-$/', '', $vars['install_item_dir']);
|
106 |
-
|
107 |
-
return $vars;
|
108 |
-
}
|
109 |
-
|
110 |
-
protected function inflectElementVars($vars)
|
111 |
-
{
|
112 |
-
$vars['install_item_dir'] = preg_replace('/-elements$/', '', $vars['install_item_dir']);
|
113 |
-
$vars['install_item_dir'] = preg_replace('/elements-$/', '', $vars['install_item_dir']);
|
114 |
-
$vars['install_item_dir'] = preg_replace('/-element$/', '', $vars['install_item_dir']);
|
115 |
-
$vars['install_item_dir'] = preg_replace('/element-$/', '', $vars['install_item_dir']);
|
116 |
-
|
117 |
-
return $vars;
|
118 |
-
}
|
119 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ModxInstaller.php
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* An installer to handle MODX specifics when installing packages.
|
6 |
-
*/
|
7 |
-
class ModxInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
protected $locations = array(
|
10 |
-
'extra' => 'core/packages/{$name}/'
|
11 |
-
);
|
12 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/MoodleInstaller.php
DELETED
@@ -1,59 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class MoodleInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'mod' => 'mod/{$name}/',
|
8 |
-
'admin_report' => 'admin/report/{$name}/',
|
9 |
-
'atto' => 'lib/editor/atto/plugins/{$name}/',
|
10 |
-
'tool' => 'admin/tool/{$name}/',
|
11 |
-
'assignment' => 'mod/assignment/type/{$name}/',
|
12 |
-
'assignsubmission' => 'mod/assign/submission/{$name}/',
|
13 |
-
'assignfeedback' => 'mod/assign/feedback/{$name}/',
|
14 |
-
'auth' => 'auth/{$name}/',
|
15 |
-
'availability' => 'availability/condition/{$name}/',
|
16 |
-
'block' => 'blocks/{$name}/',
|
17 |
-
'booktool' => 'mod/book/tool/{$name}/',
|
18 |
-
'cachestore' => 'cache/stores/{$name}/',
|
19 |
-
'cachelock' => 'cache/locks/{$name}/',
|
20 |
-
'calendartype' => 'calendar/type/{$name}/',
|
21 |
-
'fileconverter' => 'files/converter/{$name}/',
|
22 |
-
'format' => 'course/format/{$name}/',
|
23 |
-
'coursereport' => 'course/report/{$name}/',
|
24 |
-
'customcertelement' => 'mod/customcert/element/{$name}/',
|
25 |
-
'datafield' => 'mod/data/field/{$name}/',
|
26 |
-
'datapreset' => 'mod/data/preset/{$name}/',
|
27 |
-
'editor' => 'lib/editor/{$name}/',
|
28 |
-
'enrol' => 'enrol/{$name}/',
|
29 |
-
'filter' => 'filter/{$name}/',
|
30 |
-
'gradeexport' => 'grade/export/{$name}/',
|
31 |
-
'gradeimport' => 'grade/import/{$name}/',
|
32 |
-
'gradereport' => 'grade/report/{$name}/',
|
33 |
-
'gradingform' => 'grade/grading/form/{$name}/',
|
34 |
-
'local' => 'local/{$name}/',
|
35 |
-
'logstore' => 'admin/tool/log/store/{$name}/',
|
36 |
-
'ltisource' => 'mod/lti/source/{$name}/',
|
37 |
-
'ltiservice' => 'mod/lti/service/{$name}/',
|
38 |
-
'message' => 'message/output/{$name}/',
|
39 |
-
'mnetservice' => 'mnet/service/{$name}/',
|
40 |
-
'plagiarism' => 'plagiarism/{$name}/',
|
41 |
-
'portfolio' => 'portfolio/{$name}/',
|
42 |
-
'qbehaviour' => 'question/behaviour/{$name}/',
|
43 |
-
'qformat' => 'question/format/{$name}/',
|
44 |
-
'qtype' => 'question/type/{$name}/',
|
45 |
-
'quizaccess' => 'mod/quiz/accessrule/{$name}/',
|
46 |
-
'quiz' => 'mod/quiz/report/{$name}/',
|
47 |
-
'report' => 'report/{$name}/',
|
48 |
-
'repository' => 'repository/{$name}/',
|
49 |
-
'scormreport' => 'mod/scorm/report/{$name}/',
|
50 |
-
'search' => 'search/engine/{$name}/',
|
51 |
-
'theme' => 'theme/{$name}/',
|
52 |
-
'tinymce' => 'lib/editor/tinymce/plugins/{$name}/',
|
53 |
-
'profilefield' => 'user/profile/field/{$name}/',
|
54 |
-
'webservice' => 'webservice/{$name}/',
|
55 |
-
'workshopallocation' => 'mod/workshop/allocation/{$name}/',
|
56 |
-
'workshopeval' => 'mod/workshop/eval/{$name}/',
|
57 |
-
'workshopform' => 'mod/workshop/form/{$name}/'
|
58 |
-
);
|
59 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OctoberInstaller.php
DELETED
@@ -1,48 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class OctoberInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
'plugin' => 'plugins/{$vendor}/{$name}/',
|
9 |
-
'theme' => 'themes/{$vendor}-{$name}/'
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name.
|
14 |
-
*
|
15 |
-
* For package type october-plugin, cut off a trailing '-plugin' if present.
|
16 |
-
*
|
17 |
-
* For package type october-theme, cut off a trailing '-theme' if present.
|
18 |
-
*
|
19 |
-
*/
|
20 |
-
public function inflectPackageVars($vars)
|
21 |
-
{
|
22 |
-
if ($vars['type'] === 'october-plugin') {
|
23 |
-
return $this->inflectPluginVars($vars);
|
24 |
-
}
|
25 |
-
|
26 |
-
if ($vars['type'] === 'october-theme') {
|
27 |
-
return $this->inflectThemeVars($vars);
|
28 |
-
}
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
|
33 |
-
protected function inflectPluginVars($vars)
|
34 |
-
{
|
35 |
-
$vars['name'] = preg_replace('/^oc-|-plugin$/', '', $vars['name']);
|
36 |
-
$vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
|
37 |
-
|
38 |
-
return $vars;
|
39 |
-
}
|
40 |
-
|
41 |
-
protected function inflectThemeVars($vars)
|
42 |
-
{
|
43 |
-
$vars['name'] = preg_replace('/^oc-|-theme$/', '', $vars['name']);
|
44 |
-
$vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
|
45 |
-
|
46 |
-
return $vars;
|
47 |
-
}
|
48 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php
DELETED
@@ -1,24 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class OntoWikiInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'extension' => 'extensions/{$name}/',
|
8 |
-
'theme' => 'extensions/themes/{$name}/',
|
9 |
-
'translation' => 'extensions/translations/{$name}/',
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name to lower case and remove ".ontowiki" suffix
|
14 |
-
*/
|
15 |
-
public function inflectPackageVars($vars)
|
16 |
-
{
|
17 |
-
$vars['name'] = strtolower($vars['name']);
|
18 |
-
$vars['name'] = preg_replace('/.ontowiki$/', '', $vars['name']);
|
19 |
-
$vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
|
20 |
-
$vars['name'] = preg_replace('/-translation$/', '', $vars['name']);
|
21 |
-
|
22 |
-
return $vars;
|
23 |
-
}
|
24 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php
DELETED
@@ -1,14 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
|
5 |
-
class OsclassInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
|
8 |
-
protected $locations = array(
|
9 |
-
'plugin' => 'oc-content/plugins/{$name}/',
|
10 |
-
'theme' => 'oc-content/themes/{$name}/',
|
11 |
-
'language' => 'oc-content/languages/{$name}/',
|
12 |
-
);
|
13 |
-
|
14 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/OxidInstaller.php
DELETED
@@ -1,59 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\Package\PackageInterface;
|
5 |
-
|
6 |
-
class OxidInstaller extends BaseInstaller
|
7 |
-
{
|
8 |
-
const VENDOR_PATTERN = '/^modules\/(?P<vendor>.+)\/.+/';
|
9 |
-
|
10 |
-
protected $locations = array(
|
11 |
-
'module' => 'modules/{$name}/',
|
12 |
-
'theme' => 'application/views/{$name}/',
|
13 |
-
'out' => 'out/{$name}/',
|
14 |
-
);
|
15 |
-
|
16 |
-
/**
|
17 |
-
* getInstallPath
|
18 |
-
*
|
19 |
-
* @param PackageInterface $package
|
20 |
-
* @param string $frameworkType
|
21 |
-
* @return string
|
22 |
-
*/
|
23 |
-
public function getInstallPath(PackageInterface $package, $frameworkType = '')
|
24 |
-
{
|
25 |
-
$installPath = parent::getInstallPath($package, $frameworkType);
|
26 |
-
$type = $this->package->getType();
|
27 |
-
if ($type === 'oxid-module') {
|
28 |
-
$this->prepareVendorDirectory($installPath);
|
29 |
-
}
|
30 |
-
return $installPath;
|
31 |
-
}
|
32 |
-
|
33 |
-
/**
|
34 |
-
* prepareVendorDirectory
|
35 |
-
*
|
36 |
-
* Makes sure there is a vendormetadata.php file inside
|
37 |
-
* the vendor folder if there is a vendor folder.
|
38 |
-
*
|
39 |
-
* @param string $installPath
|
40 |
-
* @return void
|
41 |
-
*/
|
42 |
-
protected function prepareVendorDirectory($installPath)
|
43 |
-
{
|
44 |
-
$matches = '';
|
45 |
-
$hasVendorDirectory = preg_match(self::VENDOR_PATTERN, $installPath, $matches);
|
46 |
-
if (!$hasVendorDirectory) {
|
47 |
-
return;
|
48 |
-
}
|
49 |
-
|
50 |
-
$vendorDirectory = $matches['vendor'];
|
51 |
-
$vendorPath = getcwd() . '/modules/' . $vendorDirectory;
|
52 |
-
if (!file_exists($vendorPath)) {
|
53 |
-
mkdir($vendorPath, 0755, true);
|
54 |
-
}
|
55 |
-
|
56 |
-
$vendorMetaDataPath = $vendorPath . '/vendormetadata.php';
|
57 |
-
touch($vendorMetaDataPath);
|
58 |
-
}
|
59 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PPIInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PPIInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PhiftyInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'bundle' => 'bundles/{$name}/',
|
8 |
-
'library' => 'libraries/{$name}/',
|
9 |
-
'framework' => 'frameworks/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PhpBBInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PhpBBInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'extension' => 'ext/{$vendor}/{$name}/',
|
8 |
-
'language' => 'language/{$name}/',
|
9 |
-
'style' => 'styles/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PimcoreInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'plugins/{$name}/',
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Format package name to CamelCase
|
12 |
-
*/
|
13 |
-
public function inflectPackageVars($vars)
|
14 |
-
{
|
15 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
16 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
17 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
18 |
-
|
19 |
-
return $vars;
|
20 |
-
}
|
21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php
DELETED
@@ -1,32 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Class PiwikInstaller
|
6 |
-
*
|
7 |
-
* @package Composer\Installers
|
8 |
-
*/
|
9 |
-
class PiwikInstaller extends BaseInstaller
|
10 |
-
{
|
11 |
-
/**
|
12 |
-
* @var array
|
13 |
-
*/
|
14 |
-
protected $locations = array(
|
15 |
-
'plugin' => 'plugins/{$name}/',
|
16 |
-
);
|
17 |
-
|
18 |
-
/**
|
19 |
-
* Format package name to CamelCase
|
20 |
-
* @param array $vars
|
21 |
-
*
|
22 |
-
* @return array
|
23 |
-
*/
|
24 |
-
public function inflectPackageVars($vars)
|
25 |
-
{
|
26 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
27 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
28 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php
DELETED
@@ -1,29 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PlentymarketsInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => '{$name}/'
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Remove hyphen, "plugin" and format to camelcase
|
12 |
-
* @param array $vars
|
13 |
-
*
|
14 |
-
* @return array
|
15 |
-
*/
|
16 |
-
public function inflectPackageVars($vars)
|
17 |
-
{
|
18 |
-
$vars['name'] = explode("-", $vars['name']);
|
19 |
-
foreach ($vars['name'] as $key => $name) {
|
20 |
-
$vars['name'][$key] = ucfirst($vars['name'][$key]);
|
21 |
-
if (strcasecmp($name, "Plugin") == 0) {
|
22 |
-
unset($vars['name'][$key]);
|
23 |
-
}
|
24 |
-
}
|
25 |
-
$vars['name'] = implode("",$vars['name']);
|
26 |
-
|
27 |
-
return $vars;
|
28 |
-
}
|
29 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Plugin.php
DELETED
@@ -1,27 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
use Composer\Composer;
|
6 |
-
use Composer\IO\IOInterface;
|
7 |
-
use Composer\Plugin\PluginInterface;
|
8 |
-
|
9 |
-
class Plugin implements PluginInterface
|
10 |
-
{
|
11 |
-
private $installer;
|
12 |
-
|
13 |
-
public function activate(Composer $composer, IOInterface $io)
|
14 |
-
{
|
15 |
-
$this->installer = new Installer($io, $composer);
|
16 |
-
$composer->getInstallationManager()->addInstaller($this->installer);
|
17 |
-
}
|
18 |
-
|
19 |
-
public function deactivate(Composer $composer, IOInterface $io)
|
20 |
-
{
|
21 |
-
$composer->getInstallationManager()->removeInstaller($this->installer);
|
22 |
-
}
|
23 |
-
|
24 |
-
public function uninstall(Composer $composer, IOInterface $io)
|
25 |
-
{
|
26 |
-
}
|
27 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PortoInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PortoInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'container' => 'app/Containers/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PrestashopInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PrestashopInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ProcessWireInstaller.php
DELETED
@@ -1,22 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class ProcessWireInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'module' => 'site/modules/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name to CamelCase
|
13 |
-
*/
|
14 |
-
public function inflectPackageVars($vars)
|
15 |
-
{
|
16 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
17 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
18 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
19 |
-
|
20 |
-
return $vars;
|
21 |
-
}
|
22 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PuppetInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class PuppetInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
|
8 |
-
protected $locations = array(
|
9 |
-
'module' => 'modules/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/PxcmsInstaller.php
DELETED
@@ -1,63 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class PxcmsInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'app/Modules/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name.
|
13 |
-
*
|
14 |
-
* @param array $vars
|
15 |
-
*
|
16 |
-
* @return array
|
17 |
-
*/
|
18 |
-
public function inflectPackageVars($vars)
|
19 |
-
{
|
20 |
-
if ($vars['type'] === 'pxcms-module') {
|
21 |
-
return $this->inflectModuleVars($vars);
|
22 |
-
}
|
23 |
-
|
24 |
-
if ($vars['type'] === 'pxcms-theme') {
|
25 |
-
return $this->inflectThemeVars($vars);
|
26 |
-
}
|
27 |
-
|
28 |
-
return $vars;
|
29 |
-
}
|
30 |
-
|
31 |
-
/**
|
32 |
-
* For package type pxcms-module, cut off a trailing '-plugin' if present.
|
33 |
-
*
|
34 |
-
* return string
|
35 |
-
*/
|
36 |
-
protected function inflectModuleVars($vars)
|
37 |
-
{
|
38 |
-
$vars['name'] = str_replace('pxcms-', '', $vars['name']); // strip out pxcms- just incase (legacy)
|
39 |
-
$vars['name'] = str_replace('module-', '', $vars['name']); // strip out module-
|
40 |
-
$vars['name'] = preg_replace('/-module$/', '', $vars['name']); // strip out -module
|
41 |
-
$vars['name'] = str_replace('-', '_', $vars['name']); // make -'s be _'s
|
42 |
-
$vars['name'] = ucwords($vars['name']); // make module name camelcased
|
43 |
-
|
44 |
-
return $vars;
|
45 |
-
}
|
46 |
-
|
47 |
-
|
48 |
-
/**
|
49 |
-
* For package type pxcms-module, cut off a trailing '-plugin' if present.
|
50 |
-
*
|
51 |
-
* return string
|
52 |
-
*/
|
53 |
-
protected function inflectThemeVars($vars)
|
54 |
-
{
|
55 |
-
$vars['name'] = str_replace('pxcms-', '', $vars['name']); // strip out pxcms- just incase (legacy)
|
56 |
-
$vars['name'] = str_replace('theme-', '', $vars['name']); // strip out theme-
|
57 |
-
$vars['name'] = preg_replace('/-theme$/', '', $vars['name']); // strip out -theme
|
58 |
-
$vars['name'] = str_replace('-', '_', $vars['name']); // make -'s be _'s
|
59 |
-
$vars['name'] = ucwords($vars['name']); // make module name camelcased
|
60 |
-
|
61 |
-
return $vars;
|
62 |
-
}
|
63 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php
DELETED
@@ -1,24 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class RadPHPInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'bundle' => 'src/{$name}/'
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Format package name to CamelCase
|
12 |
-
*/
|
13 |
-
public function inflectPackageVars($vars)
|
14 |
-
{
|
15 |
-
$nameParts = explode('/', $vars['name']);
|
16 |
-
foreach ($nameParts as &$value) {
|
17 |
-
$value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
|
18 |
-
$value = str_replace(array('-', '_'), ' ', $value);
|
19 |
-
$value = str_replace(' ', '', ucwords($value));
|
20 |
-
}
|
21 |
-
$vars['name'] = implode('/', $nameParts);
|
22 |
-
return $vars;
|
23 |
-
}
|
24 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ReIndexInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ReIndexInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'theme' => 'themes/{$name}/',
|
8 |
-
'plugin' => 'plugins/{$name}/'
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Redaxo5Installer.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class Redaxo5Installer extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'addon' => 'redaxo/src/addons/{$name}/',
|
8 |
-
'bestyle-plugin' => 'redaxo/src/addons/be_style/plugins/{$name}/'
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RedaxoInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class RedaxoInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'addon' => 'redaxo/include/addons/{$name}/',
|
8 |
-
'bestyle-plugin' => 'redaxo/include/addons/be_style/plugins/{$name}/'
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/RoundcubeInstaller.php
DELETED
@@ -1,22 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class RoundcubeInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'plugins/{$name}/',
|
8 |
-
);
|
9 |
-
|
10 |
-
/**
|
11 |
-
* Lowercase name and changes the name to a underscores
|
12 |
-
*
|
13 |
-
* @param array $vars
|
14 |
-
* @return array
|
15 |
-
*/
|
16 |
-
public function inflectPackageVars($vars)
|
17 |
-
{
|
18 |
-
$vars['name'] = strtolower(str_replace('-', '_', $vars['name']));
|
19 |
-
|
20 |
-
return $vars;
|
21 |
-
}
|
22 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SMFInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class SMFInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'Sources/{$name}/',
|
8 |
-
'theme' => 'Themes/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ShopwareInstaller.php
DELETED
@@ -1,60 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Plugin/theme installer for shopware
|
6 |
-
* @author Benjamin Boit
|
7 |
-
*/
|
8 |
-
class ShopwareInstaller extends BaseInstaller
|
9 |
-
{
|
10 |
-
protected $locations = array(
|
11 |
-
'backend-plugin' => 'engine/Shopware/Plugins/Local/Backend/{$name}/',
|
12 |
-
'core-plugin' => 'engine/Shopware/Plugins/Local/Core/{$name}/',
|
13 |
-
'frontend-plugin' => 'engine/Shopware/Plugins/Local/Frontend/{$name}/',
|
14 |
-
'theme' => 'templates/{$name}/',
|
15 |
-
'plugin' => 'custom/plugins/{$name}/',
|
16 |
-
'frontend-theme' => 'themes/Frontend/{$name}/',
|
17 |
-
);
|
18 |
-
|
19 |
-
/**
|
20 |
-
* Transforms the names
|
21 |
-
* @param array $vars
|
22 |
-
* @return array
|
23 |
-
*/
|
24 |
-
public function inflectPackageVars($vars)
|
25 |
-
{
|
26 |
-
if ($vars['type'] === 'shopware-theme') {
|
27 |
-
return $this->correctThemeName($vars);
|
28 |
-
}
|
29 |
-
|
30 |
-
return $this->correctPluginName($vars);
|
31 |
-
}
|
32 |
-
|
33 |
-
/**
|
34 |
-
* Changes the name to a camelcased combination of vendor and name
|
35 |
-
* @param array $vars
|
36 |
-
* @return array
|
37 |
-
*/
|
38 |
-
private function correctPluginName($vars)
|
39 |
-
{
|
40 |
-
$camelCasedName = preg_replace_callback('/(-[a-z])/', function ($matches) {
|
41 |
-
return strtoupper($matches[0][1]);
|
42 |
-
}, $vars['name']);
|
43 |
-
|
44 |
-
$vars['name'] = ucfirst($vars['vendor']) . ucfirst($camelCasedName);
|
45 |
-
|
46 |
-
return $vars;
|
47 |
-
}
|
48 |
-
|
49 |
-
/**
|
50 |
-
* Changes the name to a underscore separated name
|
51 |
-
* @param array $vars
|
52 |
-
* @return array
|
53 |
-
*/
|
54 |
-
private function correctThemeName($vars)
|
55 |
-
{
|
56 |
-
$vars['name'] = str_replace('-', '_', $vars['name']);
|
57 |
-
|
58 |
-
return $vars;
|
59 |
-
}
|
60 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SilverStripeInstaller.php
DELETED
@@ -1,35 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
use Composer\Package\PackageInterface;
|
5 |
-
|
6 |
-
class SilverStripeInstaller extends BaseInstaller
|
7 |
-
{
|
8 |
-
protected $locations = array(
|
9 |
-
'module' => '{$name}/',
|
10 |
-
'theme' => 'themes/{$name}/',
|
11 |
-
);
|
12 |
-
|
13 |
-
/**
|
14 |
-
* Return the install path based on package type.
|
15 |
-
*
|
16 |
-
* Relies on built-in BaseInstaller behaviour with one exception: silverstripe/framework
|
17 |
-
* must be installed to 'sapphire' and not 'framework' if the version is <3.0.0
|
18 |
-
*
|
19 |
-
* @param PackageInterface $package
|
20 |
-
* @param string $frameworkType
|
21 |
-
* @return string
|
22 |
-
*/
|
23 |
-
public function getInstallPath(PackageInterface $package, $frameworkType = '')
|
24 |
-
{
|
25 |
-
if (
|
26 |
-
$package->getName() == 'silverstripe/framework'
|
27 |
-
&& preg_match('/^\d+\.\d+\.\d+/', $package->getVersion())
|
28 |
-
&& version_compare($package->getVersion(), '2.999.999') < 0
|
29 |
-
) {
|
30 |
-
return $this->templatePath($this->locations['module'], array('name' => 'sapphire'));
|
31 |
-
}
|
32 |
-
|
33 |
-
return parent::getInstallPath($package, $frameworkType);
|
34 |
-
}
|
35 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php
DELETED
@@ -1,25 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class SiteDirectInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'module' => 'modules/{$vendor}/{$name}/',
|
9 |
-
'plugin' => 'plugins/{$vendor}/{$name}/'
|
10 |
-
);
|
11 |
-
|
12 |
-
public function inflectPackageVars($vars)
|
13 |
-
{
|
14 |
-
return $this->parseVars($vars);
|
15 |
-
}
|
16 |
-
|
17 |
-
protected function parseVars($vars)
|
18 |
-
{
|
19 |
-
$vars['vendor'] = strtolower($vars['vendor']) == 'sitedirect' ? 'SiteDirect' : $vars['vendor'];
|
20 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
21 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
22 |
-
|
23 |
-
return $vars;
|
24 |
-
}
|
25 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/StarbugInstaller.php
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class StarbugInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/',
|
9 |
-
'custom-module' => 'app/modules/{$name}/',
|
10 |
-
'custom-theme' => 'app/themes/{$name}/'
|
11 |
-
);
|
12 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SyDESInstaller.php
DELETED
@@ -1,47 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class SyDESInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'app/modules/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/',
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format module name.
|
13 |
-
*
|
14 |
-
* Strip `sydes-` prefix and a trailing '-theme' or '-module' from package name if present.
|
15 |
-
*
|
16 |
-
* {@inerhitDoc}
|
17 |
-
*/
|
18 |
-
public function inflectPackageVars($vars)
|
19 |
-
{
|
20 |
-
if ($vars['type'] == 'sydes-module') {
|
21 |
-
return $this->inflectModuleVars($vars);
|
22 |
-
}
|
23 |
-
|
24 |
-
if ($vars['type'] === 'sydes-theme') {
|
25 |
-
return $this->inflectThemeVars($vars);
|
26 |
-
}
|
27 |
-
|
28 |
-
return $vars;
|
29 |
-
}
|
30 |
-
|
31 |
-
public function inflectModuleVars($vars)
|
32 |
-
{
|
33 |
-
$vars['name'] = preg_replace('/(^sydes-|-module$)/i', '', $vars['name']);
|
34 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
35 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
36 |
-
|
37 |
-
return $vars;
|
38 |
-
}
|
39 |
-
|
40 |
-
protected function inflectThemeVars($vars)
|
41 |
-
{
|
42 |
-
$vars['name'] = preg_replace('/(^sydes-|-theme$)/', '', $vars['name']);
|
43 |
-
$vars['name'] = strtolower($vars['name']);
|
44 |
-
|
45 |
-
return $vars;
|
46 |
-
}
|
47 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/SyliusInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class SyliusInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'theme' => 'themes/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/Symfony1Installer.php
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Plugin installer for symfony 1.x
|
6 |
-
*
|
7 |
-
* @author Jérôme Tamarelle <jerome@tamarelle.net>
|
8 |
-
*/
|
9 |
-
class Symfony1Installer extends BaseInstaller
|
10 |
-
{
|
11 |
-
protected $locations = array(
|
12 |
-
'plugin' => 'plugins/{$name}/',
|
13 |
-
);
|
14 |
-
|
15 |
-
/**
|
16 |
-
* Format package name to CamelCase
|
17 |
-
*/
|
18 |
-
public function inflectPackageVars($vars)
|
19 |
-
{
|
20 |
-
$vars['name'] = preg_replace_callback('/(-[a-z])/', function ($matches) {
|
21 |
-
return strtoupper($matches[0][1]);
|
22 |
-
}, $vars['name']);
|
23 |
-
|
24 |
-
return $vars;
|
25 |
-
}
|
26 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php
DELETED
@@ -1,16 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* Extension installer for TYPO3 CMS
|
6 |
-
*
|
7 |
-
* @deprecated since 1.0.25, use https://packagist.org/packages/typo3/cms-composer-installers instead
|
8 |
-
*
|
9 |
-
* @author Sascha Egerer <sascha.egerer@dkd.de>
|
10 |
-
*/
|
11 |
-
class TYPO3CmsInstaller extends BaseInstaller
|
12 |
-
{
|
13 |
-
protected $locations = array(
|
14 |
-
'extension' => 'typo3conf/ext/{$name}/',
|
15 |
-
);
|
16 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php
DELETED
@@ -1,38 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* An installer to handle TYPO3 Flow specifics when installing packages.
|
6 |
-
*/
|
7 |
-
class TYPO3FlowInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
protected $locations = array(
|
10 |
-
'package' => 'Packages/Application/{$name}/',
|
11 |
-
'framework' => 'Packages/Framework/{$name}/',
|
12 |
-
'plugin' => 'Packages/Plugins/{$name}/',
|
13 |
-
'site' => 'Packages/Sites/{$name}/',
|
14 |
-
'boilerplate' => 'Packages/Boilerplates/{$name}/',
|
15 |
-
'build' => 'Build/{$name}/',
|
16 |
-
);
|
17 |
-
|
18 |
-
/**
|
19 |
-
* Modify the package name to be a TYPO3 Flow style key.
|
20 |
-
*
|
21 |
-
* @param array $vars
|
22 |
-
* @return array
|
23 |
-
*/
|
24 |
-
public function inflectPackageVars($vars)
|
25 |
-
{
|
26 |
-
$autoload = $this->package->getAutoload();
|
27 |
-
if (isset($autoload['psr-0']) && is_array($autoload['psr-0'])) {
|
28 |
-
$namespace = key($autoload['psr-0']);
|
29 |
-
$vars['name'] = str_replace('\\', '.', $namespace);
|
30 |
-
}
|
31 |
-
if (isset($autoload['psr-4']) && is_array($autoload['psr-4'])) {
|
32 |
-
$namespace = key($autoload['psr-4']);
|
33 |
-
$vars['name'] = rtrim(str_replace('\\', '.', $namespace), '.');
|
34 |
-
}
|
35 |
-
|
36 |
-
return $vars;
|
37 |
-
}
|
38 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TaoInstaller.php
DELETED
@@ -1,30 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
/**
|
5 |
-
* An installer to handle TAO extensions.
|
6 |
-
*/
|
7 |
-
class TaoInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
const EXTRA_TAO_EXTENSION_NAME = 'tao-extension-name';
|
10 |
-
|
11 |
-
protected $locations = array(
|
12 |
-
'extension' => '{$name}'
|
13 |
-
);
|
14 |
-
|
15 |
-
public function inflectPackageVars($vars)
|
16 |
-
{
|
17 |
-
$extra = $this->package->getExtra();
|
18 |
-
|
19 |
-
if (array_key_exists(self::EXTRA_TAO_EXTENSION_NAME, $extra)) {
|
20 |
-
$vars['name'] = $extra[self::EXTRA_TAO_EXTENSION_NAME];
|
21 |
-
return $vars;
|
22 |
-
}
|
23 |
-
|
24 |
-
$vars['name'] = str_replace('extension-', '', $vars['name']);
|
25 |
-
$vars['name'] = str_replace('-', ' ', $vars['name']);
|
26 |
-
$vars['name'] = lcfirst(str_replace(' ', '', ucwords($vars['name'])));
|
27 |
-
|
28 |
-
return $vars;
|
29 |
-
}
|
30 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php
DELETED
@@ -1,32 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class TastyIgniterInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'extension' => 'extensions/{$vendor}/{$name}/',
|
9 |
-
'theme' => 'themes/{$name}/',
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name.
|
14 |
-
*
|
15 |
-
* Cut off leading 'ti-ext-' or 'ti-theme-' if present.
|
16 |
-
* Strip vendor name of characters that is not alphanumeric or an underscore
|
17 |
-
*
|
18 |
-
*/
|
19 |
-
public function inflectPackageVars($vars)
|
20 |
-
{
|
21 |
-
if ($vars['type'] === 'tastyigniter-extension') {
|
22 |
-
$vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
|
23 |
-
$vars['name'] = preg_replace('/^ti-ext-/', '', $vars['name']);
|
24 |
-
}
|
25 |
-
|
26 |
-
if ($vars['type'] === 'tastyigniter-theme') {
|
27 |
-
$vars['name'] = preg_replace('/^ti-theme-/', '', $vars['name']);
|
28 |
-
}
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TheliaInstaller.php
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class TheliaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'local/modules/{$name}/',
|
8 |
-
'frontoffice-template' => 'templates/frontOffice/{$name}/',
|
9 |
-
'backoffice-template' => 'templates/backOffice/{$name}/',
|
10 |
-
'email-template' => 'templates/email/{$name}/',
|
11 |
-
);
|
12 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/TuskInstaller.php
DELETED
@@ -1,14 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
/**
|
4 |
-
* Composer installer for 3rd party Tusk utilities
|
5 |
-
* @author Drew Ewing <drew@phenocode.com>
|
6 |
-
*/
|
7 |
-
class TuskInstaller extends BaseInstaller
|
8 |
-
{
|
9 |
-
protected $locations = array(
|
10 |
-
'task' => '.tusk/tasks/{$name}/',
|
11 |
-
'command' => '.tusk/commands/{$name}/',
|
12 |
-
'asset' => 'assets/tusk/{$name}/',
|
13 |
-
);
|
14 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/UserFrostingInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class UserFrostingInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'sprinkle' => 'app/sprinkles/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/VanillaInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class VanillaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'plugins/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/',
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/VgmcpInstaller.php
DELETED
@@ -1,49 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class VgmcpInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'bundle' => 'src/{$vendor}/{$name}/',
|
8 |
-
'theme' => 'themes/{$name}/'
|
9 |
-
);
|
10 |
-
|
11 |
-
/**
|
12 |
-
* Format package name.
|
13 |
-
*
|
14 |
-
* For package type vgmcp-bundle, cut off a trailing '-bundle' if present.
|
15 |
-
*
|
16 |
-
* For package type vgmcp-theme, cut off a trailing '-theme' if present.
|
17 |
-
*
|
18 |
-
*/
|
19 |
-
public function inflectPackageVars($vars)
|
20 |
-
{
|
21 |
-
if ($vars['type'] === 'vgmcp-bundle') {
|
22 |
-
return $this->inflectPluginVars($vars);
|
23 |
-
}
|
24 |
-
|
25 |
-
if ($vars['type'] === 'vgmcp-theme') {
|
26 |
-
return $this->inflectThemeVars($vars);
|
27 |
-
}
|
28 |
-
|
29 |
-
return $vars;
|
30 |
-
}
|
31 |
-
|
32 |
-
protected function inflectPluginVars($vars)
|
33 |
-
{
|
34 |
-
$vars['name'] = preg_replace('/-bundle$/', '', $vars['name']);
|
35 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
36 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
37 |
-
|
38 |
-
return $vars;
|
39 |
-
}
|
40 |
-
|
41 |
-
protected function inflectThemeVars($vars)
|
42 |
-
{
|
43 |
-
$vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
|
44 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
45 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
46 |
-
|
47 |
-
return $vars;
|
48 |
-
}
|
49 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WHMCSInstaller.php
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
namespace Composer\Installers;
|
4 |
-
|
5 |
-
class WHMCSInstaller extends BaseInstaller
|
6 |
-
{
|
7 |
-
protected $locations = array(
|
8 |
-
'addons' => 'modules/addons/{$vendor}_{$name}/',
|
9 |
-
'fraud' => 'modules/fraud/{$vendor}_{$name}/',
|
10 |
-
'gateways' => 'modules/gateways/{$vendor}_{$name}/',
|
11 |
-
'notifications' => 'modules/notifications/{$vendor}_{$name}/',
|
12 |
-
'registrars' => 'modules/registrars/{$vendor}_{$name}/',
|
13 |
-
'reports' => 'modules/reports/{$vendor}_{$name}/',
|
14 |
-
'security' => 'modules/security/{$vendor}_{$name}/',
|
15 |
-
'servers' => 'modules/servers/{$vendor}_{$name}/',
|
16 |
-
'social' => 'modules/social/{$vendor}_{$name}/',
|
17 |
-
'support' => 'modules/support/{$vendor}_{$name}/',
|
18 |
-
'templates' => 'templates/{$vendor}_{$name}/',
|
19 |
-
'includes' => 'includes/{$vendor}_{$name}/'
|
20 |
-
);
|
21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WinterInstaller.php
DELETED
@@ -1,58 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class WinterInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$name}/',
|
8 |
-
'plugin' => 'plugins/{$vendor}/{$name}/',
|
9 |
-
'theme' => 'themes/{$name}/'
|
10 |
-
);
|
11 |
-
|
12 |
-
/**
|
13 |
-
* Format package name.
|
14 |
-
*
|
15 |
-
* For package type winter-plugin, cut off a trailing '-plugin' if present.
|
16 |
-
*
|
17 |
-
* For package type winter-theme, cut off a trailing '-theme' if present.
|
18 |
-
*
|
19 |
-
*/
|
20 |
-
public function inflectPackageVars($vars)
|
21 |
-
{
|
22 |
-
if ($vars['type'] === 'winter-module') {
|
23 |
-
return $this->inflectModuleVars($vars);
|
24 |
-
}
|
25 |
-
|
26 |
-
if ($vars['type'] === 'winter-plugin') {
|
27 |
-
return $this->inflectPluginVars($vars);
|
28 |
-
}
|
29 |
-
|
30 |
-
if ($vars['type'] === 'winter-theme') {
|
31 |
-
return $this->inflectThemeVars($vars);
|
32 |
-
}
|
33 |
-
|
34 |
-
return $vars;
|
35 |
-
}
|
36 |
-
|
37 |
-
protected function inflectModuleVars($vars)
|
38 |
-
{
|
39 |
-
$vars['name'] = preg_replace('/^wn-|-module$/', '', $vars['name']);
|
40 |
-
|
41 |
-
return $vars;
|
42 |
-
}
|
43 |
-
|
44 |
-
protected function inflectPluginVars($vars)
|
45 |
-
{
|
46 |
-
$vars['name'] = preg_replace('/^wn-|-plugin$/', '', $vars['name']);
|
47 |
-
$vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
|
48 |
-
|
49 |
-
return $vars;
|
50 |
-
}
|
51 |
-
|
52 |
-
protected function inflectThemeVars($vars)
|
53 |
-
{
|
54 |
-
$vars['name'] = preg_replace('/^wn-|-theme$/', '', $vars['name']);
|
55 |
-
|
56 |
-
return $vars;
|
57 |
-
}
|
58 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WolfCMSInstaller.php
DELETED
@@ -1,9 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class WolfCMSInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'wolf/plugins/{$name}/',
|
8 |
-
);
|
9 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/WordPressInstaller.php
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class WordPressInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'plugin' => 'wp-content/plugins/{$name}/',
|
8 |
-
'theme' => 'wp-content/themes/{$name}/',
|
9 |
-
'muplugin' => 'wp-content/mu-plugins/{$name}/',
|
10 |
-
'dropin' => 'wp-content/{$name}/',
|
11 |
-
);
|
12 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/YawikInstaller.php
DELETED
@@ -1,32 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Created by PhpStorm.
|
4 |
-
* User: cbleek
|
5 |
-
* Date: 25.03.16
|
6 |
-
* Time: 20:55
|
7 |
-
*/
|
8 |
-
|
9 |
-
namespace Composer\Installers;
|
10 |
-
|
11 |
-
|
12 |
-
class YawikInstaller extends BaseInstaller
|
13 |
-
{
|
14 |
-
protected $locations = array(
|
15 |
-
'module' => 'module/{$name}/',
|
16 |
-
);
|
17 |
-
|
18 |
-
/**
|
19 |
-
* Format package name to CamelCase
|
20 |
-
* @param array $vars
|
21 |
-
*
|
22 |
-
* @return array
|
23 |
-
*/
|
24 |
-
public function inflectPackageVars($vars)
|
25 |
-
{
|
26 |
-
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
|
27 |
-
$vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
|
28 |
-
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
|
29 |
-
|
30 |
-
return $vars;
|
31 |
-
}
|
32 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ZendInstaller.php
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ZendInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'library' => 'library/{$name}/',
|
8 |
-
'extra' => 'extras/library/{$name}/',
|
9 |
-
'module' => 'module/{$name}/',
|
10 |
-
);
|
11 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/Composer/Installers/ZikulaInstaller.php
DELETED
@@ -1,10 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
namespace Composer\Installers;
|
3 |
-
|
4 |
-
class ZikulaInstaller extends BaseInstaller
|
5 |
-
{
|
6 |
-
protected $locations = array(
|
7 |
-
'module' => 'modules/{$vendor}-{$name}/',
|
8 |
-
'theme' => 'themes/{$vendor}-{$name}/'
|
9 |
-
);
|
10 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/installers/src/bootstrap.php
DELETED
@@ -1,13 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
function includeIfExists($file)
|
3 |
-
{
|
4 |
-
if (file_exists($file)) {
|
5 |
-
return include $file;
|
6 |
-
}
|
7 |
-
}
|
8 |
-
if ((!$loader = includeIfExists(__DIR__ . '/../vendor/autoload.php')) && (!$loader = includeIfExists(__DIR__ . '/../../../autoload.php'))) {
|
9 |
-
die('You must set up the project dependencies, run the following commands:'.PHP_EOL.
|
10 |
-
'curl -s http://getcomposer.org/installer | php'.PHP_EOL.
|
11 |
-
'php composer.phar install'.PHP_EOL);
|
12 |
-
}
|
13 |
-
return $loader;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/gateways/stripe/vendor/composer/platform_check.php
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
// platform_check.php @generated by Composer
|
4 |
-
|
5 |
-
$issues = array();
|
6 |
-
|
7 |
-
if (!(PHP_VERSION_ID >= 50600)) {
|
8 |
-
$issues[] = 'Your Composer dependencies require a PHP version ">= 5.6.0". You are running ' . PHP_VERSION . '.';
|
9 |
-
}
|
10 |
-
|
11 |
-
if ($issues) {
|
12 |
-
if (!headers_sent()) {
|
13 |
-
header('HTTP/1.1 500 Internal Server Error');
|
14 |
-
}
|
15 |
-
if (!ini_get('display_errors')) {
|
16 |
-
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
17 |
-
fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
|
18 |
-
} elseif (!headers_sent()) {
|
19 |
-
echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL;
|
20 |
-
}
|
21 |
-
}
|
22 |
-
trigger_error(
|
23 |
-
'Composer detected issues in your platform: ' . implode(' ', $issues),
|
24 |
-
E_USER_ERROR
|
25 |
-
);
|
26 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
includes/orders/functions/orders.php
CHANGED
@@ -649,17 +649,6 @@ function edd_build_order( $order_data = array() ) {
|
|
649 |
return false;
|
650 |
}
|
651 |
|
652 |
-
$order_data = wp_parse_args(
|
653 |
-
$order_data,
|
654 |
-
array(
|
655 |
-
'user_info' => array(),
|
656 |
-
)
|
657 |
-
);
|
658 |
-
|
659 |
-
if ( empty( $order_data['user_info']['email'] ) ) {
|
660 |
-
return false;
|
661 |
-
}
|
662 |
-
|
663 |
/* Order recovery ********************************************************/
|
664 |
|
665 |
$resume_order = false;
|
@@ -681,8 +670,6 @@ function edd_build_order( $order_data = array() ) {
|
|
681 |
}
|
682 |
|
683 |
if ( $resume_order ) {
|
684 |
-
$payment->date = date( 'Y-m-d G:i:s', current_time( 'timestamp' ) );
|
685 |
-
|
686 |
$payment->add_note( __( 'Payment recovery processed', 'easy-digital-downloads' ) );
|
687 |
|
688 |
// Since things could have been added/removed since we first crated this...rebuild the cart details.
|
@@ -811,9 +798,18 @@ function edd_build_order( $order_data = array() ) {
|
|
811 |
/** Insert order **********************************************************/
|
812 |
|
813 |
// Add order into the edd_orders table.
|
814 |
-
|
815 |
-
|
816 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
817 |
|
818 |
// Attach order to the customer record.
|
819 |
$customer->attach_payment( $order_id, false );
|
649 |
return false;
|
650 |
}
|
651 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
652 |
/* Order recovery ********************************************************/
|
653 |
|
654 |
$resume_order = false;
|
670 |
}
|
671 |
|
672 |
if ( $resume_order ) {
|
|
|
|
|
673 |
$payment->add_note( __( 'Payment recovery processed', 'easy-digital-downloads' ) );
|
674 |
|
675 |
// Since things could have been added/removed since we first crated this...rebuild the cart details.
|
798 |
/** Insert order **********************************************************/
|
799 |
|
800 |
// Add order into the edd_orders table.
|
801 |
+
if ( true === $resume_order ) {
|
802 |
+
$order_id = $payment->ID;
|
803 |
+
unset( $order_args['date_created'] );
|
804 |
+
edd_update_order( $order_id, $order_args );
|
805 |
+
} else {
|
806 |
+
$order_id = edd_add_order( $order_args );
|
807 |
+
}
|
808 |
+
|
809 |
+
// If there is no order ID at this point, something went wrong.
|
810 |
+
if ( empty( $order_id ) ) {
|
811 |
+
return false;
|
812 |
+
}
|
813 |
|
814 |
// Attach order to the customer record.
|
815 |
$customer->attach_payment( $order_id, false );
|
includes/payments/actions.php
CHANGED
@@ -255,65 +255,6 @@ function edd_process_after_payment_actions( $payment_id = 0, $force = false ) {
|
|
255 |
}
|
256 |
add_action( 'edd_after_payment_scheduled_actions', 'edd_process_after_payment_actions', 10, 1 );
|
257 |
|
258 |
-
/**
|
259 |
-
* Flushes the current user's purchase history transient when a payment status
|
260 |
-
* is updated
|
261 |
-
*
|
262 |
-
* @since 1.2.2
|
263 |
-
*
|
264 |
-
* @param int $payment_id the ID number of the payment
|
265 |
-
* @param string $new_status the status of the payment, probably "publish"
|
266 |
-
* @param string $old_status the status of the payment prior to being marked as "complete", probably "pending"
|
267 |
-
*/
|
268 |
-
function edd_clear_user_history_cache( $payment_id, $new_status, $old_status ) {
|
269 |
-
$payment = new EDD_Payment( $payment_id );
|
270 |
-
|
271 |
-
if( ! empty( $payment->user_id ) ) {
|
272 |
-
delete_transient( 'edd_user_' . $payment->user_id . '_purchases' );
|
273 |
-
}
|
274 |
-
}
|
275 |
-
add_action( 'edd_update_payment_status', 'edd_clear_user_history_cache', 10, 3 );
|
276 |
-
|
277 |
-
/**
|
278 |
-
* Updates all old payments, prior to 1.2, with new
|
279 |
-
* meta for the total purchase amount
|
280 |
-
*
|
281 |
-
* This is so that payments can be queried by their totals
|
282 |
-
*
|
283 |
-
* @since 1.2
|
284 |
-
* @param array $data Arguments passed
|
285 |
-
* @return void
|
286 |
-
*/
|
287 |
-
function edd_update_old_payments_with_totals( $data ) {
|
288 |
-
if ( ! wp_verify_nonce( $data['_wpnonce'], 'edd_upgrade_payments_nonce' ) ) {
|
289 |
-
return;
|
290 |
-
}
|
291 |
-
|
292 |
-
if ( get_option( 'edd_payment_totals_upgraded' ) ) {
|
293 |
-
return;
|
294 |
-
}
|
295 |
-
|
296 |
-
$payments = edd_get_payments( array(
|
297 |
-
'offset' => 0,
|
298 |
-
'number' => 9999999,
|
299 |
-
'mode' => 'all',
|
300 |
-
) );
|
301 |
-
|
302 |
-
if ( $payments ) {
|
303 |
-
foreach ( $payments as $payment ) {
|
304 |
-
|
305 |
-
$payment = new EDD_Payment( $payment->ID );
|
306 |
-
$meta = $payment->get_meta();
|
307 |
-
|
308 |
-
$payment->total = $meta['amount'];
|
309 |
-
$payment->save();
|
310 |
-
}
|
311 |
-
}
|
312 |
-
|
313 |
-
add_option( 'edd_payment_totals_upgraded', 1 );
|
314 |
-
}
|
315 |
-
add_action( 'edd_upgrade_payments', 'edd_update_old_payments_with_totals' );
|
316 |
-
|
317 |
/**
|
318 |
* Updates week-old+ 'pending' orders to 'abandoned'
|
319 |
*
|
@@ -352,113 +293,6 @@ function edd_mark_abandoned_orders() {
|
|
352 |
}
|
353 |
add_action( 'edd_weekly_scheduled_events', 'edd_mark_abandoned_orders' );
|
354 |
|
355 |
-
/**
|
356 |
-
* Listens to the updated_postmeta hook for our backwards compatible payment_meta updates, and runs through them
|
357 |
-
*
|
358 |
-
* @since 2.3
|
359 |
-
* @param int $meta_id The Meta ID that was updated
|
360 |
-
* @param int $object_id The Object ID that was updated (post ID)
|
361 |
-
* @param string $meta_key The Meta key that was updated
|
362 |
-
* @param string|int|float $meta_value The Value being updated
|
363 |
-
* @return bool|int If successful the number of rows updated, if it fails, false
|
364 |
-
*/
|
365 |
-
function edd_update_payment_backwards_compat( $meta_id, $object_id, $meta_key, $meta_value ) {
|
366 |
-
|
367 |
-
$meta_keys = array( '_edd_payment_meta', '_edd_payment_tax' );
|
368 |
-
|
369 |
-
if ( ! in_array( $meta_key, $meta_keys ) ) {
|
370 |
-
return;
|
371 |
-
}
|
372 |
-
|
373 |
-
global $wpdb;
|
374 |
-
switch( $meta_key ) {
|
375 |
-
|
376 |
-
case '_edd_payment_meta':
|
377 |
-
$meta_value = maybe_unserialize( $meta_value );
|
378 |
-
|
379 |
-
if( ! isset( $meta_value['tax'] ) ){
|
380 |
-
return;
|
381 |
-
}
|
382 |
-
|
383 |
-
$tax_value = $meta_value['tax'];
|
384 |
-
|
385 |
-
$data = array( 'meta_value' => $tax_value );
|
386 |
-
$where = array( 'post_id' => $object_id, 'meta_key' => '_edd_payment_tax' );
|
387 |
-
$data_format = array( '%f' );
|
388 |
-
$where_format = array( '%d', '%s' );
|
389 |
-
break;
|
390 |
-
|
391 |
-
case '_edd_payment_tax':
|
392 |
-
$tax_value = ! empty( $meta_value ) ? $meta_value : 0;
|
393 |
-
$current_meta = edd_get_payment_meta( $object_id, '_edd_payment_meta', true );
|
394 |
-
|
395 |
-
$current_meta['tax'] = $tax_value;
|
396 |
-
$new_meta = maybe_serialize( $current_meta );
|
397 |
-
|
398 |
-
$data = array( 'meta_value' => $new_meta );
|
399 |
-
$where = array( 'post_id' => $object_id, 'meta_key' => '_edd_payment_meta' );
|
400 |
-
$data_format = array( '%s' );
|
401 |
-
$where_format = array( '%d', '%s' );
|
402 |
-
|
403 |
-
break;
|
404 |
-
|
405 |
-
}
|
406 |
-
|
407 |
-
$updated = $wpdb->update( $wpdb->postmeta, $data, $where, $data_format, $where_format );
|
408 |
-
|
409 |
-
if ( ! empty( $updated ) ) {
|
410 |
-
// Since we did a direct DB query, clear the postmeta cache.
|
411 |
-
wp_cache_delete( $object_id, 'post_meta' );
|
412 |
-
}
|
413 |
-
|
414 |
-
return $updated;
|
415 |
-
|
416 |
-
|
417 |
-
}
|
418 |
-
add_action( 'updated_postmeta', 'edd_update_payment_backwards_compat', 10, 4 );
|
419 |
-
|
420 |
-
/**
|
421 |
-
* Deletes edd_stats_ transients that have expired to prevent database clogs
|
422 |
-
*
|
423 |
-
* @since 2.6.7
|
424 |
-
* @return void
|
425 |
-
*/
|
426 |
-
function edd_cleanup_stats_transients() {
|
427 |
-
global $wpdb;
|
428 |
-
|
429 |
-
if ( defined( 'WP_SETUP_CONFIG' ) ) {
|
430 |
-
return;
|
431 |
-
}
|
432 |
-
|
433 |
-
if ( defined( 'WP_INSTALLING' ) ) {
|
434 |
-
return;
|
435 |
-
}
|
436 |
-
|
437 |
-
$now = current_time( 'timestamp' );
|
438 |
-
$transients = $wpdb->get_results( "SELECT option_name, option_value FROM $wpdb->options WHERE option_name LIKE '%\_transient_timeout\_edd\_stats\_%' AND option_value+0 < $now LIMIT 0, 200;" );
|
439 |
-
$to_delete = array();
|
440 |
-
|
441 |
-
if( ! empty( $transients ) ) {
|
442 |
-
|
443 |
-
foreach( $transients as $transient ) {
|
444 |
-
|
445 |
-
$to_delete[] = $transient->option_name;
|
446 |
-
$to_delete[] = str_replace( '_timeout', '', $transient->option_name );
|
447 |
-
|
448 |
-
}
|
449 |
-
|
450 |
-
}
|
451 |
-
|
452 |
-
if ( ! empty( $to_delete ) ) {
|
453 |
-
|
454 |
-
$option_names = implode( "','", $to_delete );
|
455 |
-
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name IN ('$option_names')" );
|
456 |
-
|
457 |
-
}
|
458 |
-
|
459 |
-
}
|
460 |
-
add_action( 'edd_daily_scheduled_events', 'edd_cleanup_stats_transients' );
|
461 |
-
|
462 |
/**
|
463 |
* Process an attempt to complete a recoverable payment.
|
464 |
*
|
255 |
}
|
256 |
add_action( 'edd_after_payment_scheduled_actions', 'edd_process_after_payment_actions', 10, 1 );
|
257 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
258 |
/**
|
259 |
* Updates week-old+ 'pending' orders to 'abandoned'
|
260 |
*
|
293 |
}
|
294 |
add_action( 'edd_weekly_scheduled_events', 'edd_mark_abandoned_orders' );
|
295 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
296 |
/**
|
297 |
* Process an attempt to complete a recoverable payment.
|
298 |
*
|
includes/process-download.php
CHANGED
@@ -365,17 +365,51 @@ function edd_deliver_download( $file = '', $redirect = false ) {
|
|
365 |
* Determine if the file being requested is hosted locally or not
|
366 |
*
|
367 |
* @since 2.5.10
|
|
|
|
|
368 |
* @param string $requested_file The file being requested
|
369 |
* @return bool If the file is hosted locally or not
|
370 |
*/
|
371 |
function edd_is_local_file( $requested_file ) {
|
372 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
373 |
$requested_file = preg_replace('#^(https?|file)://#', '', $requested_file );
|
374 |
|
375 |
-
|
376 |
-
$
|
|
|
377 |
|
378 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
379 |
}
|
380 |
|
381 |
/**
|
365 |
* Determine if the file being requested is hosted locally or not
|
366 |
*
|
367 |
* @since 2.5.10
|
368 |
+
* @since 3.1.0.3 - Updated to also check home_url (which is what previous versions of EDD were using).
|
369 |
+
*
|
370 |
* @param string $requested_file The file being requested
|
371 |
* @return bool If the file is hosted locally or not
|
372 |
*/
|
373 |
function edd_is_local_file( $requested_file ) {
|
374 |
+
// By default, we assume the file is not locally hosted.
|
375 |
+
$is_local_file = false;
|
376 |
+
|
377 |
+
// Grab the home_url and site_url values, so we can use them to test file location.
|
378 |
+
$site_url = preg_replace('#^https?://#', '', site_url() );
|
379 |
+
$home_url = preg_replace('#^https?://#', '', home_url() );
|
380 |
+
|
381 |
+
// Sanitize the requested file.
|
382 |
$requested_file = preg_replace('#^(https?|file)://#', '', $requested_file );
|
383 |
|
384 |
+
// First, check the Site URL.
|
385 |
+
$is_local_url_site_url = strpos( $requested_file, $site_url ) === 0;
|
386 |
+
$is_local_path_site_url = strpos( $requested_file, '/' ) === 0;
|
387 |
|
388 |
+
$is_local_file = ( $is_local_url_site_url || $is_local_path_site_url );
|
389 |
+
|
390 |
+
/**
|
391 |
+
* If the site_url and home_url are different, and we still didn't detect a local file, try
|
392 |
+
* again with the home_url value.
|
393 |
+
*/
|
394 |
+
if ( $home_url !== $site_url && false === $is_local_file ) {
|
395 |
+
$is_local_url_home_url = strpos( $requested_file, $home_url ) === 0;
|
396 |
+
$is_local_path_home_url = strpos( $requested_file, '/' ) === 0;
|
397 |
+
|
398 |
+
$is_local_file = ( $is_local_url_home_url || $is_local_path_home_url );
|
399 |
+
}
|
400 |
+
|
401 |
+
/**
|
402 |
+
* Allow filtering the edd_is_local_file detection.
|
403 |
+
*
|
404 |
+
* EDD tries to identify if a file is hosted locally, so that we can use the proper file delivery method.
|
405 |
+
* By default we check the site_url, and then the home_url (in the event that those settings are different).
|
406 |
+
*
|
407 |
+
* @since 3.1.0.3
|
408 |
+
*
|
409 |
+
* @param boolean $is_local_file If the file is hosted locally, on the server and within the site's contents.
|
410 |
+
* @param string $requested_file The file that is being requested to download.
|
411 |
+
*/
|
412 |
+
return apply_filters( 'edd_is_local_file', $is_local_file, $requested_file );
|
413 |
}
|
414 |
|
415 |
/**
|
includes/shortcodes.php
CHANGED
@@ -664,15 +664,15 @@ function edd_receipt_shortcode( $atts, $content = null ) {
|
|
664 |
global $edd_receipt_args;
|
665 |
|
666 |
$edd_receipt_args = shortcode_atts( array(
|
667 |
-
'error'
|
668 |
-
'price'
|
669 |
-
'discount'
|
670 |
-
'products'
|
671 |
-
'date'
|
672 |
-
'notes'
|
673 |
-
'payment_key'
|
674 |
-
'payment_method'
|
675 |
-
'payment_id'
|
676 |
), $atts, 'edd_receipt' );
|
677 |
|
678 |
$session = edd_get_purchase_session();
|
@@ -698,7 +698,7 @@ function edd_receipt_shortcode( $atts, $content = null ) {
|
|
698 |
// Key was provided, but user is logged out. Offer them the ability to login and view the receipt
|
699 |
if ( ! $user_can_view && ! empty( $payment_key ) && ! is_user_logged_in() && ! edd_is_guest_payment( $order->id ) ) {
|
700 |
global $edd_login_redirect;
|
701 |
-
$edd_login_redirect =
|
702 |
|
703 |
ob_start();
|
704 |
|
664 |
global $edd_receipt_args;
|
665 |
|
666 |
$edd_receipt_args = shortcode_atts( array(
|
667 |
+
'error' => __( 'Sorry, trouble retrieving order receipt.', 'easy-digital-downloads' ),
|
668 |
+
'price' => true,
|
669 |
+
'discount' => true,
|
670 |
+
'products' => true,
|
671 |
+
'date' => true,
|
672 |
+
'notes' => true,
|
673 |
+
'payment_key' => false,
|
674 |
+
'payment_method' => true,
|
675 |
+
'payment_id' => true,
|
676 |
), $atts, 'edd_receipt' );
|
677 |
|
678 |
$session = edd_get_purchase_session();
|
698 |
// Key was provided, but user is logged out. Offer them the ability to login and view the receipt
|
699 |
if ( ! $user_can_view && ! empty( $payment_key ) && ! is_user_logged_in() && ! edd_is_guest_payment( $order->id ) ) {
|
700 |
global $edd_login_redirect;
|
701 |
+
$edd_login_redirect = edd_get_receipt_page_uri( $order->id );
|
702 |
|
703 |
ob_start();
|
704 |
|
languages/easy-digital-downloads.pot
CHANGED
@@ -2,16 +2,16 @@
|
|
2 |
# This file is distributed under the same license as the Easy Digital Downloads plugin.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: Easy Digital Downloads 3.1.0.
|
6 |
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/easy-digital-downloads\n"
|
7 |
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
8 |
"Language-Team: LANGUAGE <LL@li.org>\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"POT-Creation-Date: 2022-
|
13 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
14 |
-
"X-Generator: WP-CLI 2.
|
15 |
"X-Domain: easy-digital-downloads\n"
|
16 |
|
17 |
#. Plugin Name of the plugin
|
@@ -82,7 +82,7 @@ msgstr ""
|
|
82 |
#: includes/admin/adjustments/adjustment-functions.php:43
|
83 |
#: includes/admin/adjustments/adjustment-functions.php:99
|
84 |
#: includes/admin/admin-pages.php:88
|
85 |
-
#: includes/admin/reporting/reports.php:
|
86 |
#: includes/admin/settings/display-settings.php:40
|
87 |
#: includes/admin/upgrades/upgrade-functions.php:1431
|
88 |
#: includes/post-types.php:129
|
@@ -248,18 +248,20 @@ msgstr ""
|
|
248 |
#: includes/download-functions.php:1553
|
249 |
#: includes/EDD_SL_Plugin_Updater.php:486
|
250 |
#: includes/emails/actions.php:59
|
251 |
-
#: includes/emails/template.php:
|
252 |
#: includes/error-tracking.php:60
|
253 |
#: includes/gateways/functions.php:320
|
254 |
#: includes/gateways/manual.php:33
|
255 |
#: includes/gateways/paypal-standard.php:170
|
256 |
-
#: includes/gateways/paypal/admin/connect.php:
|
257 |
-
#: includes/gateways/paypal/admin/connect.php:
|
258 |
-
#: includes/gateways/paypal/admin/connect.php:
|
|
|
|
|
259 |
#: includes/gateways/stripe/includes/admin/upgrade-functions.php:80
|
260 |
#: includes/gateways/stripe/includes/payment-actions.php:1387
|
261 |
#: includes/process-download.php:296
|
262 |
-
#: includes/process-download.php:
|
263 |
#: includes/query-filters.php:51
|
264 |
#: includes/user-functions.php:893
|
265 |
#: includes/user-functions.php:918
|
@@ -282,7 +284,7 @@ msgstr ""
|
|
282 |
|
283 |
#: includes/admin/admin-pages.php:87
|
284 |
#: includes/admin/customers/customers.php:77
|
285 |
-
#: includes/admin/reporting/reports.php:
|
286 |
#: includes/admin/settings/display-settings.php:43
|
287 |
msgid "Customers"
|
288 |
msgstr ""
|
@@ -626,15 +628,18 @@ msgstr ""
|
|
626 |
#: includes/admin/promos/class-promo-handler.php:128
|
627 |
#: includes/admin/tools/class-edd-tools-recount-all-stats.php:78
|
628 |
#: includes/admin/tools/class-edd-tools-recount-download-stats.php:117
|
629 |
-
#: includes/gateways/paypal/admin/connect.php:
|
630 |
-
#: includes/gateways/paypal/admin/connect.php:
|
631 |
-
#: includes/gateways/paypal/admin/connect.php:
|
632 |
-
#: includes/gateways/paypal/admin/connect.php:
|
633 |
-
#: includes/gateways/paypal/admin/connect.php:
|
634 |
-
#: includes/gateways/paypal/admin/connect.php:
|
635 |
-
#: includes/gateways/paypal/admin/connect.php:
|
636 |
-
#: includes/gateways/paypal/admin/connect.php:
|
637 |
-
#: includes/gateways/paypal/admin/connect.php:
|
|
|
|
|
|
|
638 |
msgid "You do not have permission to perform this action."
|
639 |
msgstr ""
|
640 |
|
@@ -815,7 +820,7 @@ msgstr ""
|
|
815 |
#: includes/blocks/views/orders/totals.php:38
|
816 |
#: includes/privacy-functions.php:946
|
817 |
#: includes/reports/reports-functions.php:316
|
818 |
-
#: templates/history-purchases.php:
|
819 |
#: templates/shortcode-receipt.php:69
|
820 |
msgid "Date"
|
821 |
msgstr ""
|
@@ -1206,7 +1211,7 @@ msgstr ""
|
|
1206 |
#: includes/admin/customers/customers.php:708
|
1207 |
#: includes/admin/customers/customers.php:749
|
1208 |
#: includes/admin/payments/class-payments-table.php:384
|
1209 |
-
#: includes/admin/reporting/reports.php:
|
1210 |
msgid "Number"
|
1211 |
msgstr ""
|
1212 |
|
@@ -1389,10 +1394,10 @@ msgstr ""
|
|
1389 |
#: includes/admin/reporting/reports.php:254
|
1390 |
#: includes/admin/reporting/reports.php:352
|
1391 |
#: includes/admin/reporting/reports.php:713
|
1392 |
-
#: includes/admin/reporting/reports.php:
|
1393 |
-
#: includes/admin/reporting/reports.php:
|
1394 |
-
#: includes/admin/reporting/reports.php:
|
1395 |
-
#: includes/admin/reporting/reports.php:
|
1396 |
#: includes/reports/data/file-downloads/class-top-five-most-downloaded-list-table.php:61
|
1397 |
#: includes/blocks/build/downloads/index.js:1
|
1398 |
msgid "Earnings"
|
@@ -1493,7 +1498,7 @@ msgstr ""
|
|
1493 |
#: includes/admin/reporting/class-export-payments.php:70
|
1494 |
#: includes/admin/reporting/export/class-batch-export-payments.php:56
|
1495 |
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:56
|
1496 |
-
#: includes/admin/reporting/reports.php:
|
1497 |
#: includes/admin/views/tmpl-order-adjustment-discount.php:41
|
1498 |
#: includes/admin/views/tmpl-order-adjustment.php:55
|
1499 |
#: includes/admin/views/tmpl-order-form-add-order-adjustment.php:80
|
@@ -1503,7 +1508,7 @@ msgstr ""
|
|
1503 |
#: includes/admin/views/tmpl-order-tax.php:29
|
1504 |
#: includes/admin/views/tmpl-order-total.php:23
|
1505 |
#: includes/reports/data/discounts/class-top-five-discounts-list-table.php:78
|
1506 |
-
#: templates/history-purchases.php:
|
1507 |
msgid "Amount"
|
1508 |
msgstr ""
|
1509 |
|
@@ -1963,10 +1968,10 @@ msgstr ""
|
|
1963 |
#. translators: the plural post type label
|
1964 |
#: includes/admin/downloads/dashboard-columns.php:238
|
1965 |
#: includes/admin/downloads/dashboard-columns.php:250
|
1966 |
-
#: includes/admin/reporting/reports.php:
|
1967 |
-
#: includes/admin/reporting/reports.php:
|
1968 |
-
#: includes/admin/reporting/reports.php:
|
1969 |
-
#: includes/admin/reporting/reports.php:
|
1970 |
#: includes/reports/reports-functions.php:1387
|
1971 |
msgid "All %s"
|
1972 |
msgstr ""
|
@@ -2156,9 +2161,9 @@ msgid "Insert into %s"
|
|
2156 |
msgstr ""
|
2157 |
|
2158 |
#: includes/admin/downloads/metabox.php:942
|
2159 |
-
#: includes/admin/reporting/reports.php:
|
2160 |
-
#: includes/admin/reporting/reports.php:
|
2161 |
-
#: includes/admin/reporting/reports.php:
|
2162 |
#: includes/admin/settings/register-settings.php:668
|
2163 |
#: includes/admin/settings/register-settings.php:671
|
2164 |
#: includes/admin/settings/register-settings.php:1786
|
@@ -2636,12 +2641,12 @@ msgstr ""
|
|
2636 |
|
2637 |
#: includes/admin/payments/class-payments-table.php:193
|
2638 |
#: includes/admin/reporting/class-base-logs-list-table.php:477
|
2639 |
-
#: includes/admin/reporting/reports.php:
|
2640 |
-
#: includes/admin/reporting/reports.php:
|
2641 |
-
#: includes/admin/reporting/reports.php:
|
2642 |
-
#: includes/admin/reporting/reports.php:
|
2643 |
-
#: includes/admin/reporting/reports.php:
|
2644 |
-
#: includes/admin/reporting/reports.php:
|
2645 |
#: includes/reports/reports-functions.php:1287
|
2646 |
msgctxt "date filter"
|
2647 |
msgid "From"
|
@@ -2649,12 +2654,12 @@ msgstr ""
|
|
2649 |
|
2650 |
#: includes/admin/payments/class-payments-table.php:200
|
2651 |
#: includes/admin/reporting/class-base-logs-list-table.php:484
|
2652 |
-
#: includes/admin/reporting/reports.php:
|
2653 |
-
#: includes/admin/reporting/reports.php:
|
2654 |
-
#: includes/admin/reporting/reports.php:
|
2655 |
-
#: includes/admin/reporting/reports.php:
|
2656 |
-
#: includes/admin/reporting/reports.php:
|
2657 |
-
#: includes/admin/reporting/reports.php:
|
2658 |
#: includes/reports/reports-functions.php:1297
|
2659 |
msgctxt "date filter"
|
2660 |
msgid "To"
|
@@ -2985,7 +2990,7 @@ msgid "A transaction ID prefixed by %s"
|
|
2985 |
msgstr ""
|
2986 |
|
2987 |
#: includes/admin/payments/contextual-help.php:130
|
2988 |
-
#: templates/history-purchases.php:
|
2989 |
msgid "Details"
|
2990 |
msgstr ""
|
2991 |
|
@@ -3489,10 +3494,10 @@ msgstr ""
|
|
3489 |
#: includes/admin/reporting/reports.php:232
|
3490 |
#: includes/admin/reporting/reports.php:364
|
3491 |
#: includes/admin/reporting/reports.php:663
|
3492 |
-
#: includes/admin/reporting/reports.php:
|
3493 |
-
#: includes/admin/reporting/reports.php:
|
3494 |
-
#: includes/admin/reporting/reports.php:
|
3495 |
-
#: includes/admin/reporting/reports.php:
|
3496 |
#: includes/reports/data/downloads/class-top-selling-downloads-list-table.php:57
|
3497 |
#: includes/reports/data/file-downloads/class-top-five-most-downloaded-list-table.php:60
|
3498 |
#: tests/reports/data/charts/v2/tests-dateset.php:209
|
@@ -3559,14 +3564,13 @@ msgstr ""
|
|
3559 |
#: includes/admin/reporting/export/class-batch-export-customers.php:51
|
3560 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:41
|
3561 |
#: includes/admin/reporting/export/class-batch-export-taxed-customers.php:41
|
3562 |
-
#: templates/history-purchases.php:
|
3563 |
#: includes/blocks/build/downloads/index.js:1
|
3564 |
#: includes/blocks/build/terms/index.js:1
|
3565 |
msgid "ID"
|
3566 |
msgstr ""
|
3567 |
|
3568 |
#: includes/admin/reporting/class-export-payments.php:57
|
3569 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:42
|
3570 |
#: includes/admin/tools.php:611
|
3571 |
msgid "Payment Number"
|
3572 |
msgstr ""
|
@@ -3648,14 +3652,14 @@ msgid "User"
|
|
3648 |
msgstr ""
|
3649 |
|
3650 |
#: includes/admin/reporting/class-export-payments.php:185
|
3651 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
3652 |
-
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:
|
3653 |
msgid "none"
|
3654 |
msgstr ""
|
3655 |
|
3656 |
#: includes/admin/reporting/class-export-payments.php:190
|
3657 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
3658 |
-
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:
|
3659 |
msgid "guest"
|
3660 |
msgstr ""
|
3661 |
|
@@ -3670,6 +3674,7 @@ msgstr ""
|
|
3670 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:112
|
3671 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:108
|
3672 |
#: includes/admin/reporting/class-sales-logs-list-table.php:97
|
|
|
3673 |
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:42
|
3674 |
msgid "Order Number"
|
3675 |
msgstr ""
|
@@ -3717,8 +3722,8 @@ msgid "This screen provides you with reports for your earnings, downloads, custo
|
|
3717 |
msgstr ""
|
3718 |
|
3719 |
#: includes/admin/reporting/contextual-help.php:67
|
3720 |
-
#: includes/admin/reporting/reports.php:
|
3721 |
-
#: includes/admin/reporting/reports.php:
|
3722 |
#: includes/admin/tools.php:1012
|
3723 |
msgid "Export"
|
3724 |
msgstr ""
|
@@ -3825,7 +3830,7 @@ msgid "Tags"
|
|
3825 |
msgstr ""
|
3826 |
|
3827 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:52
|
3828 |
-
#: templates/history-downloads.php:
|
3829 |
msgid "Files"
|
3830 |
msgstr ""
|
3831 |
|
@@ -3861,9 +3866,9 @@ msgid "Gross Amount"
|
|
3861 |
msgstr ""
|
3862 |
|
3863 |
#: includes/admin/reporting/export/class-batch-export-payments.php:41
|
3864 |
-
#: includes/admin/reporting/export/class-batch-export-
|
3865 |
-
#: includes/
|
3866 |
-
msgid "
|
3867 |
msgstr ""
|
3868 |
|
3869 |
#: includes/admin/reporting/export/class-batch-export-payments.php:44
|
@@ -3895,13 +3900,13 @@ msgstr ""
|
|
3895 |
msgid "State Name"
|
3896 |
msgstr ""
|
3897 |
|
3898 |
-
#: includes/admin/reporting/export/class-batch-export-sales.php:
|
3899 |
-
|
|
|
3900 |
msgstr ""
|
3901 |
|
3902 |
-
#: includes/admin/reporting/export/class-batch-export-
|
3903 |
-
|
3904 |
-
msgid "Order ID"
|
3905 |
msgstr ""
|
3906 |
|
3907 |
#: includes/admin/reporting/export/export-functions.php:51
|
@@ -3975,26 +3980,26 @@ msgid "The logs tab has been moved to the Tools screen."
|
|
3975 |
msgstr ""
|
3976 |
|
3977 |
#: includes/admin/reporting/reports.php:279
|
3978 |
-
#: includes/admin/reporting/reports.php:
|
3979 |
msgid "Average Order Value"
|
3980 |
msgstr ""
|
3981 |
|
3982 |
#: includes/admin/reporting/reports.php:303
|
3983 |
-
#: includes/admin/reporting/reports.php:
|
3984 |
-
#: includes/admin/reporting/reports.php:
|
3985 |
-
#: includes/admin/reporting/reports.php:
|
3986 |
#: includes/emails/email-summary/edd-email-summary-template.php:279
|
3987 |
msgid "New Customers"
|
3988 |
msgstr ""
|
3989 |
|
3990 |
#: includes/admin/reporting/reports.php:321
|
3991 |
-
#: includes/admin/reporting/reports.php:
|
3992 |
msgid "Total Refund Amount"
|
3993 |
msgstr ""
|
3994 |
|
3995 |
#: includes/admin/reporting/reports.php:344
|
3996 |
#: includes/admin/reporting/reports.php:731
|
3997 |
-
#: includes/admin/reporting/reports.php:
|
3998 |
msgid "Sales and Earnings"
|
3999 |
msgstr ""
|
4000 |
|
@@ -4030,67 +4035,67 @@ msgstr ""
|
|
4030 |
msgid "Earnings by Variation"
|
4031 |
msgstr ""
|
4032 |
|
4033 |
-
#: includes/admin/reporting/reports.php:
|
4034 |
msgid "Number of Refunds"
|
4035 |
msgstr ""
|
4036 |
|
4037 |
-
#: includes/admin/reporting/reports.php:
|
4038 |
msgid "Number of Fully Refunded Orders"
|
4039 |
msgstr ""
|
4040 |
|
4041 |
-
#: includes/admin/reporting/reports.php:
|
4042 |
msgid "Number of Fully Refunded Items"
|
4043 |
msgstr ""
|
4044 |
|
4045 |
-
#: includes/admin/reporting/reports.php:
|
4046 |
msgid "Average Refund Amount"
|
4047 |
msgstr ""
|
4048 |
|
4049 |
-
#: includes/admin/reporting/reports.php:
|
4050 |
msgid "Average Time to Refund"
|
4051 |
msgstr ""
|
4052 |
|
4053 |
-
#: includes/admin/reporting/reports.php:
|
4054 |
msgid "Refund Rate"
|
4055 |
msgstr ""
|
4056 |
|
4057 |
-
#: includes/admin/reporting/reports.php:
|
4058 |
msgid "Payment Gateways"
|
4059 |
msgstr ""
|
4060 |
|
4061 |
-
#: includes/admin/reporting/reports.php:
|
4062 |
msgid "Gateway Stats"
|
4063 |
msgstr ""
|
4064 |
|
4065 |
-
#: includes/admin/reporting/reports.php:
|
4066 |
msgid "Gateway Sales"
|
4067 |
msgstr ""
|
4068 |
|
4069 |
-
#: includes/admin/reporting/reports.php:
|
4070 |
msgid "Gateway Earnings"
|
4071 |
msgstr ""
|
4072 |
|
4073 |
-
#: includes/admin/reporting/reports.php:
|
4074 |
#: includes/admin/settings/contextual-help.php:99
|
4075 |
#: includes/admin/settings/register-settings.php:917
|
4076 |
#: includes/admin/settings/register-settings.php:1737
|
4077 |
msgid "Taxes"
|
4078 |
msgstr ""
|
4079 |
|
4080 |
-
#: includes/admin/reporting/reports.php:
|
4081 |
msgid "Total Tax Collected"
|
4082 |
msgstr ""
|
4083 |
|
4084 |
-
#: includes/admin/reporting/reports.php:
|
4085 |
msgid "Total Tax Collected for "
|
4086 |
msgstr ""
|
4087 |
|
4088 |
-
#: includes/admin/reporting/reports.php:
|
4089 |
msgid "Tax Collected by Location"
|
4090 |
msgstr ""
|
4091 |
|
4092 |
-
#: includes/admin/reporting/reports.php:
|
4093 |
-
#: includes/admin/reporting/reports.php:
|
4094 |
#: includes/admin/settings/register-settings.php:1818
|
4095 |
#: includes/admin/tools/logs.php:195
|
4096 |
#: includes/privacy-functions.php:546
|
@@ -4098,286 +4103,286 @@ msgstr ""
|
|
4098 |
msgid "File Downloads"
|
4099 |
msgstr ""
|
4100 |
|
4101 |
-
#: includes/admin/reporting/reports.php:
|
4102 |
-
#: includes/admin/reporting/reports.php:
|
4103 |
msgid "Number of File Downloads"
|
4104 |
msgstr ""
|
4105 |
|
4106 |
-
#: includes/admin/reporting/reports.php:
|
4107 |
msgid "Average per Customer"
|
4108 |
msgstr ""
|
4109 |
|
4110 |
-
#: includes/admin/reporting/reports.php:
|
4111 |
msgid "Average per Order"
|
4112 |
msgstr ""
|
4113 |
|
4114 |
-
#: includes/admin/reporting/reports.php:
|
4115 |
msgid "Most Downloaded Product"
|
4116 |
msgstr ""
|
4117 |
|
4118 |
-
#: includes/admin/reporting/reports.php:
|
4119 |
msgid "Top Five Most Downloaded Products"
|
4120 |
msgstr ""
|
4121 |
|
4122 |
-
#: includes/admin/reporting/reports.php:
|
4123 |
msgid "Number of Discounts Used"
|
4124 |
msgstr ""
|
4125 |
|
4126 |
-
#: includes/admin/reporting/reports.php:
|
4127 |
msgid "Discount Ratio"
|
4128 |
msgstr ""
|
4129 |
|
4130 |
-
#: includes/admin/reporting/reports.php:
|
4131 |
msgid "Customer Savings"
|
4132 |
msgstr ""
|
4133 |
|
4134 |
-
#: includes/admin/reporting/reports.php:
|
4135 |
msgid "Average Discount Amount"
|
4136 |
msgstr ""
|
4137 |
|
4138 |
-
#: includes/admin/reporting/reports.php:
|
4139 |
msgid "Most Popular Discount"
|
4140 |
msgstr ""
|
4141 |
|
4142 |
-
#: includes/admin/reporting/reports.php:
|
4143 |
msgid "Discount Usage Count"
|
4144 |
msgstr ""
|
4145 |
|
4146 |
-
#: includes/admin/reporting/reports.php:
|
4147 |
msgid "Top Five Discounts"
|
4148 |
msgstr ""
|
4149 |
|
4150 |
-
#: includes/admin/reporting/reports.php:
|
4151 |
-
#: includes/admin/reporting/reports.php:
|
4152 |
msgid "Discount Usage"
|
4153 |
msgstr ""
|
4154 |
|
4155 |
-
#: includes/admin/reporting/reports.php:
|
4156 |
msgid "Average Revenue per Customer"
|
4157 |
msgstr ""
|
4158 |
|
4159 |
-
#: includes/admin/reporting/reports.php:
|
4160 |
msgid "Average Orders per Customer"
|
4161 |
msgstr ""
|
4162 |
|
4163 |
-
#: includes/admin/reporting/reports.php:
|
4164 |
msgid "Top Five Customers — All Time"
|
4165 |
msgstr ""
|
4166 |
|
4167 |
-
#: includes/admin/reporting/reports.php:
|
4168 |
msgid "Most Valuable Customers"
|
4169 |
msgstr ""
|
4170 |
|
4171 |
-
#: includes/admin/reporting/reports.php:
|
4172 |
msgid "Export Earnings Report"
|
4173 |
msgstr ""
|
4174 |
|
4175 |
-
#: includes/admin/reporting/reports.php:
|
4176 |
msgid "Download a CSV giving a detailed look into earnings over time."
|
4177 |
msgstr ""
|
4178 |
|
4179 |
-
#: includes/admin/reporting/reports.php:
|
4180 |
msgid "Export Earnings Start"
|
4181 |
msgstr ""
|
4182 |
|
4183 |
-
#: includes/admin/reporting/reports.php:
|
4184 |
msgid "Select start month"
|
4185 |
msgstr ""
|
4186 |
|
4187 |
-
#: includes/admin/reporting/reports.php:
|
4188 |
msgid "Select start year"
|
4189 |
msgstr ""
|
4190 |
|
4191 |
-
#: includes/admin/reporting/reports.php:
|
4192 |
msgctxt "Date one to date two"
|
4193 |
msgid "— to —"
|
4194 |
msgstr ""
|
4195 |
|
4196 |
-
#: includes/admin/reporting/reports.php:
|
4197 |
msgid "Export Earnings End"
|
4198 |
msgstr ""
|
4199 |
|
4200 |
-
#: includes/admin/reporting/reports.php:
|
4201 |
msgid "Select end month"
|
4202 |
msgstr ""
|
4203 |
|
4204 |
-
#: includes/admin/reporting/reports.php:
|
4205 |
msgid "Select end year"
|
4206 |
msgstr ""
|
4207 |
|
4208 |
-
#: includes/admin/reporting/reports.php:
|
4209 |
-
#: includes/admin/reporting/reports.php:
|
4210 |
-
#: includes/admin/reporting/reports.php:
|
4211 |
-
#: includes/admin/reporting/reports.php:
|
4212 |
-
#: includes/admin/reporting/reports.php:
|
4213 |
-
#: includes/admin/reporting/reports.php:
|
4214 |
-
#: includes/admin/reporting/reports.php:
|
4215 |
-
#: includes/admin/reporting/reports.php:
|
4216 |
msgid "Generate CSV"
|
4217 |
msgstr ""
|
4218 |
|
4219 |
-
#: includes/admin/reporting/reports.php:
|
4220 |
msgid "Export Sales and Earnings"
|
4221 |
msgstr ""
|
4222 |
|
4223 |
-
#: includes/admin/reporting/reports.php:
|
4224 |
msgid "Download a CSV of all sales or earnings on a day-by-day basis."
|
4225 |
msgstr ""
|
4226 |
|
4227 |
-
#: includes/admin/reporting/reports.php:
|
4228 |
msgid "Export Sales and Earnings Dates"
|
4229 |
msgstr ""
|
4230 |
|
4231 |
-
#: includes/admin/reporting/reports.php:
|
4232 |
-
#: includes/admin/reporting/reports.php:
|
4233 |
-
#: includes/admin/reporting/reports.php:
|
4234 |
-
#: includes/admin/reporting/reports.php:
|
4235 |
-
#: includes/admin/reporting/reports.php:
|
4236 |
-
#: includes/admin/reporting/reports.php:
|
4237 |
msgid "Set start date"
|
4238 |
msgstr ""
|
4239 |
|
4240 |
-
#: includes/admin/reporting/reports.php:
|
4241 |
-
#: includes/admin/reporting/reports.php:
|
4242 |
-
#: includes/admin/reporting/reports.php:
|
4243 |
-
#: includes/admin/reporting/reports.php:
|
4244 |
-
#: includes/admin/reporting/reports.php:
|
4245 |
-
#: includes/admin/reporting/reports.php:
|
4246 |
msgid "Set end date"
|
4247 |
msgstr ""
|
4248 |
|
4249 |
-
#: includes/admin/reporting/reports.php:
|
4250 |
-
#: includes/admin/reporting/reports.php:
|
4251 |
-
#: includes/admin/reporting/reports.php:
|
4252 |
-
#: includes/admin/reporting/reports.php:
|
4253 |
msgid "Select Download"
|
4254 |
msgstr ""
|
4255 |
|
4256 |
-
#: includes/admin/reporting/reports.php:
|
4257 |
msgid "Select Customer"
|
4258 |
msgstr ""
|
4259 |
|
4260 |
-
#: includes/admin/reporting/reports.php:
|
4261 |
msgid "All Customers"
|
4262 |
msgstr ""
|
4263 |
|
4264 |
-
#: includes/admin/reporting/reports.php:
|
4265 |
msgid "Export Orders"
|
4266 |
msgstr ""
|
4267 |
|
4268 |
-
#: includes/admin/reporting/reports.php:
|
4269 |
msgid "Download a CSV of all orders."
|
4270 |
msgstr ""
|
4271 |
|
4272 |
-
#: includes/admin/reporting/reports.php:
|
4273 |
msgid "Export Order Dates"
|
4274 |
msgstr ""
|
4275 |
|
4276 |
-
#: includes/admin/reporting/reports.php:
|
4277 |
-
#: includes/admin/reporting/reports.php:
|
4278 |
msgid "Select Status"
|
4279 |
msgstr ""
|
4280 |
|
4281 |
-
#: includes/admin/reporting/reports.php:
|
4282 |
-
#: includes/admin/reporting/reports.php:
|
4283 |
msgid "All Statuses"
|
4284 |
msgstr ""
|
4285 |
|
4286 |
-
#: includes/admin/reporting/reports.php:
|
4287 |
msgid "Export Taxed Orders"
|
4288 |
msgstr ""
|
4289 |
|
4290 |
-
#: includes/admin/reporting/reports.php:
|
4291 |
msgid "Download a CSV of all orders, taxed by Country and/or Region."
|
4292 |
msgstr ""
|
4293 |
|
4294 |
-
#: includes/admin/reporting/reports.php:
|
4295 |
msgid "Export Taxed Order Dates"
|
4296 |
msgstr ""
|
4297 |
|
4298 |
-
#: includes/admin/reporting/reports.php:
|
4299 |
msgid "Select Country"
|
4300 |
msgstr ""
|
4301 |
|
4302 |
-
#: includes/admin/reporting/reports.php:
|
4303 |
msgid "Select Region"
|
4304 |
msgstr ""
|
4305 |
|
4306 |
-
#: includes/admin/reporting/reports.php:
|
4307 |
#: includes/class-edd-html-elements.php:656
|
4308 |
msgid "All Regions"
|
4309 |
msgstr ""
|
4310 |
|
4311 |
-
#: includes/admin/reporting/reports.php:
|
4312 |
msgid "Export Customers"
|
4313 |
msgstr ""
|
4314 |
|
4315 |
-
#: includes/admin/reporting/reports.php:
|
4316 |
msgid "Download a CSV of customers. Select a taxonomy to see all the customers who purchased %s in that taxonomy."
|
4317 |
msgstr ""
|
4318 |
|
4319 |
-
#: includes/admin/reporting/reports.php:
|
4320 |
#: includes/blocks/build/terms/index.js:1
|
4321 |
msgid "Select Taxonomy"
|
4322 |
msgstr ""
|
4323 |
|
4324 |
-
#: includes/admin/reporting/reports.php:
|
4325 |
msgid "All Taxonomies"
|
4326 |
msgstr ""
|
4327 |
|
4328 |
-
#: includes/admin/reporting/reports.php:
|
4329 |
msgid "Export Taxed Customers"
|
4330 |
msgstr ""
|
4331 |
|
4332 |
-
#: includes/admin/reporting/reports.php:
|
4333 |
msgid "Download a CSV of all customers that were taxed."
|
4334 |
msgstr ""
|
4335 |
|
4336 |
-
#: includes/admin/reporting/reports.php:
|
4337 |
msgid "Export Taxed Customer Dates"
|
4338 |
msgstr ""
|
4339 |
|
4340 |
#. translators: the singular post type label
|
4341 |
-
#: includes/admin/reporting/reports.php:
|
4342 |
msgid "Export %s Products"
|
4343 |
msgstr ""
|
4344 |
|
4345 |
#. translators: the plural post type label
|
4346 |
-
#: includes/admin/reporting/reports.php:
|
4347 |
msgid "Download a CSV of product %1$s."
|
4348 |
msgstr ""
|
4349 |
|
4350 |
-
#: includes/admin/reporting/reports.php:
|
4351 |
msgid "Export API Request Logs"
|
4352 |
msgstr ""
|
4353 |
|
4354 |
-
#: includes/admin/reporting/reports.php:
|
4355 |
msgid "Download a CSV of API request logs."
|
4356 |
msgstr ""
|
4357 |
|
4358 |
-
#: includes/admin/reporting/reports.php:
|
4359 |
msgid "Export API Request Log Dates"
|
4360 |
msgstr ""
|
4361 |
|
4362 |
-
#: includes/admin/reporting/reports.php:
|
4363 |
msgid "Export File Download Logs"
|
4364 |
msgstr ""
|
4365 |
|
4366 |
-
#: includes/admin/reporting/reports.php:
|
4367 |
msgid "Download a CSV of file download logs."
|
4368 |
msgstr ""
|
4369 |
|
4370 |
-
#: includes/admin/reporting/reports.php:
|
4371 |
msgid "Export File Download Log Dates"
|
4372 |
msgstr ""
|
4373 |
|
4374 |
-
#: includes/admin/reporting/reports.php:
|
4375 |
#: includes/user-functions.php:922
|
4376 |
#: includes/user-functions.php:926
|
4377 |
msgid "Notice"
|
4378 |
msgstr ""
|
4379 |
|
4380 |
-
#: includes/admin/reporting/reports.php:
|
4381 |
msgid "Tax reports are only generated for taxes associated with a location. The legacy default tax rate is unable to be reported on."
|
4382 |
msgstr ""
|
4383 |
|
@@ -6655,7 +6660,7 @@ msgid "Orders placed through the Amazon gateway must be refunded through Amazon.
|
|
6655 |
msgstr ""
|
6656 |
|
6657 |
#: includes/admin/views/tmpl-order-adjustment-discount.php:27
|
6658 |
-
#: includes/discount-functions.php:
|
6659 |
msgid "Remove discount"
|
6660 |
msgstr ""
|
6661 |
|
@@ -6665,7 +6670,7 @@ msgstr ""
|
|
6665 |
#: includes/blocks/views/checkout/discount.php:16
|
6666 |
#: includes/blocks/views/orders/discounts.php:7
|
6667 |
#: includes/checkout/template.php:741
|
6668 |
-
#: includes/discount-functions.php:
|
6669 |
#: templates/shortcode-receipt.php:87
|
6670 |
msgid "Discount"
|
6671 |
msgid_plural "Discounts"
|
@@ -6991,7 +6996,7 @@ msgstr ""
|
|
6991 |
|
6992 |
#: includes/blocks/edd-blocks.php:86
|
6993 |
#: includes/emails/tags.php:245
|
6994 |
-
#: includes/emails/template.php:
|
6995 |
msgid "Receipt"
|
6996 |
msgstr ""
|
6997 |
|
@@ -7108,18 +7113,18 @@ msgstr ""
|
|
7108 |
msgid "Your cart is empty."
|
7109 |
msgstr ""
|
7110 |
|
7111 |
-
#: includes/blocks/includes/checkout/forms.php:
|
7112 |
#: includes/blocks/views/checkout/purchase-form/login.php:26
|
7113 |
#: includes/checkout/template.php:497
|
7114 |
#: includes/checkout/template.php:602
|
7115 |
msgid "Log in"
|
7116 |
msgstr ""
|
7117 |
|
7118 |
-
#: includes/blocks/includes/checkout/forms.php:
|
7119 |
msgid "Register for a new account"
|
7120 |
msgstr ""
|
7121 |
|
7122 |
-
#: includes/blocks/includes/checkout/forms.php:
|
7123 |
msgid "Check out as a guest"
|
7124 |
msgstr ""
|
7125 |
|
@@ -7156,13 +7161,13 @@ msgid "reCAPTCHA verification failed with low score. Please contact a site admin
|
|
7156 |
msgstr ""
|
7157 |
|
7158 |
#: includes/blocks/includes/orders/functions.php:30
|
7159 |
-
#: templates/history-purchases.php:
|
7160 |
msgid "Complete Purchase"
|
7161 |
msgstr ""
|
7162 |
|
7163 |
#: includes/blocks/includes/orders/functions.php:38
|
7164 |
#: includes/blocks/includes/orders/orders.php:158
|
7165 |
-
#: templates/history-purchases.php:
|
7166 |
msgid "View Details and Downloads"
|
7167 |
msgstr ""
|
7168 |
|
@@ -7397,38 +7402,38 @@ msgstr ""
|
|
7397 |
msgid "Personal Info"
|
7398 |
msgstr ""
|
7399 |
|
7400 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7401 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7402 |
#: includes/checkout/template.php:183
|
7403 |
#: includes/checkout/template.php:189
|
7404 |
msgid "Email address"
|
7405 |
msgstr ""
|
7406 |
|
7407 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7408 |
#: includes/checkout/template.php:188
|
7409 |
msgid "We will send the purchase receipt to this address."
|
7410 |
msgstr ""
|
7411 |
|
7412 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7413 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7414 |
#: includes/checkout/template.php:194
|
7415 |
#: includes/checkout/template.php:200
|
7416 |
msgid "First name"
|
7417 |
msgstr ""
|
7418 |
|
7419 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7420 |
#: includes/checkout/template.php:199
|
7421 |
msgid "We will use this to personalize your account experience."
|
7422 |
msgstr ""
|
7423 |
|
7424 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7425 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7426 |
#: includes/checkout/template.php:204
|
7427 |
#: includes/checkout/template.php:210
|
7428 |
msgid "Last name"
|
7429 |
msgstr ""
|
7430 |
|
7431 |
-
#: includes/blocks/views/checkout/purchase-form/personal-info.php:
|
7432 |
#: includes/checkout/template.php:209
|
7433 |
msgid "We will use this as well to personalize your account experience."
|
7434 |
msgstr ""
|
@@ -7463,7 +7468,7 @@ msgid "Log In"
|
|
7463 |
msgstr ""
|
7464 |
|
7465 |
#: includes/blocks/views/forms/login.php:44
|
7466 |
-
#: includes/payments/actions.php:
|
7467 |
#: templates/shortcode-login.php:33
|
7468 |
#: includes/blocks/build/login/index.js:1
|
7469 |
msgid "Lost Password?"
|
@@ -7515,7 +7520,7 @@ msgstr ""
|
|
7515 |
|
7516 |
#: includes/blocks/views/orders/receipt-files.php:70
|
7517 |
#: includes/emails/tags.php:378
|
7518 |
-
#: templates/history-downloads.php:
|
7519 |
#: templates/shortcode-receipt.php:306
|
7520 |
msgid "No downloadable files found."
|
7521 |
msgstr ""
|
@@ -7897,7 +7902,7 @@ msgstr ""
|
|
7897 |
#. translators: the order item's status.
|
7898 |
#: includes/class-edd-cli.php:185
|
7899 |
#: includes/class-edd-cli.php:444
|
7900 |
-
#: templates/history-downloads.php:
|
7901 |
msgid "Status: %s"
|
7902 |
msgstr ""
|
7903 |
|
@@ -8098,12 +8103,12 @@ msgid "Single Use: %s"
|
|
8098 |
msgstr ""
|
8099 |
|
8100 |
#: includes/class-edd-cli.php:486
|
8101 |
-
#: includes/class-edd-cli.php:
|
8102 |
msgid "No action specified, did you mean"
|
8103 |
msgstr ""
|
8104 |
|
8105 |
#: includes/class-edd-cli.php:488
|
8106 |
-
#: includes/class-edd-cli.php:
|
8107 |
msgid "Invalid action specified, did you mean"
|
8108 |
msgstr ""
|
8109 |
|
@@ -8124,295 +8129,299 @@ msgid "Created %s discounts"
|
|
8124 |
msgstr ""
|
8125 |
|
8126 |
#: includes/class-edd-cli.php:899
|
|
|
|
|
|
|
|
|
8127 |
msgid "The discounts custom database migration has already been run. To do this anyway, use the --force argument."
|
8128 |
msgstr ""
|
8129 |
|
8130 |
-
#: includes/class-edd-cli.php:
|
8131 |
msgid "Migration complete: Discounts"
|
8132 |
msgstr ""
|
8133 |
|
8134 |
-
#: includes/class-edd-cli.php:
|
8135 |
-
#: includes/class-edd-cli.php:
|
8136 |
-
#: includes/class-edd-cli.php:
|
8137 |
-
#: includes/class-edd-cli.php:
|
8138 |
msgid "Old Records: "
|
8139 |
msgstr ""
|
8140 |
|
8141 |
-
#: includes/class-edd-cli.php:
|
8142 |
-
#: includes/class-edd-cli.php:
|
8143 |
-
#: includes/class-edd-cli.php:
|
8144 |
-
#: includes/class-edd-cli.php:
|
8145 |
msgid "New Records: "
|
8146 |
msgstr ""
|
8147 |
|
8148 |
-
#: includes/class-edd-cli.php:
|
8149 |
msgid "No discount records found."
|
8150 |
msgstr ""
|
8151 |
|
8152 |
-
#: includes/class-edd-cli.php:
|
8153 |
msgid "The logs custom table migration has already been run. To do this anyway, use the --force argument."
|
8154 |
msgstr ""
|
8155 |
|
8156 |
-
#: includes/class-edd-cli.php:
|
8157 |
msgid "Preparing to migrate logs (this can take several minutes)."
|
8158 |
msgstr ""
|
8159 |
|
8160 |
-
#: includes/class-edd-cli.php:
|
8161 |
msgid "Migrating Logs"
|
8162 |
msgstr ""
|
8163 |
|
8164 |
-
#: includes/class-edd-cli.php:
|
8165 |
msgid "No log records found."
|
8166 |
msgstr ""
|
8167 |
|
8168 |
-
#: includes/class-edd-cli.php:
|
8169 |
msgid "Migration complete: Logs"
|
8170 |
msgstr ""
|
8171 |
|
8172 |
-
#: includes/class-edd-cli.php:
|
8173 |
msgid "The order notes custom table migration has already been run. To do this anyway, use the --force argument."
|
8174 |
msgstr ""
|
8175 |
|
8176 |
-
#: includes/class-edd-cli.php:
|
8177 |
msgid "Preparing to migrate order notes."
|
8178 |
msgstr ""
|
8179 |
|
8180 |
-
#: includes/class-edd-cli.php:
|
8181 |
msgid "Migrating Order Notes"
|
8182 |
msgstr ""
|
8183 |
|
8184 |
-
#: includes/class-edd-cli.php:
|
8185 |
msgid "No order notes found."
|
8186 |
msgstr ""
|
8187 |
|
8188 |
-
#: includes/class-edd-cli.php:
|
8189 |
msgid "Migration complete: Order Notes"
|
8190 |
msgstr ""
|
8191 |
|
8192 |
-
#: includes/class-edd-cli.php:
|
8193 |
msgid "Old order notes: "
|
8194 |
msgstr ""
|
8195 |
|
8196 |
-
#: includes/class-edd-cli.php:
|
8197 |
msgid "New order notes: "
|
8198 |
msgstr ""
|
8199 |
|
8200 |
-
#: includes/class-edd-cli.php:
|
8201 |
msgid "The customer notes custom table migration has already been run. To do this anyway, use the --force argument."
|
8202 |
msgstr ""
|
8203 |
|
8204 |
-
#: includes/class-edd-cli.php:
|
8205 |
msgid "Preparing to migrate customer notes."
|
8206 |
msgstr ""
|
8207 |
|
8208 |
-
#: includes/class-edd-cli.php:
|
8209 |
msgid "Migrating Customer Notes"
|
8210 |
msgstr ""
|
8211 |
|
8212 |
-
#: includes/class-edd-cli.php:
|
8213 |
msgid "No customer notes found."
|
8214 |
msgstr ""
|
8215 |
|
8216 |
-
#: includes/class-edd-cli.php:
|
8217 |
msgid "Migration complete: Customer Notes"
|
8218 |
msgstr ""
|
8219 |
|
8220 |
-
#: includes/class-edd-cli.php:
|
8221 |
msgid "Old customer notes: "
|
8222 |
msgstr ""
|
8223 |
|
8224 |
-
#: includes/class-edd-cli.php:
|
8225 |
msgid "New customer notes: "
|
8226 |
msgstr ""
|
8227 |
|
8228 |
-
#: includes/class-edd-cli.php:
|
8229 |
msgid "Preparing to migrate additional customer data."
|
8230 |
msgstr ""
|
8231 |
|
8232 |
-
#: includes/class-edd-cli.php:
|
8233 |
msgid "The user addresses custom table migration has already been run. To do this anyway, use the --force argument."
|
8234 |
msgstr ""
|
8235 |
|
8236 |
-
#: includes/class-edd-cli.php:
|
8237 |
msgid "Preparing to migrate customer address data."
|
8238 |
msgstr ""
|
8239 |
|
8240 |
-
#: includes/class-edd-cli.php:
|
8241 |
msgid "Migrating Customer Addresses"
|
8242 |
msgstr ""
|
8243 |
|
8244 |
-
#: includes/class-edd-cli.php:
|
8245 |
msgid "The user email addresses custom table migration has already been run. To do this anyway, use the --force argument."
|
8246 |
msgstr ""
|
8247 |
|
8248 |
-
#: includes/class-edd-cli.php:
|
8249 |
msgid "Preparing to migrate customer email addresses (this can take several minutes)."
|
8250 |
msgstr ""
|
8251 |
|
8252 |
-
#: includes/class-edd-cli.php:
|
8253 |
msgid "Migrating Customer Email Addresses"
|
8254 |
msgstr ""
|
8255 |
|
8256 |
-
#: includes/class-edd-cli.php:
|
8257 |
msgid "Migration complete: Customer Email Addresses"
|
8258 |
msgstr ""
|
8259 |
|
8260 |
-
#: includes/class-edd-cli.php:
|
8261 |
msgid "The tax rates custom table migration has already been run. To do this anyway, use the --force argument."
|
8262 |
msgstr ""
|
8263 |
|
8264 |
-
#: includes/class-edd-cli.php:
|
8265 |
msgid "Checking for default tax rate"
|
8266 |
msgstr ""
|
8267 |
|
8268 |
-
#: includes/class-edd-cli.php:
|
8269 |
msgid "Migrating default tax rate"
|
8270 |
msgstr ""
|
8271 |
|
8272 |
-
#: includes/class-edd-cli.php:
|
8273 |
msgid "Migration complete: Tax Rates"
|
8274 |
msgstr ""
|
8275 |
|
8276 |
-
#: includes/class-edd-cli.php:
|
8277 |
msgid "This process will remove and recreate orders in your database. Please make sure you've backed up your EDD database tables. Are you sure you want to delete orders that have already been migrated and run the migration again?"
|
8278 |
msgstr ""
|
8279 |
|
8280 |
-
#: includes/class-edd-cli.php:
|
8281 |
msgid "The payments custom table migration has already been run. To do this anyway, use the --force argument."
|
8282 |
msgstr ""
|
8283 |
|
8284 |
-
#: includes/class-edd-cli.php:
|
8285 |
msgid "Preparing to migrate payments."
|
8286 |
msgstr ""
|
8287 |
|
8288 |
-
#: includes/class-edd-cli.php:
|
8289 |
msgid "Migrating Payments"
|
8290 |
msgstr ""
|
8291 |
|
8292 |
-
#: includes/class-edd-cli.php:
|
8293 |
msgid "An EDD Payment could not be found for that ID."
|
8294 |
msgstr ""
|
8295 |
|
8296 |
-
#: includes/class-edd-cli.php:
|
8297 |
msgid "The payment ID must be an integer from the post_id column."
|
8298 |
msgstr ""
|
8299 |
|
8300 |
-
#: includes/class-edd-cli.php:
|
8301 |
msgid "The starting ID must be an integer from the post_id column."
|
8302 |
msgstr ""
|
8303 |
|
8304 |
-
#: includes/class-edd-cli.php:
|
8305 |
msgid "The ending ID must be an integer from the post_id column."
|
8306 |
msgstr ""
|
8307 |
|
8308 |
-
#: includes/class-edd-cli.php:
|
8309 |
msgid "Are you sure you want to run a partial order migration?"
|
8310 |
msgstr ""
|
8311 |
|
8312 |
#. translators: 1. the refund order ID; 2. the original payment ID.
|
8313 |
-
#: includes/class-edd-cli.php:
|
8314 |
msgid "%1$d is a refund order. EDD will delete the refund and migrate payment %1$d, then re-migrate payment %2$d."
|
8315 |
msgstr ""
|
8316 |
|
8317 |
#. translators: 1. the order/payment ID.
|
8318 |
-
#: includes/class-edd-cli.php:
|
8319 |
msgid "Order ID %1$d appears to be a different record from Payment ID %1$d. Are you sure you want to destroy this order and overwrite it?"
|
8320 |
msgstr ""
|
8321 |
|
8322 |
#. translators: payment ID.
|
8323 |
-
#: includes/class-edd-cli.php:
|
8324 |
msgid "Migration failed for payment %d."
|
8325 |
msgstr ""
|
8326 |
|
8327 |
-
#: includes/class-edd-cli.php:
|
8328 |
msgid "No payment records found."
|
8329 |
msgstr ""
|
8330 |
|
8331 |
-
#: includes/class-edd-cli.php:
|
8332 |
msgid "Partial order migration complete. Orders Processed: "
|
8333 |
msgstr ""
|
8334 |
|
8335 |
-
#: includes/class-edd-cli.php:
|
8336 |
msgid "To recalculate all download sales and earnings, run wp edd `recalculate_download_sales_earnings`."
|
8337 |
msgstr ""
|
8338 |
|
8339 |
-
#: includes/class-edd-cli.php:
|
8340 |
msgid "Migration complete: Orders"
|
8341 |
msgstr ""
|
8342 |
|
8343 |
-
#: includes/class-edd-cli.php:
|
8344 |
msgid "Refund Records Created: "
|
8345 |
msgstr ""
|
8346 |
|
8347 |
-
#: includes/class-edd-cli.php:
|
8348 |
msgid "You must enter a payment ID to display legacy data."
|
8349 |
msgstr ""
|
8350 |
|
8351 |
-
#: includes/class-edd-cli.php:
|
8352 |
msgid "The legacy payment data could not be found."
|
8353 |
msgstr ""
|
8354 |
|
8355 |
-
#: includes/class-edd-cli.php:
|
8356 |
msgid "Sales and Earnings successfully recalculated for all downloads."
|
8357 |
msgstr ""
|
8358 |
|
8359 |
-
#: includes/class-edd-cli.php:
|
8360 |
msgid "Downloads Updated: "
|
8361 |
msgstr ""
|
8362 |
|
8363 |
-
#: includes/class-edd-cli.php:
|
8364 |
msgid "Do you want to remove legacy data? This will permanently remove legacy discounts, logs, and order notes."
|
8365 |
msgstr ""
|
8366 |
|
8367 |
-
#: includes/class-edd-cli.php:
|
8368 |
msgid "Legacy discounts have already been removed. To run this anyway, use the --force argument."
|
8369 |
msgstr ""
|
8370 |
|
8371 |
-
#: includes/class-edd-cli.php:
|
8372 |
msgid "Removing old discount data."
|
8373 |
msgstr ""
|
8374 |
|
8375 |
-
#: includes/class-edd-cli.php:
|
8376 |
msgid "Legacy logs have already been removed. To run this anyway, use the --force argument."
|
8377 |
msgstr ""
|
8378 |
|
8379 |
-
#: includes/class-edd-cli.php:
|
8380 |
msgid "Removing old logs."
|
8381 |
msgstr ""
|
8382 |
|
8383 |
-
#: includes/class-edd-cli.php:
|
8384 |
msgid "Legacy order notes have already been removed. To run this anyway, use the --force argument."
|
8385 |
msgstr ""
|
8386 |
|
8387 |
-
#: includes/class-edd-cli.php:
|
8388 |
msgid "Removing old order notes."
|
8389 |
msgstr ""
|
8390 |
|
8391 |
-
#: includes/class-edd-cli.php:
|
8392 |
msgid "Updating customers database table."
|
8393 |
msgstr ""
|
8394 |
|
8395 |
-
#: includes/class-edd-cli.php:
|
8396 |
msgid "Legacy customer emails have already been removed. To run this anyway, use the --force argument."
|
8397 |
msgstr ""
|
8398 |
|
8399 |
-
#: includes/class-edd-cli.php:
|
8400 |
msgid "Removing old customer emails."
|
8401 |
msgstr ""
|
8402 |
|
8403 |
-
#: includes/class-edd-cli.php:
|
8404 |
msgid "Legacy customer addresses have already been removed. To run this anyway, use the --force argument."
|
8405 |
msgstr ""
|
8406 |
|
8407 |
-
#: includes/class-edd-cli.php:
|
8408 |
msgid "Removing old customer addresses."
|
8409 |
msgstr ""
|
8410 |
|
8411 |
-
#: includes/class-edd-cli.php:
|
8412 |
msgid "Legacy orders have already been removed. To run this anyway, use the --force argument."
|
8413 |
msgstr ""
|
8414 |
|
8415 |
-
#: includes/class-edd-cli.php:
|
8416 |
msgid "Removing old orders."
|
8417 |
msgstr ""
|
8418 |
|
@@ -9296,7 +9305,7 @@ msgid "Enter the email that is sent to sale notification emails after completion
|
|
9296 |
msgstr ""
|
9297 |
|
9298 |
#: includes/deprecated-functions.php:488
|
9299 |
-
#: includes/process-download.php:
|
9300 |
msgid "Sorry but you have hit your download limit for this file."
|
9301 |
msgstr ""
|
9302 |
|
@@ -9700,7 +9709,7 @@ msgstr ""
|
|
9700 |
msgid "Preview Purchase Receipt"
|
9701 |
msgstr ""
|
9702 |
|
9703 |
-
#: includes/emails/template.php:
|
9704 |
msgid "Missing purchase key."
|
9705 |
msgstr ""
|
9706 |
|
@@ -9812,6 +9821,7 @@ msgstr ""
|
|
9812 |
msgid "Invalid Amazon seller ID"
|
9813 |
msgstr ""
|
9814 |
|
|
|
9815 |
#: includes/gateways/amazon-payments.php:1024
|
9816 |
#: includes/gateways/amazon-payments.php:1064
|
9817 |
#: includes/gateways/paypal-standard.php:492
|
@@ -9820,6 +9830,8 @@ msgstr ""
|
|
9820 |
#: includes/gateways/paypal-standard.php:602
|
9821 |
#: includes/gateways/paypal-standard.php:675
|
9822 |
#: includes/gateways/paypal-standard.php:684
|
|
|
|
|
9823 |
msgid "IPN Error"
|
9824 |
msgstr ""
|
9825 |
|
@@ -10107,120 +10119,132 @@ msgid "PayPal refund failed: %s"
|
|
10107 |
msgstr ""
|
10108 |
|
10109 |
#: includes/gateways/paypal/admin/connect.php:32
|
10110 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10111 |
msgid "sandbox"
|
10112 |
msgstr ""
|
10113 |
|
10114 |
#: includes/gateways/paypal/admin/connect.php:32
|
10115 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10116 |
msgid "live"
|
10117 |
msgstr ""
|
10118 |
|
10119 |
#. Translators: %1$s opening <strong> tag; %2$s closing </strong> tag
|
10120 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10121 |
msgid "%1$sConnection failure:%2$s Please ensure browser popups are enabled then click the button below to connect again. If you continue to experience this error, please contact support."
|
10122 |
msgstr ""
|
10123 |
|
10124 |
#. Translators: %s - the store mode, either `sandbox` or `live`
|
10125 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10126 |
msgid "Connect with PayPal in %s mode"
|
10127 |
msgstr ""
|
10128 |
|
10129 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10130 |
msgid "Sign up for PayPal"
|
10131 |
msgstr ""
|
10132 |
|
10133 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10134 |
#: includes/gateways/stripe/includes/admin/settings/stripe-connect.php:342
|
10135 |
msgid "Retrieving account information..."
|
10136 |
msgstr ""
|
10137 |
|
10138 |
-
#: includes/gateways/paypal/admin/connect.php:85
|
10139 |
-
msgid "Disconnect from PayPal"
|
10140 |
-
msgstr ""
|
10141 |
-
|
10142 |
#. Translators: %d - HTTP response code; %s - Response from the API
|
10143 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10144 |
msgid "Unexpected response code: %d. Error: %s"
|
10145 |
msgstr ""
|
10146 |
|
10147 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10148 |
msgid "An unexpected error occurred."
|
10149 |
msgstr ""
|
10150 |
|
10151 |
-
#: includes/gateways/paypal/admin/connect.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10152 |
msgid "Missing PayPal authentication information. Please try again."
|
10153 |
msgstr ""
|
10154 |
|
10155 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10156 |
msgid "Missing nonce. Please refresh the page and try again."
|
10157 |
msgstr ""
|
10158 |
|
10159 |
#. Translators: %d - HTTP response code
|
10160 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10161 |
msgid "Unexpected response from PayPal while generating token. Response code: %d. Please try again."
|
10162 |
msgstr ""
|
10163 |
|
10164 |
#. Translators: %d - HTTP response code
|
10165 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10166 |
msgid "Unexpected response from PayPal. Response code: %d. Please try again."
|
10167 |
msgstr ""
|
10168 |
|
10169 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10170 |
msgid "Successfully connected."
|
10171 |
msgstr ""
|
10172 |
|
10173 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10174 |
msgid "Your account has been successfully connected, but an error occurred while creating a webhook."
|
10175 |
msgstr ""
|
10176 |
|
10177 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10178 |
msgid "Re-Check Payment Status"
|
10179 |
msgstr ""
|
10180 |
|
10181 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10182 |
msgid "Sync Webhook"
|
10183 |
msgstr ""
|
10184 |
|
10185 |
-
#: includes/gateways/paypal/admin/connect.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10186 |
msgid "API:"
|
10187 |
msgstr ""
|
10188 |
|
10189 |
#. Translators: %s - the connected mode, either `sandbox` or `live`
|
10190 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10191 |
msgid "Your PayPal account is successfully connected in %s mode."
|
10192 |
msgstr ""
|
10193 |
|
10194 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10195 |
msgid "Payment Status:"
|
10196 |
msgstr ""
|
10197 |
|
10198 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10199 |
msgid "You need to address the following issues before you can start receiving payments:"
|
10200 |
msgstr ""
|
10201 |
|
10202 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10203 |
msgid "Ready to accept payments."
|
10204 |
msgstr ""
|
10205 |
|
10206 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10207 |
msgid "Webhook:"
|
10208 |
msgstr ""
|
10209 |
|
10210 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10211 |
-
msgid "Create
|
10212 |
msgstr ""
|
10213 |
|
10214 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10215 |
msgid "Webhook successfully configured for the following events:"
|
10216 |
msgstr ""
|
10217 |
|
10218 |
#. Translators: %1$s opening anchor tag; %2$s closing anchor tag; %3$s: opening line item/status/strong tags; %4$s closing strong tag; %5$s: closing list item tag
|
10219 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10220 |
msgid "%3$sGateway Status: %4$s PayPal is not currently active. %1$sEnable PayPal%2$s in the general gateway settings to start using it.%5$s"
|
10221 |
msgstr ""
|
10222 |
|
10223 |
-
#: includes/gateways/paypal/admin/connect.php:
|
10224 |
msgid "No merchant ID saved. Please reconnect to PayPal."
|
10225 |
msgstr ""
|
10226 |
|
@@ -10423,6 +10447,47 @@ msgstr ""
|
|
10423 |
msgid "Response Code: %d; Message: %s"
|
10424 |
msgstr ""
|
10425 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10426 |
#. Translators: %d - ID of the refund; %s - error message from PayPal
|
10427 |
#: includes/gateways/paypal/refunds.php:107
|
10428 |
msgid "Failure when processing PayPal refund #%d: %s"
|
@@ -10469,18 +10534,6 @@ msgstr ""
|
|
10469 |
msgid "PayPal transaction denied."
|
10470 |
msgstr ""
|
10471 |
|
10472 |
-
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:53
|
10473 |
-
msgid "Amount: %1$s; Payment transaction ID: %2$s; Refund transaction ID: %3$s"
|
10474 |
-
msgstr ""
|
10475 |
-
|
10476 |
-
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:64
|
10477 |
-
msgid "Partial refund processed in PayPal."
|
10478 |
-
msgstr ""
|
10479 |
-
|
10480 |
-
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:72
|
10481 |
-
msgid "Full refund processed in PayPal."
|
10482 |
-
msgstr ""
|
10483 |
-
|
10484 |
#: includes/gateways/paypal/webhooks/functions.php:86
|
10485 |
msgid "An SSL certificate is required to create a PayPal webhook."
|
10486 |
msgstr ""
|
@@ -10503,17 +10556,21 @@ msgstr ""
|
|
10503 |
msgid "Invalid response code %d while syncing webhook. Response: %s"
|
10504 |
msgstr ""
|
10505 |
|
10506 |
-
#. Translators: %d - HTTP response code.
|
10507 |
#: includes/gateways/paypal/webhooks/functions.php:226
|
|
|
|
|
|
|
|
|
|
|
10508 |
msgid "Invalid response code %d while retrieving webhook details."
|
10509 |
msgstr ""
|
10510 |
|
10511 |
-
#: includes/gateways/paypal/webhooks/functions.php:
|
10512 |
msgid "Unexpected response from PayPal when retrieving webhook details."
|
10513 |
msgstr ""
|
10514 |
|
10515 |
#. Translators: %d - HTTP response code.
|
10516 |
-
#: includes/gateways/paypal/webhooks/functions.php:
|
10517 |
msgid "Invalid response code %d while deleting webhook."
|
10518 |
msgstr ""
|
10519 |
|
@@ -11543,7 +11600,7 @@ msgstr ""
|
|
11543 |
msgid "The maximum refund %s for the adjustment \"%s\" is %s."
|
11544 |
msgstr ""
|
11545 |
|
11546 |
-
#: includes/orders/functions/orders.php:
|
11547 |
msgid "Payment recovery processed"
|
11548 |
msgstr ""
|
11549 |
|
@@ -11587,21 +11644,21 @@ msgstr ""
|
|
11587 |
msgid "After payment actions processed."
|
11588 |
msgstr ""
|
11589 |
|
11590 |
-
#: includes/payments/actions.php:
|
11591 |
-
#: includes/payments/actions.php:
|
11592 |
msgid "Error resuming payment."
|
11593 |
msgstr ""
|
11594 |
|
11595 |
-
#: includes/payments/actions.php:
|
11596 |
msgid "Payment recovery triggered URL"
|
11597 |
msgstr ""
|
11598 |
|
11599 |
-
#: includes/payments/actions.php:
|
11600 |
-
#: includes/payments/actions.php:
|
11601 |
msgid "To complete this payment, please login to your account."
|
11602 |
msgstr ""
|
11603 |
|
11604 |
-
#: includes/payments/actions.php:
|
11605 |
msgid "Lost Password"
|
11606 |
msgstr ""
|
11607 |
|
@@ -12237,15 +12294,15 @@ msgstr ""
|
|
12237 |
msgid "Purchase Verification Failed"
|
12238 |
msgstr ""
|
12239 |
|
12240 |
-
#: includes/process-download.php:
|
12241 |
msgid "Invalid file"
|
12242 |
msgstr ""
|
12243 |
|
12244 |
-
#: includes/process-download.php:
|
12245 |
msgid "The requested file could not be found. Error 404."
|
12246 |
msgstr ""
|
12247 |
|
12248 |
-
#: includes/process-download.php:
|
12249 |
msgid "File not found"
|
12250 |
msgstr ""
|
12251 |
|
@@ -13030,15 +13087,15 @@ msgstr ""
|
|
13030 |
msgid "Your account has been successfully verified!"
|
13031 |
msgstr ""
|
13032 |
|
13033 |
-
#: templates/history-downloads.php:
|
13034 |
msgid "Download Name"
|
13035 |
msgstr ""
|
13036 |
|
13037 |
-
#: templates/history-downloads.php:
|
13038 |
msgid "You have not purchased any downloads"
|
13039 |
msgstr ""
|
13040 |
|
13041 |
-
#: templates/history-purchases.php:
|
13042 |
msgid "You have not made any purchases."
|
13043 |
msgstr ""
|
13044 |
|
2 |
# This file is distributed under the same license as the Easy Digital Downloads plugin.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: Easy Digital Downloads 3.1.0.3\n"
|
6 |
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/easy-digital-downloads\n"
|
7 |
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
8 |
"Language-Team: LANGUAGE <LL@li.org>\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
+
"POT-Creation-Date: 2022-11-23T23:51:31+00:00\n"
|
13 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
14 |
+
"X-Generator: WP-CLI 2.7.1\n"
|
15 |
"X-Domain: easy-digital-downloads\n"
|
16 |
|
17 |
#. Plugin Name of the plugin
|
82 |
#: includes/admin/adjustments/adjustment-functions.php:43
|
83 |
#: includes/admin/adjustments/adjustment-functions.php:99
|
84 |
#: includes/admin/admin-pages.php:88
|
85 |
+
#: includes/admin/reporting/reports.php:2206
|
86 |
#: includes/admin/settings/display-settings.php:40
|
87 |
#: includes/admin/upgrades/upgrade-functions.php:1431
|
88 |
#: includes/post-types.php:129
|
248 |
#: includes/download-functions.php:1553
|
249 |
#: includes/EDD_SL_Plugin_Updater.php:486
|
250 |
#: includes/emails/actions.php:59
|
251 |
+
#: includes/emails/template.php:241
|
252 |
#: includes/error-tracking.php:60
|
253 |
#: includes/gateways/functions.php:320
|
254 |
#: includes/gateways/manual.php:33
|
255 |
#: includes/gateways/paypal-standard.php:170
|
256 |
+
#: includes/gateways/paypal/admin/connect.php:517
|
257 |
+
#: includes/gateways/paypal/admin/connect.php:521
|
258 |
+
#: includes/gateways/paypal/admin/connect.php:558
|
259 |
+
#: includes/gateways/paypal/admin/connect.php:562
|
260 |
+
#: includes/gateways/paypal/admin/connect.php:704
|
261 |
#: includes/gateways/stripe/includes/admin/upgrade-functions.php:80
|
262 |
#: includes/gateways/stripe/includes/payment-actions.php:1387
|
263 |
#: includes/process-download.php:296
|
264 |
+
#: includes/process-download.php:924
|
265 |
#: includes/query-filters.php:51
|
266 |
#: includes/user-functions.php:893
|
267 |
#: includes/user-functions.php:918
|
284 |
|
285 |
#: includes/admin/admin-pages.php:87
|
286 |
#: includes/admin/customers/customers.php:77
|
287 |
+
#: includes/admin/reporting/reports.php:2500
|
288 |
#: includes/admin/settings/display-settings.php:43
|
289 |
msgid "Customers"
|
290 |
msgstr ""
|
628 |
#: includes/admin/promos/class-promo-handler.php:128
|
629 |
#: includes/admin/tools/class-edd-tools-recount-all-stats.php:78
|
630 |
#: includes/admin/tools/class-edd-tools-recount-download-stats.php:117
|
631 |
+
#: includes/gateways/paypal/admin/connect.php:103
|
632 |
+
#: includes/gateways/paypal/admin/connect.php:163
|
633 |
+
#: includes/gateways/paypal/admin/connect.php:218
|
634 |
+
#: includes/gateways/paypal/admin/connect.php:328
|
635 |
+
#: includes/gateways/paypal/admin/connect.php:517
|
636 |
+
#: includes/gateways/paypal/admin/connect.php:521
|
637 |
+
#: includes/gateways/paypal/admin/connect.php:558
|
638 |
+
#: includes/gateways/paypal/admin/connect.php:562
|
639 |
+
#: includes/gateways/paypal/admin/connect.php:618
|
640 |
+
#: includes/gateways/paypal/admin/connect.php:652
|
641 |
+
#: includes/gateways/paypal/admin/connect.php:675
|
642 |
+
#: includes/gateways/paypal/admin/connect.php:704
|
643 |
msgid "You do not have permission to perform this action."
|
644 |
msgstr ""
|
645 |
|
820 |
#: includes/blocks/views/orders/totals.php:38
|
821 |
#: includes/privacy-functions.php:946
|
822 |
#: includes/reports/reports-functions.php:316
|
823 |
+
#: templates/history-purchases.php:52
|
824 |
#: templates/shortcode-receipt.php:69
|
825 |
msgid "Date"
|
826 |
msgstr ""
|
1211 |
#: includes/admin/customers/customers.php:708
|
1212 |
#: includes/admin/customers/customers.php:749
|
1213 |
#: includes/admin/payments/class-payments-table.php:384
|
1214 |
+
#: includes/admin/reporting/reports.php:1163
|
1215 |
msgid "Number"
|
1216 |
msgstr ""
|
1217 |
|
1394 |
#: includes/admin/reporting/reports.php:254
|
1395 |
#: includes/admin/reporting/reports.php:352
|
1396 |
#: includes/admin/reporting/reports.php:713
|
1397 |
+
#: includes/admin/reporting/reports.php:888
|
1398 |
+
#: includes/admin/reporting/reports.php:1307
|
1399 |
+
#: includes/admin/reporting/reports.php:1493
|
1400 |
+
#: includes/admin/reporting/reports.php:1629
|
1401 |
#: includes/reports/data/file-downloads/class-top-five-most-downloaded-list-table.php:61
|
1402 |
#: includes/blocks/build/downloads/index.js:1
|
1403 |
msgid "Earnings"
|
1498 |
#: includes/admin/reporting/class-export-payments.php:70
|
1499 |
#: includes/admin/reporting/export/class-batch-export-payments.php:56
|
1500 |
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:56
|
1501 |
+
#: includes/admin/reporting/reports.php:1151
|
1502 |
#: includes/admin/views/tmpl-order-adjustment-discount.php:41
|
1503 |
#: includes/admin/views/tmpl-order-adjustment.php:55
|
1504 |
#: includes/admin/views/tmpl-order-form-add-order-adjustment.php:80
|
1508 |
#: includes/admin/views/tmpl-order-tax.php:29
|
1509 |
#: includes/admin/views/tmpl-order-total.php:23
|
1510 |
#: includes/reports/data/discounts/class-top-five-discounts-list-table.php:78
|
1511 |
+
#: templates/history-purchases.php:53
|
1512 |
msgid "Amount"
|
1513 |
msgstr ""
|
1514 |
|
1968 |
#. translators: the plural post type label
|
1969 |
#: includes/admin/downloads/dashboard-columns.php:238
|
1970 |
#: includes/admin/downloads/dashboard-columns.php:250
|
1971 |
+
#: includes/admin/reporting/reports.php:2827
|
1972 |
+
#: includes/admin/reporting/reports.php:3028
|
1973 |
+
#: includes/admin/reporting/reports.php:3097
|
1974 |
+
#: includes/admin/reporting/reports.php:3163
|
1975 |
#: includes/reports/reports-functions.php:1387
|
1976 |
msgid "All %s"
|
1977 |
msgstr ""
|
2161 |
msgstr ""
|
2162 |
|
2163 |
#: includes/admin/downloads/metabox.php:942
|
2164 |
+
#: includes/admin/reporting/reports.php:980
|
2165 |
+
#: includes/admin/reporting/reports.php:1143
|
2166 |
+
#: includes/admin/reporting/reports.php:1333
|
2167 |
#: includes/admin/settings/register-settings.php:668
|
2168 |
#: includes/admin/settings/register-settings.php:671
|
2169 |
#: includes/admin/settings/register-settings.php:1786
|
2641 |
|
2642 |
#: includes/admin/payments/class-payments-table.php:193
|
2643 |
#: includes/admin/reporting/class-base-logs-list-table.php:477
|
2644 |
+
#: includes/admin/reporting/reports.php:2802
|
2645 |
+
#: includes/admin/reporting/reports.php:2867
|
2646 |
+
#: includes/admin/reporting/reports.php:2920
|
2647 |
+
#: includes/admin/reporting/reports.php:3055
|
2648 |
+
#: includes/admin/reporting/reports.php:3124
|
2649 |
+
#: includes/admin/reporting/reports.php:3178
|
2650 |
#: includes/reports/reports-functions.php:1287
|
2651 |
msgctxt "date filter"
|
2652 |
msgid "From"
|
2654 |
|
2655 |
#: includes/admin/payments/class-payments-table.php:200
|
2656 |
#: includes/admin/reporting/class-base-logs-list-table.php:484
|
2657 |
+
#: includes/admin/reporting/reports.php:2813
|
2658 |
+
#: includes/admin/reporting/reports.php:2878
|
2659 |
+
#: includes/admin/reporting/reports.php:2931
|
2660 |
+
#: includes/admin/reporting/reports.php:3066
|
2661 |
+
#: includes/admin/reporting/reports.php:3135
|
2662 |
+
#: includes/admin/reporting/reports.php:3189
|
2663 |
#: includes/reports/reports-functions.php:1297
|
2664 |
msgctxt "date filter"
|
2665 |
msgid "To"
|
2990 |
msgstr ""
|
2991 |
|
2992 |
#: includes/admin/payments/contextual-help.php:130
|
2993 |
+
#: templates/history-purchases.php:54
|
2994 |
msgid "Details"
|
2995 |
msgstr ""
|
2996 |
|
3494 |
#: includes/admin/reporting/reports.php:232
|
3495 |
#: includes/admin/reporting/reports.php:364
|
3496 |
#: includes/admin/reporting/reports.php:663
|
3497 |
+
#: includes/admin/reporting/reports.php:900
|
3498 |
+
#: includes/admin/reporting/reports.php:1283
|
3499 |
+
#: includes/admin/reporting/reports.php:1443
|
3500 |
+
#: includes/admin/reporting/reports.php:1641
|
3501 |
#: includes/reports/data/downloads/class-top-selling-downloads-list-table.php:57
|
3502 |
#: includes/reports/data/file-downloads/class-top-five-most-downloaded-list-table.php:60
|
3503 |
#: tests/reports/data/charts/v2/tests-dateset.php:209
|
3564 |
#: includes/admin/reporting/export/class-batch-export-customers.php:51
|
3565 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:41
|
3566 |
#: includes/admin/reporting/export/class-batch-export-taxed-customers.php:41
|
3567 |
+
#: templates/history-purchases.php:51
|
3568 |
#: includes/blocks/build/downloads/index.js:1
|
3569 |
#: includes/blocks/build/terms/index.js:1
|
3570 |
msgid "ID"
|
3571 |
msgstr ""
|
3572 |
|
3573 |
#: includes/admin/reporting/class-export-payments.php:57
|
|
|
3574 |
#: includes/admin/tools.php:611
|
3575 |
msgid "Payment Number"
|
3576 |
msgstr ""
|
3652 |
msgstr ""
|
3653 |
|
3654 |
#: includes/admin/reporting/class-export-payments.php:185
|
3655 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:128
|
3656 |
+
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:129
|
3657 |
msgid "none"
|
3658 |
msgstr ""
|
3659 |
|
3660 |
#: includes/admin/reporting/class-export-payments.php:190
|
3661 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:216
|
3662 |
+
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:212
|
3663 |
msgid "guest"
|
3664 |
msgstr ""
|
3665 |
|
3674 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:112
|
3675 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:108
|
3676 |
#: includes/admin/reporting/class-sales-logs-list-table.php:97
|
3677 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:42
|
3678 |
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:42
|
3679 |
msgid "Order Number"
|
3680 |
msgstr ""
|
3722 |
msgstr ""
|
3723 |
|
3724 |
#: includes/admin/reporting/contextual-help.php:67
|
3725 |
+
#: includes/admin/reporting/reports.php:2724
|
3726 |
+
#: includes/admin/reporting/reports.php:2846
|
3727 |
#: includes/admin/tools.php:1012
|
3728 |
msgid "Export"
|
3729 |
msgstr ""
|
3830 |
msgstr ""
|
3831 |
|
3832 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:52
|
3833 |
+
#: templates/history-downloads.php:46
|
3834 |
msgid "Files"
|
3835 |
msgstr ""
|
3836 |
|
3866 |
msgstr ""
|
3867 |
|
3868 |
#: includes/admin/reporting/export/class-batch-export-payments.php:41
|
3869 |
+
#: includes/admin/reporting/export/class-batch-export-taxed-orders.php:41
|
3870 |
+
#: includes/privacy-functions.php:868
|
3871 |
+
msgid "Order ID"
|
3872 |
msgstr ""
|
3873 |
|
3874 |
#: includes/admin/reporting/export/class-batch-export-payments.php:44
|
3900 |
msgid "State Name"
|
3901 |
msgstr ""
|
3902 |
|
3903 |
+
#: includes/admin/reporting/export/class-batch-export-sales.php:48
|
3904 |
+
#: includes/emails/tags.php:221
|
3905 |
+
msgid "Payment ID"
|
3906 |
msgstr ""
|
3907 |
|
3908 |
+
#: includes/admin/reporting/export/class-batch-export-sales.php:49
|
3909 |
+
msgid "Price ID"
|
|
|
3910 |
msgstr ""
|
3911 |
|
3912 |
#: includes/admin/reporting/export/export-functions.php:51
|
3980 |
msgstr ""
|
3981 |
|
3982 |
#: includes/admin/reporting/reports.php:279
|
3983 |
+
#: includes/admin/reporting/reports.php:1360
|
3984 |
msgid "Average Order Value"
|
3985 |
msgstr ""
|
3986 |
|
3987 |
#: includes/admin/reporting/reports.php:303
|
3988 |
+
#: includes/admin/reporting/reports.php:2520
|
3989 |
+
#: includes/admin/reporting/reports.php:2593
|
3990 |
+
#: includes/admin/reporting/reports.php:2678
|
3991 |
#: includes/emails/email-summary/edd-email-summary-template.php:279
|
3992 |
msgid "New Customers"
|
3993 |
msgstr ""
|
3994 |
|
3995 |
#: includes/admin/reporting/reports.php:321
|
3996 |
+
#: includes/admin/reporting/reports.php:1064
|
3997 |
msgid "Total Refund Amount"
|
3998 |
msgstr ""
|
3999 |
|
4000 |
#: includes/admin/reporting/reports.php:344
|
4001 |
#: includes/admin/reporting/reports.php:731
|
4002 |
+
#: includes/admin/reporting/reports.php:1511
|
4003 |
msgid "Sales and Earnings"
|
4004 |
msgstr ""
|
4005 |
|
4035 |
msgid "Earnings by Variation"
|
4036 |
msgstr ""
|
4037 |
|
4038 |
+
#: includes/admin/reporting/reports.php:1005
|
4039 |
msgid "Number of Refunds"
|
4040 |
msgstr ""
|
4041 |
|
4042 |
+
#: includes/admin/reporting/reports.php:1024
|
4043 |
msgid "Number of Fully Refunded Orders"
|
4044 |
msgstr ""
|
4045 |
|
4046 |
+
#: includes/admin/reporting/reports.php:1044
|
4047 |
msgid "Number of Fully Refunded Items"
|
4048 |
msgstr ""
|
4049 |
|
4050 |
+
#: includes/admin/reporting/reports.php:1084
|
4051 |
msgid "Average Refund Amount"
|
4052 |
msgstr ""
|
4053 |
|
4054 |
+
#: includes/admin/reporting/reports.php:1105
|
4055 |
msgid "Average Time to Refund"
|
4056 |
msgstr ""
|
4057 |
|
4058 |
+
#: includes/admin/reporting/reports.php:1123
|
4059 |
msgid "Refund Rate"
|
4060 |
msgstr ""
|
4061 |
|
4062 |
+
#: includes/admin/reporting/reports.php:1271
|
4063 |
msgid "Payment Gateways"
|
4064 |
msgstr ""
|
4065 |
|
4066 |
+
#: includes/admin/reporting/reports.php:1397
|
4067 |
msgid "Gateway Stats"
|
4068 |
msgstr ""
|
4069 |
|
4070 |
+
#: includes/admin/reporting/reports.php:1411
|
4071 |
msgid "Gateway Sales"
|
4072 |
msgstr ""
|
4073 |
|
4074 |
+
#: includes/admin/reporting/reports.php:1460
|
4075 |
msgid "Gateway Earnings"
|
4076 |
msgstr ""
|
4077 |
|
4078 |
+
#: includes/admin/reporting/reports.php:1753
|
4079 |
#: includes/admin/settings/contextual-help.php:99
|
4080 |
#: includes/admin/settings/register-settings.php:917
|
4081 |
#: includes/admin/settings/register-settings.php:1737
|
4082 |
msgid "Taxes"
|
4083 |
msgstr ""
|
4084 |
|
4085 |
+
#: includes/admin/reporting/reports.php:1764
|
4086 |
msgid "Total Tax Collected"
|
4087 |
msgstr ""
|
4088 |
|
4089 |
+
#: includes/admin/reporting/reports.php:1799
|
4090 |
msgid "Total Tax Collected for "
|
4091 |
msgstr ""
|
4092 |
|
4093 |
+
#: includes/admin/reporting/reports.php:1829
|
4094 |
msgid "Tax Collected by Location"
|
4095 |
msgstr ""
|
4096 |
|
4097 |
+
#: includes/admin/reporting/reports.php:1908
|
4098 |
+
#: includes/admin/reporting/reports.php:2111
|
4099 |
#: includes/admin/settings/register-settings.php:1818
|
4100 |
#: includes/admin/tools/logs.php:195
|
4101 |
#: includes/privacy-functions.php:546
|
4103 |
msgid "File Downloads"
|
4104 |
msgstr ""
|
4105 |
|
4106 |
+
#: includes/admin/reporting/reports.php:1920
|
4107 |
+
#: includes/admin/reporting/reports.php:2010
|
4108 |
msgid "Number of File Downloads"
|
4109 |
msgstr ""
|
4110 |
|
4111 |
+
#: includes/admin/reporting/reports.php:1944
|
4112 |
msgid "Average per Customer"
|
4113 |
msgstr ""
|
4114 |
|
4115 |
+
#: includes/admin/reporting/reports.php:1962
|
4116 |
msgid "Average per Order"
|
4117 |
msgstr ""
|
4118 |
|
4119 |
+
#: includes/admin/reporting/reports.php:1980
|
4120 |
msgid "Most Downloaded Product"
|
4121 |
msgstr ""
|
4122 |
|
4123 |
+
#: includes/admin/reporting/reports.php:1998
|
4124 |
msgid "Top Five Most Downloaded Products"
|
4125 |
msgstr ""
|
4126 |
|
4127 |
+
#: includes/admin/reporting/reports.php:2218
|
4128 |
msgid "Number of Discounts Used"
|
4129 |
msgstr ""
|
4130 |
|
4131 |
+
#: includes/admin/reporting/reports.php:2235
|
4132 |
msgid "Discount Ratio"
|
4133 |
msgstr ""
|
4134 |
|
4135 |
+
#: includes/admin/reporting/reports.php:2253
|
4136 |
msgid "Customer Savings"
|
4137 |
msgstr ""
|
4138 |
|
4139 |
+
#: includes/admin/reporting/reports.php:2274
|
4140 |
msgid "Average Discount Amount"
|
4141 |
msgstr ""
|
4142 |
|
4143 |
+
#: includes/admin/reporting/reports.php:2292
|
4144 |
msgid "Most Popular Discount"
|
4145 |
msgstr ""
|
4146 |
|
4147 |
+
#: includes/admin/reporting/reports.php:2317
|
4148 |
msgid "Discount Usage Count"
|
4149 |
msgstr ""
|
4150 |
|
4151 |
+
#: includes/admin/reporting/reports.php:2336
|
4152 |
msgid "Top Five Discounts"
|
4153 |
msgstr ""
|
4154 |
|
4155 |
+
#: includes/admin/reporting/reports.php:2349
|
4156 |
+
#: includes/admin/reporting/reports.php:2444
|
4157 |
msgid "Discount Usage"
|
4158 |
msgstr ""
|
4159 |
|
4160 |
+
#: includes/admin/reporting/reports.php:2538
|
4161 |
msgid "Average Revenue per Customer"
|
4162 |
msgstr ""
|
4163 |
|
4164 |
+
#: includes/admin/reporting/reports.php:2553
|
4165 |
msgid "Average Orders per Customer"
|
4166 |
msgstr ""
|
4167 |
|
4168 |
+
#: includes/admin/reporting/reports.php:2569
|
4169 |
msgid "Top Five Customers — All Time"
|
4170 |
msgstr ""
|
4171 |
|
4172 |
+
#: includes/admin/reporting/reports.php:2581
|
4173 |
msgid "Most Valuable Customers"
|
4174 |
msgstr ""
|
4175 |
|
4176 |
+
#: includes/admin/reporting/reports.php:2754
|
4177 |
msgid "Export Earnings Report"
|
4178 |
msgstr ""
|
4179 |
|
4180 |
+
#: includes/admin/reporting/reports.php:2756
|
4181 |
msgid "Download a CSV giving a detailed look into earnings over time."
|
4182 |
msgstr ""
|
4183 |
|
4184 |
+
#: includes/admin/reporting/reports.php:2760
|
4185 |
msgid "Export Earnings Start"
|
4186 |
msgstr ""
|
4187 |
|
4188 |
+
#: includes/admin/reporting/reports.php:2762
|
4189 |
msgid "Select start month"
|
4190 |
msgstr ""
|
4191 |
|
4192 |
+
#: includes/admin/reporting/reports.php:2764
|
4193 |
msgid "Select start year"
|
4194 |
msgstr ""
|
4195 |
|
4196 |
+
#: includes/admin/reporting/reports.php:2768
|
4197 |
msgctxt "Date one to date two"
|
4198 |
msgid "— to —"
|
4199 |
msgstr ""
|
4200 |
|
4201 |
+
#: includes/admin/reporting/reports.php:2772
|
4202 |
msgid "Export Earnings End"
|
4203 |
msgstr ""
|
4204 |
|
4205 |
+
#: includes/admin/reporting/reports.php:2774
|
4206 |
msgid "Select end month"
|
4207 |
msgstr ""
|
4208 |
|
4209 |
+
#: includes/admin/reporting/reports.php:2776
|
4210 |
msgid "Select end year"
|
4211 |
msgstr ""
|
4212 |
|
4213 |
+
#: includes/admin/reporting/reports.php:2781
|
4214 |
+
#: includes/admin/reporting/reports.php:2899
|
4215 |
+
#: includes/admin/reporting/reports.php:2972
|
4216 |
+
#: includes/admin/reporting/reports.php:3035
|
4217 |
+
#: includes/admin/reporting/reports.php:3076
|
4218 |
+
#: includes/admin/reporting/reports.php:3103
|
4219 |
+
#: includes/admin/reporting/reports.php:3146
|
4220 |
+
#: includes/admin/reporting/reports.php:3200
|
4221 |
msgid "Generate CSV"
|
4222 |
msgstr ""
|
4223 |
|
4224 |
+
#: includes/admin/reporting/reports.php:2787
|
4225 |
msgid "Export Sales and Earnings"
|
4226 |
msgstr ""
|
4227 |
|
4228 |
+
#: includes/admin/reporting/reports.php:2789
|
4229 |
msgid "Download a CSV of all sales or earnings on a day-by-day basis."
|
4230 |
msgstr ""
|
4231 |
|
4232 |
+
#: includes/admin/reporting/reports.php:2793
|
4233 |
msgid "Export Sales and Earnings Dates"
|
4234 |
msgstr ""
|
4235 |
|
4236 |
+
#: includes/admin/reporting/reports.php:2795
|
4237 |
+
#: includes/admin/reporting/reports.php:2860
|
4238 |
+
#: includes/admin/reporting/reports.php:2913
|
4239 |
+
#: includes/admin/reporting/reports.php:3048
|
4240 |
+
#: includes/admin/reporting/reports.php:3117
|
4241 |
+
#: includes/admin/reporting/reports.php:3171
|
4242 |
msgid "Set start date"
|
4243 |
msgstr ""
|
4244 |
|
4245 |
+
#: includes/admin/reporting/reports.php:2806
|
4246 |
+
#: includes/admin/reporting/reports.php:2871
|
4247 |
+
#: includes/admin/reporting/reports.php:2924
|
4248 |
+
#: includes/admin/reporting/reports.php:3059
|
4249 |
+
#: includes/admin/reporting/reports.php:3128
|
4250 |
+
#: includes/admin/reporting/reports.php:3182
|
4251 |
msgid "Set end date"
|
4252 |
msgstr ""
|
4253 |
|
4254 |
+
#: includes/admin/reporting/reports.php:2819
|
4255 |
+
#: includes/admin/reporting/reports.php:3020
|
4256 |
+
#: includes/admin/reporting/reports.php:3090
|
4257 |
+
#: includes/admin/reporting/reports.php:3156
|
4258 |
msgid "Select Download"
|
4259 |
msgstr ""
|
4260 |
|
4261 |
+
#: includes/admin/reporting/reports.php:2831
|
4262 |
msgid "Select Customer"
|
4263 |
msgstr ""
|
4264 |
|
4265 |
+
#: includes/admin/reporting/reports.php:2839
|
4266 |
msgid "All Customers"
|
4267 |
msgstr ""
|
4268 |
|
4269 |
+
#: includes/admin/reporting/reports.php:2852
|
4270 |
msgid "Export Orders"
|
4271 |
msgstr ""
|
4272 |
|
4273 |
+
#: includes/admin/reporting/reports.php:2854
|
4274 |
msgid "Download a CSV of all orders."
|
4275 |
msgstr ""
|
4276 |
|
4277 |
+
#: includes/admin/reporting/reports.php:2858
|
4278 |
msgid "Export Order Dates"
|
4279 |
msgstr ""
|
4280 |
|
4281 |
+
#: includes/admin/reporting/reports.php:2883
|
4282 |
+
#: includes/admin/reporting/reports.php:2936
|
4283 |
msgid "Select Status"
|
4284 |
msgstr ""
|
4285 |
|
4286 |
+
#: includes/admin/reporting/reports.php:2889
|
4287 |
+
#: includes/admin/reporting/reports.php:2942
|
4288 |
msgid "All Statuses"
|
4289 |
msgstr ""
|
4290 |
|
4291 |
+
#: includes/admin/reporting/reports.php:2905
|
4292 |
msgid "Export Taxed Orders"
|
4293 |
msgstr ""
|
4294 |
|
4295 |
+
#: includes/admin/reporting/reports.php:2907
|
4296 |
msgid "Download a CSV of all orders, taxed by Country and/or Region."
|
4297 |
msgstr ""
|
4298 |
|
4299 |
+
#: includes/admin/reporting/reports.php:2911
|
4300 |
msgid "Export Taxed Order Dates"
|
4301 |
msgstr ""
|
4302 |
|
4303 |
+
#: includes/admin/reporting/reports.php:2949
|
4304 |
msgid "Select Country"
|
4305 |
msgstr ""
|
4306 |
|
4307 |
+
#: includes/admin/reporting/reports.php:2960
|
4308 |
msgid "Select Region"
|
4309 |
msgstr ""
|
4310 |
|
4311 |
+
#: includes/admin/reporting/reports.php:2965
|
4312 |
#: includes/class-edd-html-elements.php:656
|
4313 |
msgid "All Regions"
|
4314 |
msgstr ""
|
4315 |
|
4316 |
+
#: includes/admin/reporting/reports.php:2978
|
4317 |
msgid "Export Customers"
|
4318 |
msgstr ""
|
4319 |
|
4320 |
+
#: includes/admin/reporting/reports.php:2980
|
4321 |
msgid "Download a CSV of customers. Select a taxonomy to see all the customers who purchased %s in that taxonomy."
|
4322 |
msgstr ""
|
4323 |
|
4324 |
+
#: includes/admin/reporting/reports.php:3007
|
4325 |
#: includes/blocks/build/terms/index.js:1
|
4326 |
msgid "Select Taxonomy"
|
4327 |
msgstr ""
|
4328 |
|
4329 |
+
#: includes/admin/reporting/reports.php:3016
|
4330 |
msgid "All Taxonomies"
|
4331 |
msgstr ""
|
4332 |
|
4333 |
+
#: includes/admin/reporting/reports.php:3041
|
4334 |
msgid "Export Taxed Customers"
|
4335 |
msgstr ""
|
4336 |
|
4337 |
+
#: includes/admin/reporting/reports.php:3043
|
4338 |
msgid "Download a CSV of all customers that were taxed."
|
4339 |
msgstr ""
|
4340 |
|
4341 |
+
#: includes/admin/reporting/reports.php:3047
|
4342 |
msgid "Export Taxed Customer Dates"
|
4343 |
msgstr ""
|
4344 |
|
4345 |
#. translators: the singular post type label
|
4346 |
+
#: includes/admin/reporting/reports.php:3084
|
4347 |
msgid "Export %s Products"
|
4348 |
msgstr ""
|
4349 |
|
4350 |
#. translators: the plural post type label
|
4351 |
+
#: includes/admin/reporting/reports.php:3088
|
4352 |
msgid "Download a CSV of product %1$s."
|
4353 |
msgstr ""
|
4354 |
|
4355 |
+
#: includes/admin/reporting/reports.php:3109
|
4356 |
msgid "Export API Request Logs"
|
4357 |
msgstr ""
|
4358 |
|
4359 |
+
#: includes/admin/reporting/reports.php:3111
|
4360 |
msgid "Download a CSV of API request logs."
|
4361 |
msgstr ""
|
4362 |
|
4363 |
+
#: includes/admin/reporting/reports.php:3115
|
4364 |
msgid "Export API Request Log Dates"
|
4365 |
msgstr ""
|
4366 |
|
4367 |
+
#: includes/admin/reporting/reports.php:3152
|
4368 |
msgid "Export File Download Logs"
|
4369 |
msgstr ""
|
4370 |
|
4371 |
+
#: includes/admin/reporting/reports.php:3154
|
4372 |
msgid "Download a CSV of file download logs."
|
4373 |
msgstr ""
|
4374 |
|
4375 |
+
#: includes/admin/reporting/reports.php:3169
|
4376 |
msgid "Export File Download Log Dates"
|
4377 |
msgstr ""
|
4378 |
|
4379 |
+
#: includes/admin/reporting/reports.php:3274
|
4380 |
#: includes/user-functions.php:922
|
4381 |
#: includes/user-functions.php:926
|
4382 |
msgid "Notice"
|
4383 |
msgstr ""
|
4384 |
|
4385 |
+
#: includes/admin/reporting/reports.php:3275
|
4386 |
msgid "Tax reports are only generated for taxes associated with a location. The legacy default tax rate is unable to be reported on."
|
4387 |
msgstr ""
|
4388 |
|
6660 |
msgstr ""
|
6661 |
|
6662 |
#: includes/admin/views/tmpl-order-adjustment-discount.php:27
|
6663 |
+
#: includes/discount-functions.php:1350
|
6664 |
msgid "Remove discount"
|
6665 |
msgstr ""
|
6666 |
|
6670 |
#: includes/blocks/views/checkout/discount.php:16
|
6671 |
#: includes/blocks/views/orders/discounts.php:7
|
6672 |
#: includes/checkout/template.php:741
|
6673 |
+
#: includes/discount-functions.php:1314
|
6674 |
#: templates/shortcode-receipt.php:87
|
6675 |
msgid "Discount"
|
6676 |
msgid_plural "Discounts"
|
6996 |
|
6997 |
#: includes/blocks/edd-blocks.php:86
|
6998 |
#: includes/emails/tags.php:245
|
6999 |
+
#: includes/emails/template.php:262
|
7000 |
msgid "Receipt"
|
7001 |
msgstr ""
|
7002 |
|
7113 |
msgid "Your cart is empty."
|
7114 |
msgstr ""
|
7115 |
|
7116 |
+
#: includes/blocks/includes/checkout/forms.php:31
|
7117 |
#: includes/blocks/views/checkout/purchase-form/login.php:26
|
7118 |
#: includes/checkout/template.php:497
|
7119 |
#: includes/checkout/template.php:602
|
7120 |
msgid "Log in"
|
7121 |
msgstr ""
|
7122 |
|
7123 |
+
#: includes/blocks/includes/checkout/forms.php:35
|
7124 |
msgid "Register for a new account"
|
7125 |
msgstr ""
|
7126 |
|
7127 |
+
#: includes/blocks/includes/checkout/forms.php:39
|
7128 |
msgid "Check out as a guest"
|
7129 |
msgstr ""
|
7130 |
|
7161 |
msgstr ""
|
7162 |
|
7163 |
#: includes/blocks/includes/orders/functions.php:30
|
7164 |
+
#: templates/history-purchases.php:74
|
7165 |
msgid "Complete Purchase"
|
7166 |
msgstr ""
|
7167 |
|
7168 |
#: includes/blocks/includes/orders/functions.php:38
|
7169 |
#: includes/blocks/includes/orders/orders.php:158
|
7170 |
+
#: templates/history-purchases.php:79
|
7171 |
msgid "View Details and Downloads"
|
7172 |
msgstr ""
|
7173 |
|
7402 |
msgid "Personal Info"
|
7403 |
msgstr ""
|
7404 |
|
7405 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:12
|
7406 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:16
|
7407 |
#: includes/checkout/template.php:183
|
7408 |
#: includes/checkout/template.php:189
|
7409 |
msgid "Email address"
|
7410 |
msgstr ""
|
7411 |
|
7412 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:17
|
7413 |
#: includes/checkout/template.php:188
|
7414 |
msgid "We will send the purchase receipt to this address."
|
7415 |
msgstr ""
|
7416 |
|
7417 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:24
|
7418 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:30
|
7419 |
#: includes/checkout/template.php:194
|
7420 |
#: includes/checkout/template.php:200
|
7421 |
msgid "First name"
|
7422 |
msgstr ""
|
7423 |
|
7424 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:31
|
7425 |
#: includes/checkout/template.php:199
|
7426 |
msgid "We will use this to personalize your account experience."
|
7427 |
msgstr ""
|
7428 |
|
7429 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:38
|
7430 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:44
|
7431 |
#: includes/checkout/template.php:204
|
7432 |
#: includes/checkout/template.php:210
|
7433 |
msgid "Last name"
|
7434 |
msgstr ""
|
7435 |
|
7436 |
+
#: includes/blocks/views/checkout/purchase-form/personal-info.php:45
|
7437 |
#: includes/checkout/template.php:209
|
7438 |
msgid "We will use this as well to personalize your account experience."
|
7439 |
msgstr ""
|
7468 |
msgstr ""
|
7469 |
|
7470 |
#: includes/blocks/views/forms/login.php:44
|
7471 |
+
#: includes/payments/actions.php:412
|
7472 |
#: templates/shortcode-login.php:33
|
7473 |
#: includes/blocks/build/login/index.js:1
|
7474 |
msgid "Lost Password?"
|
7520 |
|
7521 |
#: includes/blocks/views/orders/receipt-files.php:70
|
7522 |
#: includes/emails/tags.php:378
|
7523 |
+
#: templates/history-downloads.php:89
|
7524 |
#: templates/shortcode-receipt.php:306
|
7525 |
msgid "No downloadable files found."
|
7526 |
msgstr ""
|
7902 |
#. translators: the order item's status.
|
7903 |
#: includes/class-edd-cli.php:185
|
7904 |
#: includes/class-edd-cli.php:444
|
7905 |
+
#: templates/history-downloads.php:97
|
7906 |
msgid "Status: %s"
|
7907 |
msgstr ""
|
7908 |
|
8103 |
msgstr ""
|
8104 |
|
8105 |
#: includes/class-edd-cli.php:486
|
8106 |
+
#: includes/class-edd-cli.php:2014
|
8107 |
msgid "No action specified, did you mean"
|
8108 |
msgstr ""
|
8109 |
|
8110 |
#: includes/class-edd-cli.php:488
|
8111 |
+
#: includes/class-edd-cli.php:2016
|
8112 |
msgid "Invalid action specified, did you mean"
|
8113 |
msgstr ""
|
8114 |
|
8129 |
msgstr ""
|
8130 |
|
8131 |
#: includes/class-edd-cli.php:899
|
8132 |
+
msgid "This process will remove and recreate discounts in your database. Please make sure you've backed up your EDD database tables. Are you sure you want to delete discounts that have already been migrated and run the migration again?"
|
8133 |
+
msgstr ""
|
8134 |
+
|
8135 |
+
#: includes/class-edd-cli.php:905
|
8136 |
msgid "The discounts custom database migration has already been run. To do this anyway, use the --force argument."
|
8137 |
msgstr ""
|
8138 |
|
8139 |
+
#: includes/class-edd-cli.php:927
|
8140 |
msgid "Migration complete: Discounts"
|
8141 |
msgstr ""
|
8142 |
|
8143 |
+
#: includes/class-edd-cli.php:930
|
8144 |
+
#: includes/class-edd-cli.php:1053
|
8145 |
+
#: includes/class-edd-cli.php:1530
|
8146 |
+
#: includes/class-edd-cli.php:1764
|
8147 |
msgid "Old Records: "
|
8148 |
msgstr ""
|
8149 |
|
8150 |
+
#: includes/class-edd-cli.php:931
|
8151 |
+
#: includes/class-edd-cli.php:1054
|
8152 |
+
#: includes/class-edd-cli.php:1531
|
8153 |
+
#: includes/class-edd-cli.php:1765
|
8154 |
msgid "New Records: "
|
8155 |
msgstr ""
|
8156 |
|
8157 |
+
#: includes/class-edd-cli.php:938
|
8158 |
msgid "No discount records found."
|
8159 |
msgstr ""
|
8160 |
|
8161 |
+
#: includes/class-edd-cli.php:970
|
8162 |
msgid "The logs custom table migration has already been run. To do this anyway, use the --force argument."
|
8163 |
msgstr ""
|
8164 |
|
8165 |
+
#: includes/class-edd-cli.php:973
|
8166 |
msgid "Preparing to migrate logs (this can take several minutes)."
|
8167 |
msgstr ""
|
8168 |
|
8169 |
+
#: includes/class-edd-cli.php:976
|
8170 |
msgid "Migrating Logs"
|
8171 |
msgstr ""
|
8172 |
|
8173 |
+
#: includes/class-edd-cli.php:1048
|
8174 |
msgid "No log records found."
|
8175 |
msgstr ""
|
8176 |
|
8177 |
+
#: includes/class-edd-cli.php:1051
|
8178 |
msgid "Migration complete: Logs"
|
8179 |
msgstr ""
|
8180 |
|
8181 |
+
#: includes/class-edd-cli.php:1088
|
8182 |
msgid "The order notes custom table migration has already been run. To do this anyway, use the --force argument."
|
8183 |
msgstr ""
|
8184 |
|
8185 |
+
#: includes/class-edd-cli.php:1091
|
8186 |
msgid "Preparing to migrate order notes."
|
8187 |
msgstr ""
|
8188 |
|
8189 |
+
#: includes/class-edd-cli.php:1093
|
8190 |
msgid "Migrating Order Notes"
|
8191 |
msgstr ""
|
8192 |
|
8193 |
+
#: includes/class-edd-cli.php:1157
|
8194 |
msgid "No order notes found."
|
8195 |
msgstr ""
|
8196 |
|
8197 |
+
#: includes/class-edd-cli.php:1159
|
8198 |
msgid "Migration complete: Order Notes"
|
8199 |
msgstr ""
|
8200 |
|
8201 |
+
#: includes/class-edd-cli.php:1161
|
8202 |
msgid "Old order notes: "
|
8203 |
msgstr ""
|
8204 |
|
8205 |
+
#: includes/class-edd-cli.php:1162
|
8206 |
msgid "New order notes: "
|
8207 |
msgstr ""
|
8208 |
|
8209 |
+
#: includes/class-edd-cli.php:1195
|
8210 |
msgid "The customer notes custom table migration has already been run. To do this anyway, use the --force argument."
|
8211 |
msgstr ""
|
8212 |
|
8213 |
+
#: includes/class-edd-cli.php:1197
|
8214 |
msgid "Preparing to migrate customer notes."
|
8215 |
msgstr ""
|
8216 |
|
8217 |
+
#: includes/class-edd-cli.php:1199
|
8218 |
msgid "Migrating Customer Notes"
|
8219 |
msgstr ""
|
8220 |
|
8221 |
+
#: includes/class-edd-cli.php:1259
|
8222 |
msgid "No customer notes found."
|
8223 |
msgstr ""
|
8224 |
|
8225 |
+
#: includes/class-edd-cli.php:1261
|
8226 |
msgid "Migration complete: Customer Notes"
|
8227 |
msgstr ""
|
8228 |
|
8229 |
+
#: includes/class-edd-cli.php:1263
|
8230 |
msgid "Old customer notes: "
|
8231 |
msgstr ""
|
8232 |
|
8233 |
+
#: includes/class-edd-cli.php:1264
|
8234 |
msgid "New customer notes: "
|
8235 |
msgstr ""
|
8236 |
|
8237 |
+
#: includes/class-edd-cli.php:1301
|
8238 |
msgid "Preparing to migrate additional customer data."
|
8239 |
msgstr ""
|
8240 |
|
8241 |
+
#: includes/class-edd-cli.php:1326
|
8242 |
msgid "The user addresses custom table migration has already been run. To do this anyway, use the --force argument."
|
8243 |
msgstr ""
|
8244 |
|
8245 |
+
#: includes/class-edd-cli.php:1328
|
8246 |
msgid "Preparing to migrate customer address data."
|
8247 |
msgstr ""
|
8248 |
|
8249 |
+
#: includes/class-edd-cli.php:1329
|
8250 |
msgid "Migrating Customer Addresses"
|
8251 |
msgstr ""
|
8252 |
|
8253 |
+
#: includes/class-edd-cli.php:1400
|
8254 |
msgid "The user email addresses custom table migration has already been run. To do this anyway, use the --force argument."
|
8255 |
msgstr ""
|
8256 |
|
8257 |
+
#: includes/class-edd-cli.php:1402
|
8258 |
msgid "Preparing to migrate customer email addresses (this can take several minutes)."
|
8259 |
msgstr ""
|
8260 |
|
8261 |
+
#: includes/class-edd-cli.php:1403
|
8262 |
msgid "Migrating Customer Email Addresses"
|
8263 |
msgstr ""
|
8264 |
|
8265 |
+
#: includes/class-edd-cli.php:1466
|
8266 |
msgid "Migration complete: Customer Email Addresses"
|
8267 |
msgstr ""
|
8268 |
|
8269 |
+
#: includes/class-edd-cli.php:1498
|
8270 |
msgid "The tax rates custom table migration has already been run. To do this anyway, use the --force argument."
|
8271 |
msgstr ""
|
8272 |
|
8273 |
+
#: includes/class-edd-cli.php:1501
|
8274 |
msgid "Checking for default tax rate"
|
8275 |
msgstr ""
|
8276 |
|
8277 |
+
#: includes/class-edd-cli.php:1504
|
8278 |
msgid "Migrating default tax rate"
|
8279 |
msgstr ""
|
8280 |
|
8281 |
+
#: includes/class-edd-cli.php:1528
|
8282 |
msgid "Migration complete: Tax Rates"
|
8283 |
msgstr ""
|
8284 |
|
8285 |
+
#: includes/class-edd-cli.php:1571
|
8286 |
msgid "This process will remove and recreate orders in your database. Please make sure you've backed up your EDD database tables. Are you sure you want to delete orders that have already been migrated and run the migration again?"
|
8287 |
msgstr ""
|
8288 |
|
8289 |
+
#: includes/class-edd-cli.php:1577
|
8290 |
msgid "The payments custom table migration has already been run. To do this anyway, use the --force argument."
|
8291 |
msgstr ""
|
8292 |
|
8293 |
+
#: includes/class-edd-cli.php:1580
|
8294 |
msgid "Preparing to migrate payments."
|
8295 |
msgstr ""
|
8296 |
|
8297 |
+
#: includes/class-edd-cli.php:1583
|
8298 |
msgid "Migrating Payments"
|
8299 |
msgstr ""
|
8300 |
|
8301 |
+
#: includes/class-edd-cli.php:1610
|
8302 |
msgid "An EDD Payment could not be found for that ID."
|
8303 |
msgstr ""
|
8304 |
|
8305 |
+
#: includes/class-edd-cli.php:1613
|
8306 |
msgid "The payment ID must be an integer from the post_id column."
|
8307 |
msgstr ""
|
8308 |
|
8309 |
+
#: includes/class-edd-cli.php:1624
|
8310 |
msgid "The starting ID must be an integer from the post_id column."
|
8311 |
msgstr ""
|
8312 |
|
8313 |
+
#: includes/class-edd-cli.php:1634
|
8314 |
msgid "The ending ID must be an integer from the post_id column."
|
8315 |
msgstr ""
|
8316 |
|
8317 |
+
#: includes/class-edd-cli.php:1641
|
8318 |
msgid "Are you sure you want to run a partial order migration?"
|
8319 |
msgstr ""
|
8320 |
|
8321 |
#. translators: 1. the refund order ID; 2. the original payment ID.
|
8322 |
+
#: includes/class-edd-cli.php:1683
|
8323 |
msgid "%1$d is a refund order. EDD will delete the refund and migrate payment %1$d, then re-migrate payment %2$d."
|
8324 |
msgstr ""
|
8325 |
|
8326 |
#. translators: 1. the order/payment ID.
|
8327 |
+
#: includes/class-edd-cli.php:1693
|
8328 |
msgid "Order ID %1$d appears to be a different record from Payment ID %1$d. Are you sure you want to destroy this order and overwrite it?"
|
8329 |
msgstr ""
|
8330 |
|
8331 |
#. translators: payment ID.
|
8332 |
+
#: includes/class-edd-cli.php:1728
|
8333 |
msgid "Migration failed for payment %d."
|
8334 |
msgstr ""
|
8335 |
|
8336 |
+
#: includes/class-edd-cli.php:1751
|
8337 |
msgid "No payment records found."
|
8338 |
msgstr ""
|
8339 |
|
8340 |
+
#: includes/class-edd-cli.php:1758
|
8341 |
msgid "Partial order migration complete. Orders Processed: "
|
8342 |
msgstr ""
|
8343 |
|
8344 |
+
#: includes/class-edd-cli.php:1759
|
8345 |
msgid "To recalculate all download sales and earnings, run wp edd `recalculate_download_sales_earnings`."
|
8346 |
msgstr ""
|
8347 |
|
8348 |
+
#: includes/class-edd-cli.php:1761
|
8349 |
msgid "Migration complete: Orders"
|
8350 |
msgstr ""
|
8351 |
|
8352 |
+
#: includes/class-edd-cli.php:1768
|
8353 |
msgid "Refund Records Created: "
|
8354 |
msgstr ""
|
8355 |
|
8356 |
+
#: includes/class-edd-cli.php:1790
|
8357 |
msgid "You must enter a payment ID to display legacy data."
|
8358 |
msgstr ""
|
8359 |
|
8360 |
+
#: includes/class-edd-cli.php:1805
|
8361 |
msgid "The legacy payment data could not be found."
|
8362 |
msgstr ""
|
8363 |
|
8364 |
+
#: includes/class-edd-cli.php:1848
|
8365 |
msgid "Sales and Earnings successfully recalculated for all downloads."
|
8366 |
msgstr ""
|
8367 |
|
8368 |
+
#: includes/class-edd-cli.php:1849
|
8369 |
msgid "Downloads Updated: "
|
8370 |
msgstr ""
|
8371 |
|
8372 |
+
#: includes/class-edd-cli.php:1867
|
8373 |
msgid "Do you want to remove legacy data? This will permanently remove legacy discounts, logs, and order notes."
|
8374 |
msgstr ""
|
8375 |
|
8376 |
+
#: includes/class-edd-cli.php:1875
|
8377 |
msgid "Legacy discounts have already been removed. To run this anyway, use the --force argument."
|
8378 |
msgstr ""
|
8379 |
|
8380 |
+
#: includes/class-edd-cli.php:1877
|
8381 |
msgid "Removing old discount data."
|
8382 |
msgstr ""
|
8383 |
|
8384 |
+
#: includes/class-edd-cli.php:1898
|
8385 |
msgid "Legacy logs have already been removed. To run this anyway, use the --force argument."
|
8386 |
msgstr ""
|
8387 |
|
8388 |
+
#: includes/class-edd-cli.php:1900
|
8389 |
msgid "Removing old logs."
|
8390 |
msgstr ""
|
8391 |
|
8392 |
+
#: includes/class-edd-cli.php:1921
|
8393 |
msgid "Legacy order notes have already been removed. To run this anyway, use the --force argument."
|
8394 |
msgstr ""
|
8395 |
|
8396 |
+
#: includes/class-edd-cli.php:1923
|
8397 |
msgid "Removing old order notes."
|
8398 |
msgstr ""
|
8399 |
|
8400 |
+
#: includes/class-edd-cli.php:1947
|
8401 |
msgid "Updating customers database table."
|
8402 |
msgstr ""
|
8403 |
|
8404 |
+
#: includes/class-edd-cli.php:1956
|
8405 |
msgid "Legacy customer emails have already been removed. To run this anyway, use the --force argument."
|
8406 |
msgstr ""
|
8407 |
|
8408 |
+
#: includes/class-edd-cli.php:1958
|
8409 |
msgid "Removing old customer emails."
|
8410 |
msgstr ""
|
8411 |
|
8412 |
+
#: includes/class-edd-cli.php:1969
|
8413 |
msgid "Legacy customer addresses have already been removed. To run this anyway, use the --force argument."
|
8414 |
msgstr ""
|
8415 |
|
8416 |
+
#: includes/class-edd-cli.php:1971
|
8417 |
msgid "Removing old customer addresses."
|
8418 |
msgstr ""
|
8419 |
|
8420 |
+
#: includes/class-edd-cli.php:1982
|
8421 |
msgid "Legacy orders have already been removed. To run this anyway, use the --force argument."
|
8422 |
msgstr ""
|
8423 |
|
8424 |
+
#: includes/class-edd-cli.php:1984
|
8425 |
msgid "Removing old orders."
|
8426 |
msgstr ""
|
8427 |
|
9305 |
msgstr ""
|
9306 |
|
9307 |
#: includes/deprecated-functions.php:488
|
9308 |
+
#: includes/process-download.php:924
|
9309 |
msgid "Sorry but you have hit your download limit for this file."
|
9310 |
msgstr ""
|
9311 |
|
9709 |
msgid "Preview Purchase Receipt"
|
9710 |
msgstr ""
|
9711 |
|
9712 |
+
#: includes/emails/template.php:241
|
9713 |
msgid "Missing purchase key."
|
9714 |
msgstr ""
|
9715 |
|
9821 |
msgid "Invalid Amazon seller ID"
|
9822 |
msgstr ""
|
9823 |
|
9824 |
+
#. Translators: %s - IPN Verification response
|
9825 |
#: includes/gateways/amazon-payments.php:1024
|
9826 |
#: includes/gateways/amazon-payments.php:1064
|
9827 |
#: includes/gateways/paypal-standard.php:492
|
9830 |
#: includes/gateways/paypal-standard.php:602
|
9831 |
#: includes/gateways/paypal-standard.php:675
|
9832 |
#: includes/gateways/paypal-standard.php:684
|
9833 |
+
#: includes/gateways/paypal/ipn.php:120
|
9834 |
+
#: includes/gateways/paypal/ipn.php:128
|
9835 |
msgid "IPN Error"
|
9836 |
msgstr ""
|
9837 |
|
10119 |
msgstr ""
|
10120 |
|
10121 |
#: includes/gateways/paypal/admin/connect.php:32
|
10122 |
+
#: includes/gateways/paypal/admin/connect.php:357
|
10123 |
msgid "sandbox"
|
10124 |
msgstr ""
|
10125 |
|
10126 |
#: includes/gateways/paypal/admin/connect.php:32
|
10127 |
+
#: includes/gateways/paypal/admin/connect.php:357
|
10128 |
msgid "live"
|
10129 |
msgstr ""
|
10130 |
|
10131 |
#. Translators: %1$s opening <strong> tag; %2$s closing </strong> tag
|
10132 |
+
#: includes/gateways/paypal/admin/connect.php:51
|
10133 |
msgid "%1$sConnection failure:%2$s Please ensure browser popups are enabled then click the button below to connect again. If you continue to experience this error, please contact support."
|
10134 |
msgstr ""
|
10135 |
|
10136 |
#. Translators: %s - the store mode, either `sandbox` or `live`
|
10137 |
+
#: includes/gateways/paypal/admin/connect.php:64
|
10138 |
msgid "Connect with PayPal in %s mode"
|
10139 |
msgstr ""
|
10140 |
|
10141 |
+
#: includes/gateways/paypal/admin/connect.php:68
|
10142 |
msgid "Sign up for PayPal"
|
10143 |
msgstr ""
|
10144 |
|
10145 |
+
#: includes/gateways/paypal/admin/connect.php:79
|
10146 |
#: includes/gateways/stripe/includes/admin/settings/stripe-connect.php:342
|
10147 |
msgid "Retrieving account information..."
|
10148 |
msgstr ""
|
10149 |
|
|
|
|
|
|
|
|
|
10150 |
#. Translators: %d - HTTP response code; %s - Response from the API
|
10151 |
+
#: includes/gateways/paypal/admin/connect.php:130
|
10152 |
msgid "Unexpected response code: %d. Error: %s"
|
10153 |
msgstr ""
|
10154 |
|
10155 |
+
#: includes/gateways/paypal/admin/connect.php:137
|
10156 |
msgid "An unexpected error occurred."
|
10157 |
msgstr ""
|
10158 |
|
10159 |
+
#: includes/gateways/paypal/admin/connect.php:178
|
10160 |
+
msgid "Failure reconnecting to PayPal. Please try again"
|
10161 |
+
msgstr ""
|
10162 |
+
|
10163 |
+
#: includes/gateways/paypal/admin/connect.php:184
|
10164 |
+
msgid "Your account has been successfully reconnected, but an error occurred while creating a webhook."
|
10165 |
+
msgstr ""
|
10166 |
+
|
10167 |
+
#: includes/gateways/paypal/admin/connect.php:222
|
10168 |
msgid "Missing PayPal authentication information. Please try again."
|
10169 |
msgstr ""
|
10170 |
|
10171 |
+
#: includes/gateways/paypal/admin/connect.php:229
|
10172 |
msgid "Missing nonce. Please refresh the page and try again."
|
10173 |
msgstr ""
|
10174 |
|
10175 |
#. Translators: %d - HTTP response code
|
10176 |
+
#: includes/gateways/paypal/admin/connect.php:261
|
10177 |
msgid "Unexpected response from PayPal while generating token. Response code: %d. Please try again."
|
10178 |
msgstr ""
|
10179 |
|
10180 |
#. Translators: %d - HTTP response code
|
10181 |
+
#: includes/gateways/paypal/admin/connect.php:288
|
10182 |
msgid "Unexpected response from PayPal. Response code: %d. Please try again."
|
10183 |
msgstr ""
|
10184 |
|
10185 |
+
#: includes/gateways/paypal/admin/connect.php:296
|
10186 |
msgid "Successfully connected."
|
10187 |
msgstr ""
|
10188 |
|
10189 |
+
#: includes/gateways/paypal/admin/connect.php:301
|
10190 |
msgid "Your account has been successfully connected, but an error occurred while creating a webhook."
|
10191 |
msgstr ""
|
10192 |
|
10193 |
+
#: includes/gateways/paypal/admin/connect.php:335
|
10194 |
msgid "Re-Check Payment Status"
|
10195 |
msgstr ""
|
10196 |
|
10197 |
+
#: includes/gateways/paypal/admin/connect.php:336
|
10198 |
msgid "Sync Webhook"
|
10199 |
msgstr ""
|
10200 |
|
10201 |
+
#: includes/gateways/paypal/admin/connect.php:340
|
10202 |
+
msgid "Disconnect webhooks from PayPal"
|
10203 |
+
msgstr ""
|
10204 |
+
|
10205 |
+
#: includes/gateways/paypal/admin/connect.php:341
|
10206 |
+
msgid "Delete connection with PayPal"
|
10207 |
+
msgstr ""
|
10208 |
+
|
10209 |
+
#: includes/gateways/paypal/admin/connect.php:350
|
10210 |
msgid "API:"
|
10211 |
msgstr ""
|
10212 |
|
10213 |
#. Translators: %s - the connected mode, either `sandbox` or `live`
|
10214 |
+
#: includes/gateways/paypal/admin/connect.php:360
|
10215 |
msgid "Your PayPal account is successfully connected in %s mode."
|
10216 |
msgstr ""
|
10217 |
|
10218 |
+
#: includes/gateways/paypal/admin/connect.php:375
|
10219 |
msgid "Payment Status:"
|
10220 |
msgstr ""
|
10221 |
|
10222 |
+
#: includes/gateways/paypal/admin/connect.php:379
|
10223 |
msgid "You need to address the following issues before you can start receiving payments:"
|
10224 |
msgstr ""
|
10225 |
|
10226 |
+
#: includes/gateways/paypal/admin/connect.php:387
|
10227 |
msgid "Ready to accept payments."
|
10228 |
msgstr ""
|
10229 |
|
10230 |
+
#: includes/gateways/paypal/admin/connect.php:409
|
10231 |
msgid "Webhook:"
|
10232 |
msgstr ""
|
10233 |
|
10234 |
+
#: includes/gateways/paypal/admin/connect.php:417
|
10235 |
+
msgid "Create Webhooks"
|
10236 |
msgstr ""
|
10237 |
|
10238 |
+
#: includes/gateways/paypal/admin/connect.php:422
|
10239 |
msgid "Webhook successfully configured for the following events:"
|
10240 |
msgstr ""
|
10241 |
|
10242 |
#. Translators: %1$s opening anchor tag; %2$s closing anchor tag; %3$s: opening line item/status/strong tags; %4$s closing strong tag; %5$s: closing list item tag
|
10243 |
+
#: includes/gateways/paypal/admin/connect.php:447
|
10244 |
msgid "%3$sGateway Status: %4$s PayPal is not currently active. %1$sEnable PayPal%2$s in the general gateway settings to start using it.%5$s"
|
10245 |
msgstr ""
|
10246 |
|
10247 |
+
#: includes/gateways/paypal/admin/connect.php:625
|
10248 |
msgid "No merchant ID saved. Please reconnect to PayPal."
|
10249 |
msgstr ""
|
10250 |
|
10447 |
msgid "Response Code: %d; Message: %s"
|
10448 |
msgstr ""
|
10449 |
|
10450 |
+
#. Translators: %s - IPN Verification response
|
10451 |
+
#: includes/gateways/paypal/ipn.php:120
|
10452 |
+
#: includes/gateways/paypal/ipn.php:128
|
10453 |
+
msgid "Invalid PayPal Commerce/Express IPN verification response. IPN data: %s"
|
10454 |
+
msgstr ""
|
10455 |
+
|
10456 |
+
#. Translators: %s - The payment data sent via the IPN
|
10457 |
+
#: includes/gateways/paypal/ipn.php:214
|
10458 |
+
msgid "Invalid Currency Code"
|
10459 |
+
msgstr ""
|
10460 |
+
|
10461 |
+
#. Translators: %s - The payment data sent via the IPN
|
10462 |
+
#: includes/gateways/paypal/ipn.php:214
|
10463 |
+
msgid "The currency code in an IPN request did not match the site currency code. Payment data: %s"
|
10464 |
+
msgstr ""
|
10465 |
+
|
10466 |
+
#. Translators: %s - The transaction ID of the failed payment
|
10467 |
+
#: includes/gateways/paypal/ipn.php:230
|
10468 |
+
msgid "Transaction ID %s failed in PayPal"
|
10469 |
+
msgstr ""
|
10470 |
+
|
10471 |
+
#. Translators: %s - The collected outstanding balance of the subscription
|
10472 |
+
#: includes/gateways/paypal/ipn.php:255
|
10473 |
+
msgid "Outstanding subscription balance of %s collected successfully."
|
10474 |
+
msgstr ""
|
10475 |
+
|
10476 |
+
#: includes/gateways/paypal/ipn.php:357
|
10477 |
+
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:53
|
10478 |
+
msgid "Amount: %1$s; Payment transaction ID: %2$s; Refund transaction ID: %3$s"
|
10479 |
+
msgstr ""
|
10480 |
+
|
10481 |
+
#: includes/gateways/paypal/ipn.php:369
|
10482 |
+
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:64
|
10483 |
+
msgid "Partial refund processed in PayPal."
|
10484 |
+
msgstr ""
|
10485 |
+
|
10486 |
+
#: includes/gateways/paypal/ipn.php:379
|
10487 |
+
#: includes/gateways/paypal/webhooks/events/class-payment-capture-refunded.php:72
|
10488 |
+
msgid "Full refund processed in PayPal."
|
10489 |
+
msgstr ""
|
10490 |
+
|
10491 |
#. Translators: %d - ID of the refund; %s - error message from PayPal
|
10492 |
#: includes/gateways/paypal/refunds.php:107
|
10493 |
msgid "Failure when processing PayPal refund #%d: %s"
|
10534 |
msgid "PayPal transaction denied."
|
10535 |
msgstr ""
|
10536 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10537 |
#: includes/gateways/paypal/webhooks/functions.php:86
|
10538 |
msgid "An SSL certificate is required to create a PayPal webhook."
|
10539 |
msgstr ""
|
10556 |
msgid "Invalid response code %d while syncing webhook. Response: %s"
|
10557 |
msgstr ""
|
10558 |
|
|
|
10559 |
#: includes/gateways/paypal/webhooks/functions.php:226
|
10560 |
+
msgid "Your store is currently not receiving webhook notifications, create the webhooks to reconnect."
|
10561 |
+
msgstr ""
|
10562 |
+
|
10563 |
+
#. Translators: %d - HTTP response code.
|
10564 |
+
#: includes/gateways/paypal/webhooks/functions.php:231
|
10565 |
msgid "Invalid response code %d while retrieving webhook details."
|
10566 |
msgstr ""
|
10567 |
|
10568 |
+
#: includes/gateways/paypal/webhooks/functions.php:238
|
10569 |
msgid "Unexpected response from PayPal when retrieving webhook details."
|
10570 |
msgstr ""
|
10571 |
|
10572 |
#. Translators: %d - HTTP response code.
|
10573 |
+
#: includes/gateways/paypal/webhooks/functions.php:274
|
10574 |
msgid "Invalid response code %d while deleting webhook."
|
10575 |
msgstr ""
|
10576 |
|
11600 |
msgid "The maximum refund %s for the adjustment \"%s\" is %s."
|
11601 |
msgstr ""
|
11602 |
|
11603 |
+
#: includes/orders/functions/orders.php:673
|
11604 |
msgid "Payment recovery processed"
|
11605 |
msgstr ""
|
11606 |
|
11644 |
msgid "After payment actions processed."
|
11645 |
msgstr ""
|
11646 |
|
11647 |
+
#: includes/payments/actions.php:327
|
11648 |
+
#: includes/payments/actions.php:388
|
11649 |
msgid "Error resuming payment."
|
11650 |
msgstr ""
|
11651 |
|
11652 |
+
#: includes/payments/actions.php:331
|
11653 |
msgid "Payment recovery triggered URL"
|
11654 |
msgstr ""
|
11655 |
|
11656 |
+
#: includes/payments/actions.php:409
|
11657 |
+
#: includes/payments/actions.php:443
|
11658 |
msgid "To complete this payment, please login to your account."
|
11659 |
msgstr ""
|
11660 |
|
11661 |
+
#: includes/payments/actions.php:411
|
11662 |
msgid "Lost Password"
|
11663 |
msgstr ""
|
11664 |
|
12294 |
msgid "Purchase Verification Failed"
|
12295 |
msgstr ""
|
12296 |
|
12297 |
+
#: includes/process-download.php:1074
|
12298 |
msgid "Invalid file"
|
12299 |
msgstr ""
|
12300 |
|
12301 |
+
#: includes/process-download.php:1081
|
12302 |
msgid "The requested file could not be found. Error 404."
|
12303 |
msgstr ""
|
12304 |
|
12305 |
+
#: includes/process-download.php:1082
|
12306 |
msgid "File not found"
|
12307 |
msgstr ""
|
12308 |
|
13087 |
msgid "Your account has been successfully verified!"
|
13088 |
msgstr ""
|
13089 |
|
13090 |
+
#: templates/history-downloads.php:44
|
13091 |
msgid "Download Name"
|
13092 |
msgstr ""
|
13093 |
|
13094 |
+
#: templates/history-downloads.php:135
|
13095 |
msgid "You have not purchased any downloads"
|
13096 |
msgstr ""
|
13097 |
|
13098 |
+
#: templates/history-purchases.php:102
|
13099 |
msgid "You have not made any purchases."
|
13100 |
msgstr ""
|
13101 |
|
readme.txt
CHANGED
@@ -6,7 +6,7 @@ Tags: ecommerce, e-commerce, sell, digital store, stripe
|
|
6 |
Requires at least: 4.9
|
7 |
Tested up to: 6.1
|
8 |
Requires PHP: 5.6
|
9 |
-
Stable Tag: 3.1.0.
|
10 |
License: GNU Version 2 or Any Later Version
|
11 |
|
12 |
Sell your digital products with the ecommerce plugin written for digital creators, by digital creators. 🚀
|
@@ -254,6 +254,27 @@ Yes, through the use of our commercial addon called [Recurring Payments](https:/
|
|
254 |
|
255 |
== Changelog ==
|
256 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
257 |
= 3.1.0.2, October 27, 2022 =
|
258 |
* New - Blocks: The registration block now supports the WordPress password strength script.
|
259 |
* Improvement: The products API now includes the product permalink.
|
@@ -631,4 +652,4 @@ It is not intended to resolve the issue within PayPal's API, but offer us some t
|
|
631 |
* Dev: The edd_download_price_table_head and edd_download_price_table_row actions have been formally deprecated.
|
632 |
|
633 |
== Upgrade Notice ==
|
634 |
-
IMPORTANT: Easy Digital Downloads 3.0 is a major release that includes many improvements and changes. You will be asked to perform database maintenance once installed. Please ensure you make a backup of your site prior to upgrading. Your site should remain functional during this maintenance, but as with all updates, it is best to make a backup of your site prior to updating.
|
6 |
Requires at least: 4.9
|
7 |
Tested up to: 6.1
|
8 |
Requires PHP: 5.6
|
9 |
+
Stable Tag: 3.1.0.3
|
10 |
License: GNU Version 2 or Any Later Version
|
11 |
|
12 |
Sell your digital products with the ecommerce plugin written for digital creators, by digital creators. 🚀
|
254 |
|
255 |
== Changelog ==
|
256 |
|
257 |
+
= 3.1.0.3, November 23, 2022 =
|
258 |
+
* Improvement: The PayPal webhook connect/disconnect process has been improved to ensure proper webhook delivery.
|
259 |
+
* Improvement: An IPN Backup has been added to the PayPal gateway, to avoid missing webhooks that may have been disconnected.
|
260 |
+
* 📘 Read more on [how to configure the IPN Backup](https://easydigitaldownloads.com/docs/paypal-setup/#ipn).
|
261 |
+
|
262 |
+
* Fix: PayPal Buy Now functionality has been fixed for guest users.
|
263 |
+
* Fix: Exporting orders was including orders with the Trash status.
|
264 |
+
* Fix: Trashed orders were showing in the purchase history shortcode (templates updated: history-downloads.php and history-purchases.php).
|
265 |
+
* Fix: The file downloads graph was formatting integers as currency.
|
266 |
+
* Fix: Searching by download ID on the Orders list table was not working.
|
267 |
+
* Fix: In some timezone settings, the reports could incorrectly display.
|
268 |
+
* Fix: Determining if a product can be purchased was improved for performance.
|
269 |
+
* Fix: Switching gateways when resuming an order was resulting in the wrong gateway value being added to the database.
|
270 |
+
* Fix: The migration process can now identify custom discount meta for migration to the new adjustment meta table.
|
271 |
+
* Fix: Non-Standard (but still supported by WordPress) directory structures could fail if the site_url and home_url were different.
|
272 |
+
* Fix: Discount amount calculations were assuming that the discount has Price ID assignments.
|
273 |
+
* Fix: Logging in from the {receipt_link} in emails now properly redirects the user to the receipt page.
|
274 |
+
* Fix - Blocks: The checkout block could prevent purchases if a logged in user did not have a name already.
|
275 |
+
* Fix - Blocks: The Order History block no longer shows Trashed orders.
|
276 |
+
* Fix - Blocks: Incompatible combinations of settings on the Checkout block could produce a fatal error.
|
277 |
+
|
278 |
= 3.1.0.2, October 27, 2022 =
|
279 |
* New - Blocks: The registration block now supports the WordPress password strength script.
|
280 |
* Improvement: The products API now includes the product permalink.
|
652 |
* Dev: The edd_download_price_table_head and edd_download_price_table_row actions have been formally deprecated.
|
653 |
|
654 |
== Upgrade Notice ==
|
655 |
+
IMPORTANT: Easy Digital Downloads 3.0 is a major release that includes many improvements and changes. You will be asked to perform database maintenance once installed. Please ensure you make a backup of your site prior to upgrading. Your site should remain functional during this maintenance, but as with all updates, it is best to make a backup of your site prior to updating.
|
templates/history-downloads.php
CHANGED
@@ -24,10 +24,11 @@ $page = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1;
|
|
24 |
if ( ! empty( $customer ) ) {
|
25 |
$orders = edd_get_orders(
|
26 |
array(
|
27 |
-
'customer_id'
|
28 |
-
'number'
|
29 |
-
'offset'
|
30 |
-
'type'
|
|
|
31 |
)
|
32 |
);
|
33 |
} else {
|
@@ -116,8 +117,9 @@ if ( $orders ) :
|
|
116 |
if ( ! empty( $customer->id ) ) {
|
117 |
$count = edd_count_orders(
|
118 |
array(
|
119 |
-
'customer_id'
|
120 |
-
'type'
|
|
|
121 |
)
|
122 |
);
|
123 |
echo edd_pagination(
|
24 |
if ( ! empty( $customer ) ) {
|
25 |
$orders = edd_get_orders(
|
26 |
array(
|
27 |
+
'customer_id' => $customer->id,
|
28 |
+
'number' => 20,
|
29 |
+
'offset' => 20 * ( intval( $page ) - 1 ),
|
30 |
+
'type' => 'sale',
|
31 |
+
'status__not_in' => array( 'trash', 'refunded', 'abandoned' ),
|
32 |
)
|
33 |
);
|
34 |
} else {
|
117 |
if ( ! empty( $customer->id ) ) {
|
118 |
$count = edd_count_orders(
|
119 |
array(
|
120 |
+
'customer_id' => $customer->id,
|
121 |
+
'type' => 'sale',
|
122 |
+
'status__not_in' => array( 'trash', 'refunded', 'abandoned' ),
|
123 |
)
|
124 |
);
|
125 |
echo edd_pagination(
|
templates/history-purchases.php
CHANGED
@@ -24,10 +24,11 @@ $page = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1;
|
|
24 |
$user_id = get_current_user_id();
|
25 |
$orders = edd_get_orders(
|
26 |
array(
|
27 |
-
'user_id'
|
28 |
-
'number'
|
29 |
-
'offset'
|
30 |
-
'type'
|
|
|
31 |
)
|
32 |
);
|
33 |
|
24 |
$user_id = get_current_user_id();
|
25 |
$orders = edd_get_orders(
|
26 |
array(
|
27 |
+
'user_id' => $user_id,
|
28 |
+
'number' => 20,
|
29 |
+
'offset' => 20 * ( intval( $page ) - 1 ),
|
30 |
+
'type' => 'sale',
|
31 |
+
'status__not_in' => array( 'trash' ),
|
32 |
)
|
33 |
);
|
34 |
|