View Product Page

Actions

includes/abstracts/class-yith-wcaf-abstract-rest-crud-controller.php

Copied!
Copy

Allows to trigger some action after a single object is created or updated via the REST API.
$object will be replaced with the object type

Params
 WC_Data         $object    Inserted object.
 WP_REST_Request $request   Request object.
 boolean         $creating  True when creating object, false when updating.

Copied!
Copy

Allows to trigger some action after a single object is deleted or trashed via the REST API.
$object will be replaced with the object type

Params
 WC_Data          $object   The deleted or trashed object.
 WP_REST_Response $response The response data.
 WP_REST_Request  $request  The request sent to the API.

includes/admin/admin-panels/class-yith-wcaf-affiliates-admin-panel.php

Copied!
Copy

Allows to trigger some action after saving the affiliate when it is added manually

Params
 YITH_WCAF_Affiliate $affiliate Affiliate object.

includes/admin/class-yith-wcaf-admin-coupons.php

Copied!
Copy

Allows to trigger when saving the affiliate data in the coupon

Params
 WC_Coupon $coupon     Coupon object.
 int       $new_referrer  New value to save.
 string    $prev_referrer Previous value saved

includes/admin/class-yith-wcaf-admin-profile-premium.php

Copied!
Copy

Allows to trigger some action when the persistent token is saved

Params
 int    $user_id  Current user id.
 string $referral Current referral token.
 int    $order_id Current order id (if any; null otherwise).

Copied!
Copy

Allows to trigger some action when the persistent token is deleted

Params
 int $user_id Current user id.

includes/admin/class-yith-wcaf-admin-profile.php

Copied!
Copy

Allows to trigger some action before saving the fields in the user profile

Params
 int                 $user_id   User id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.
 array               $sets      Array of fieldsets of options to print; leave empty to print all.

Copied!
Copy

Allows to trigger some action after saving the fields in the user profile

Params
 int                 $user_id   User id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.
 array               $sets      Array of fieldsets of options to print; leave empty to print all.

includes/admin/class-yith-wcaf-admin-templates.php

Copied!
Copy

Allows to trigger some action after copying email template file

Params
 string $template Template to copy.

Copied!
Copy

Allows to trigger some action after deleting template file

Params
 string $template Template to delete.

includes/admin/class-yith-wcaf-admin.php

Copied!
Copy

Allows to trigger some action before enqueueing the styles in the backend


Copied!
Copy

Allows to trigger some action before enqueueing the scripts in the backend


includes/class-yith-wcaf-affiliate-factory.php

Copied!
Copy

Allows to trigger some action when a customer sends the application to become an affiliate

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

includes/class-yith-wcaf-affiliate.php

Copied!
Copy

Allows to trigger some action when the affiliate's status changes.
$status will be replaced with the affiliate's status

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

Copied!
Copy

Allows to trigger some action when the affiliate status changes into a new status.
$new_status will be replaced with the new status for the affiliate

Params
 int $affiliate_id Affiliate id.

Copied!
Copy

Allows to trigger some action when the affiliate status changes from the old status into the new status.
$old_status will be replaced with the old affiliate status.
$new_status will be replaced with the new affiliate status

Params
 int $affiliate_id Affiliate id.

Copied!
Copy

Allows to trigger some action when the affiliate status has changed

Params
 int    $affiliate_id Affiliate id.
 string $new_status   New status.
 string $old_status   Old status.

Copied!
Copy

Allows to trigger some action when the affiliate's payment email has changed

Params
 int    $affiliate_id      Affiliate id.
 string $payment_email     Affiliate's payment email.
 string $old_payment_email Affiliate's old payment email.

Copied!
Copy

Allows to trigger some action when performing the actions to ban/unban the affiliate.
$ban_status will be replaced with the ban status for the affiliate

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

includes/class-yith-wcaf-ajax-handler-premium.php

Copied!
Copy

Allows to trigger some action after the token has been set

Params
 string $token Token.

includes/class-yith-wcaf-checkout.php

Copied!
Copy

Allows to trigger some action when an order is processed with an affiliate associated

Params
 WC_Order $order Order object.
 string   $token Affiliate token.

includes/class-yith-wcaf-commission.php

Copied!
Copy

Allows to trigger some action when the commission status changes into a new status.
$new_status will be replaced with the new status for the commission

Params
 int $commission_id Commission id.

Copied!
Copy

Allows to trigger some action when the commission status changes from the old status into the new status.
$old_status will be replaced with the old commission status.
$new_status will be replaced with the new commission status

Params
 int $commission_id Commission id.

Copied!
Copy

Allows to trigger some action when the commission status has changed

Params
 int    $commission_id Commission id.
 string $new_status    New status.
 string $old_status    Old status.

includes/class-yith-wcaf-form-handler-premium.php

Copied!
Copy

Allows to trigger some action when saving affiliate's settings

Params
 YITH_WCAF_Affiliate $affiliate Affiliate object.
 array               $fields    Submitted and sanitized fields.

includes/class-yith-wcaf-form-handler.php

Copied!
Copy

Allows to trigger some action before executing the form handler.
$handler will be replaced with the form handler

Params
 array $posted_data    Posted data.
 array $handler_option Handler option.

Copied!
Copy

Allows to trigger some action after executing the form handler.
$handler will be replaced with the form handler

Params
 object $last_result    Last result.
 array  $posted_data    Posted data.
 array  $handler_option Handler option.

Copied!
Copy

Allows to trigger some action when registering a customer as a new affiliate

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

Copied!
Copy

Allows to trigger some action when saving affiliate's settings

Params
 YITH_WCAF_Affiliate $affiliate Affiliate object.
 array               $fields    Submitted and sanitized fields.

includes/class-yith-wcaf-install.php

Copied!
Copy

Allows to perform any required upgrade


includes/class-yith-wcaf-orders-premium.php

Copied!
Copy

Allows to trigger some action when the persistent token is saved

Params
 int    $customer Current user id.
 string $referral Current referral token.
 int    $order_id Current order id (if any; null otherwise).

includes/class-yith-wcaf-orders.php

Copied!
Copy

Allows to trigger some action when changing the commission status.
$action will be replaced with the action to apply depending on the commission status

Params
 WC_Order $order       Order object.
 array    $commissions Commissions.

includes/class-yith-wcaf-payment.php

Copied!
Copy

Allows to trigger some action when the payment status changes into a new status.
$new_status will be replaced with the new status for the payment

Params
 int $payment_id Payment id.

Copied!
Copy

Allows to trigger some action when the payment status changes from the old status into the new status.
$old_status will be replaced with the old payment status.
$new_status will be replaced with the new payment status

Params
 int $payment_id Payment id.

Copied!
Copy

Allows to trigger some action when the payment status has changed

Params
 int    $payment_id Payment id.
 string $new_status New status.
 string $old_status Old status.

includes/class-yith-wcaf-payments-premium.php

Copied!
Copy

Allows to trigger some action when the payment is sent

Params
 YITH_WCAF_Payment $payment Payment object.

Copied!
Copy

Allows to trigger some action when the payments are sent

Params
 array $payment_ids Array with the ids of the payments sent.

includes/class-yith-wcaf-payments.php

Copied!
Copy

Allows to trigger some action after the payments has been registered

Params
 array  $payments   Array of payments.
 string $gateway_id Gateway id to use for payments.

includes/class-yith-wcaf-privacy.php

Copied!
Copy

Allows to trigger some action before anonymizing props from a specific object

Params
 object $object Object to anonymize data from.

Copied!
Copy

Allows to trigger some action after anonymizing props from a specific object

Params
 object $object Object to anonymize data from.

includes/class-yith-wcaf-session.php

Copied!
Copy

Allows to trigger some action after the referral cookie has been set


includes/class-yith-wcaf-withdraws.php

Copied!
Copy

Allows to trigger some action before processing the withdraw request

Params
 array               $posted    Array of posted values.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

Copied!
Copy

Allows to trigger some action after processing the withdraw request

Params
 int                 $payment_id Payment id.
 YITH_WCAF_Affiliate $affiliate  Affiliate object.

includes/class-yith-wcaf.php

Copied!
Copy

Allows to trigger some action when initializing the plugin


Copied!
Copy

Allows to trigger some action when the plugin scripts are registered


Copied!
Copy

Allows to trigger some actions before enqueueing the plugin styles


Copied!
Copy

Allows to trigger some actions before enqueueing the plugin scripts


includes/dashboard/class-yith-wcaf-dashboard-table.php

Copied!
Copy

Allows to render some content before the table topbar in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table topbar in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table topbar in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table topbar in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table options in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table options in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table options in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table options in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content for the field column in the dashboard table.
$item will be replaced with the item that is being displayed in the table.
$field will be replaced with the column key

Params
 YITH_WCAF_Abstract_Object $object          Row object.
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table bottombar in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content before the table bottombar in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table bottombar in the dashboard.
$item will be replaced with the item that is being displayed in the table

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

Copied!
Copy

Allows to render some content after the table bottombar in the dashboard

Params
 YITH_WCAF_Dashboard_Table $dashboard_table Dashboard table object.

includes/data-stores/class-yith-wcaf-affiliate-data-store.php

Copied!
Copy

Allows to trigger some action when a new affiliate is created

Params
 int                 $affiliate_id Affiliate id.
 YITH_WCAF_Affiliate $affiliate    Affiliate object.

Copied!
Copy

Allows to trigger some action when an affiliate is updated

Params
 int                 $affiliate_id Affiliate id.
 YITH_WCAF_Affiliate $affiliate    Affiliate object.

Copied!
Copy

Allows to trigger some action before deleting an affiliate

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

Copied!
Copy

Allows to trigger some action when an affiliate is deleted

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

Copied!
Copy

Allows to trigger some action after deleting an affiliate

Params
 int                 $id        Affiliate id.
 YITH_WCAF_Affiliate $affiliate Affiliate object.

includes/data-stores/class-yith-wcaf-click-data-store.php

Copied!
Copy

Allows to trigger some action when a new click is created

Params
 int             $click_id Click id.
 YITH_WCAF_Click $click    Click object.

Copied!
Copy

Allows to trigger some action when a click is updated

Params
 int             $click_id Click id.
 YITH_WCAF_Click $click    Click object.

Copied!
Copy

Allows to trigger some action before deleting a click

Params
 int             $id    Click id.
 YITH_WCAF_Click $click Click object.

Copied!
Copy

Allows to trigger some action when a click is deleted

Params
 int             $id    Click id.
 YITH_WCAF_Click $click Click object.

Copied!
Copy

Allows to trigger some action after deleting a click

Params
 int             $id    Click id.
 YITH_WCAF_Click $click Click object.

includes/data-stores/class-yith-wcaf-commission-data-store.php

Copied!
Copy

Allows to trigger some action when a new commission is created

Params
 int                  $commission_id Commission id.
 YITH_WCAF_Commission $commission    Commission object.

Copied!
Copy

Allows to trigger some action when a commission is updated

Params
 int                  $commission_id Commission id.
 YITH_WCAF_Commission $commission    Commission object.

Copied!
Copy

Allows to trigger some action before deleting a commission

Params
 int                  $id         Commission id.
 YITH_WCAF_Commission $commission Commission object.

Copied!
Copy

Allows to trigger some action when a commission is deleted

Params
 int                  $id         Commission id.
 YITH_WCAF_Commission $commission Commission object.

Copied!
Copy

Allows to trigger some action after deleting a commission

Params
 int                  $id         Commission id.
 YITH_WCAF_Commission $commission Commission object.

includes/data-stores/class-yith-wcaf-payment-data-store.php

Copied!
Copy

Allows to trigger some action when a new payment is created

Params
 int               $payment_id Payment id.
 YITH_WCAF_Payment $payment    Payment object.

Copied!
Copy

Allows to trigger some action when a payment is updated

Params
 int               $payment_id Payment id.
 YITH_WCAF_Payment $payment    Payment object.

Copied!
Copy

Allows to trigger some action before deleting a payment

Params
 int               $id      Payment id.
 YITH_WCAF_Payment $payment Payment object.

Copied!
Copy

Allows to trigger some action when a payment is deleted

Params
 int               $id      Payment id.
 YITH_WCAF_Payment $payment Payment object.

Copied!
Copy

Allows to trigger some action after deleting a payment

Params
 int               $id      Payment id.
 YITH_WCAF_Payment $payment Payment object.

includes/data-stores/class-yith-wcaf-rate-rule-data-store.php

Copied!
Copy

Allows to trigger some action when a new rate rule is created

Params
 int                 $rate_rule_id Rate rule id.
 YITH_WCAF_Rate_Rule $rule         Rate rule object.

Copied!
Copy

Allows to trigger some action when a rate rule is updated

Params
 int                 $rate_rule_id Rate rule id.
 YITH_WCAF_Rate_Rule $rule         Rate rule object.

Copied!
Copy

Allows to trigger some action before deleting a rate rule

Params
 int                 $id   Rate rule id.
 YITH_WCAF_Rate_Rule $rule Rate rule object.

Copied!
Copy

Allows to trigger some action when a rate rule is deleted

Params
 int                 $id   Rate rule id.
 YITH_WCAF_Rate_Rule $rule Rate rule object.

Copied!
Copy

Allows to trigger some action after deleting a rate rule

Params
 int                 $id   Rate rule id.
 YITH_WCAF_Rate_Rule $rule Rate rule object.

includes/gateways/class-yith-wcaf-bacs-gateway.php

Copied!
Copy

Allows to trigger some action when the payment is sent

Params
 YITH_WCAF_Payment $payment Payment object.

includes/gateways/class-yith-wcaf-funds-gateway.php

Copied!
Copy

Allows to trigger some action when the payment is sent

Params
 YITH_WCAF_Payment $payment Payment object.

includes/gateways/class-yith-wcaf-payouts-gateway.php

Copied!
Copy

Allows to trigger some action when the payment is sent

Params
 YITH_WCAF_Payment $payment Payment object.

includes/gateways/class-yith-wcaf-paypal-gateway.php

Copied!
Copy

Allows to trigger some action when the payment is sent

Params
 YITH_WCAF_Payment $payment Payment object.

init.php

Copied!
Copy

Allows the plugin initialization


templates/shortcodes/dashboard-clicks.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-commissions.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-coupons.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-payments.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-settings-premium.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content before the settings section in the Affiliate Dashboard


Copied!
Copy

Allows to render some content after the payment email in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content before the additional info in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-settings.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content before the settings section in the Affiliate Dashboard


Copied!
Copy

Allows to render some content after the payment email in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content before the additional info in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content after the additional info in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content in the settings form in the Affiliate Dashboard


Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/dashboard-summary.php

Copied!
Copy

Allows to render some content before the summary in the Affiliate Dashboard

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to output summary content in the Affiliate Dashboard

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the summary in the Affiliate Dashboard

Params
 array $atts Array with section attributes.

templates/shortcodes/dashboard-summary/withdraw-modal-opener.php

Copied!
Copy

Allows to render some content before the button to open the withdraw modal


Copied!
Copy

Allows to render some content after the button to open the withdraw modal


templates/shortcodes/dashboard-summary/withdraw-modal.php

Copied!
Copy

Allows to render some content before the balance in the withdraw modal


Copied!
Copy

Allows to render some content after the balance in the withdraw modal


Copied!
Copy

Allows to render some content before the notes in the withdraw modal


Copied!
Copy

Allows to render some content after the notes in the withdraw modal


Copied!
Copy

Allows to render some content in the withdraw_modal


templates/shortcodes/dashboard.php

Copied!
Copy

Allows to render some content before the dashboard section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to output section content in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content after the dashboard section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/link-generator.php

Copied!
Copy

Allows to render some content before the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

Copied!
Copy

Allows to render some content before the referral link generator in the Affiliate Dashboard

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content in the section to share the referral URL

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content after the section to share the referral URL

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content after the referral link generator in the Affiliate Dashboard

Params
 array $atts Array with section attributes.

Copied!
Copy

Allows to render some content after the section in the Affiliate Dashboard

Params
 string $section Section.
 array  $atts    Array with section attributes.

templates/shortcodes/link-generator/share.php

Copied!
Copy

Allows to render some content after the buttons to share the affiliate's referral URL in the Affiliate Dashboard

Params
 string $share_link_url   Referral URL to share.
 string $share_title      Title to share referral URL.
 string $share_link_title Title in the referral URL.

templates/shortcodes/navigation-menu.php

Copied!
Copy

Allows to render some content before the links in the Affiliate Dashboard

Params
 array $dashboard_links Affiliate dashboard links.

Copied!
Copy

Allows to render some content after the links in the Affiliate Dashboard

Params
 array $dashboard_links Affiliate dashboard links.

templates/shortcodes/registration-form.php

Copied!
Copy

Allows to render some content at the beginning of the registration form for the affiliates


Copied!
Copy

Allows to render some content in the registration form for the affiliates


Copied!
Copy

Allows to render some content in the form to "Become an affiliate"


Copied!
Copy

Allows to render some content before the form to "Become an affiliate" ends


views/affiliates/details-panel.php

Copied!
Copy

Allows to render some content after the affiliate options in the affiliate profile

Params
 YITH_WCAF_Affiliate $affiliate Affiliate object

views/meta-boxes/referral-commissions-metabox-premium.php

Copied!
Copy

Allows to render some content after the referrals commissions table

Params
 WC_Order $order Order object.

views/meta-boxes/referral-commissions-metabox.php

Copied!
Copy

Allows to render some content after the referrals commissions table

Params
 WC_Order $order Order object.