diff --git a/README.txt b/README.txt index a61876f..697e8b1 100755 --- a/README.txt +++ b/README.txt @@ -520,6 +520,7 @@ execute on the checkout. Usage: + add_filter('woo_solo_api_overwrite_request_on_checkout', 'my_payment_processor_overwrite', 10, 2); function my_payment_processor_overwrite($sendControl, $order) { @@ -537,9 +538,12 @@ function my_payment_processor_overwrite($sendControl, $order) { // Default fallback. return $sendControl; } + + @param string $sendControl Type of send control. Can be 'checkout' or 'status_change'. @param WC_Order $order Order object. + -------------- @@ -559,8 +563,10 @@ function my_customer_filter($customerNote, $order) { } + @param string $customerNote Existing customer note. @param WC_Order $order Order object + -------------- @@ -571,14 +577,18 @@ you can just hook to this filter and modify the request body. Usage: + add_filter('woo_solo_api_modify_request_body', 'my_customer_filter', 10, 2); function my_customer_filter($requestBody, $order) { // (maybe) modify $requestBody. return $requestBody; } + + @param array $requestBody Existing customer note. + -------------- @@ -598,9 +608,11 @@ function my_message_filter($emailMessage, $orderId, $email) { } + @param string $emailMessage Email message from options to filter. @param int $orderId Order ID. @param string $email Email address of the person for whom this message needs to be send to. + -------------- @@ -619,9 +631,11 @@ function my_message_filter($defaultMessage, $orderId, $email) { } + @param string $defaultMessage Email message to filter. @param int $orderId Order ID. @param string $email Email address of the person for whom this message needs to be send to. + -------------- @@ -641,8 +655,10 @@ function my_title_filter($emailTitle, $orderId) { } + @param string $emailTitle Email title. @param int $orderId Order ID. + -------------- @@ -662,8 +678,10 @@ function my_title_filter($defaultTitle, $orderId) { } + @param string $emailTitle Email title. @param int $orderId Order ID. + -------------- @@ -673,10 +691,12 @@ When email to customer is sent, maybe you want to add something more. In that case you'll probably need to modify the headers sent with the email. Default ones are + [ 'MIME-Version: 1.0', 'Content-Type: text/html', ]; + You can add to that list. @@ -691,11 +711,13 @@ function my_custom_email_headers($headers) { } + @param array $headers Email headers to pass to wp_mail. + -------------- -Filter the from name set from the options +Filter the 'from' name set from the options Usage: @@ -708,7 +730,9 @@ function my_custom_from_name($name) { } + @param string $name Name to change in the "From" field. + -------------- @@ -730,7 +754,9 @@ function my_global_discount($globalDiscount) { } + @param int $globalDiscount The value of the global discount to apply to every item. + -------------- @@ -751,6 +777,8 @@ function my_tax_rate($taxRate, $itemData, $taxRates) { } + @param float $taxRate The value of the tax rate for the current order item. @param array $itemData The data for the current order item. @param array $taxRates The value of the tax rates for the current order item. + diff --git a/languages/woo-solo-api-js.pot b/languages/woo-solo-api-js.pot index d3716e8..b4e7c15 100644 --- a/languages/woo-solo-api-js.pot +++ b/languages/woo-solo-api-js.pot @@ -1,15 +1,7 @@ -#, fuzzy msgid "" msgstr "" -"Project-Id-Version: \n" -"POT-Creation-Date: \n" -"PO-Revision-Date: \n" -"Last-Translator: \n" -"Language-Team: \n" -"MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.0.1\n" +"X-Generator: babel-plugin-makepot\n" #: assets/dev/scripts/const/dueDate.jsx:10 msgid "1 week" @@ -265,8 +257,8 @@ msgstr "" #: assets/dev/scripts/index.jsx:300 msgid "" -"For more details on the options you can read the official SOLO API documentation " -"here: " +"For more details on the options you can read the official SOLO API " +"documentation here: " msgstr "" #: assets/dev/scripts/index.jsx:334 @@ -377,8 +369,9 @@ msgstr "" #: assets/dev/scripts/index.jsx:495 msgid "" -"The currency will be automatically added if the selected currency is different " -"from HRK. Also, a note about conversion rate will be added to the invoice/offer." +"The currency will be automatically added if the selected currency is " +"different from HRK. Also, a note about conversion rate will be added to the " +"invoice/offer." msgstr "" #: assets/dev/scripts/index.jsx:501 @@ -431,9 +424,9 @@ msgstr "" #: assets/dev/scripts/index.jsx:559 msgid "" -"Decide when to send the PDF of the order or invoice.On customer checkout, or " -"when you approve the order in the WooCommerce admin.This will determine when the " -"call to the SOLO API will be made" +"Decide when to send the PDF of the order or invoice.On customer checkout, " +"or when you approve the order in the WooCommerce admin.This will determine " +"when the call to the SOLO API will be made" msgstr "" #: assets/dev/scripts/index.jsx:565 @@ -466,8 +459,8 @@ msgstr "" #: assets/dev/scripts/index.jsx:615 msgid "" -"CAUTION: This change is global, every mail send from your WordPress " -"will have this 'from' name" +"CAUTION: This change is global, every mail send from your " +"WordPress will have this 'from' name" msgstr "" #: assets/dev/scripts/index.jsx:630 @@ -480,8 +473,8 @@ msgstr "" #: assets/dev/scripts/index.jsx:636 msgid "" -"Pressing the button will make a request to your Solo API account,and will list " -"all the invoices you have" +"Pressing the button will make a request to your Solo API account,and will " +"list all the invoices you have" msgstr "" #: assets/dev/scripts/index.jsx:651 @@ -530,4 +523,4 @@ msgstr "" #: assets/dev/scripts/index.jsx:683 msgid "Updated at" -msgstr "" +msgstr "" \ No newline at end of file