Filters Associated With Payment

Filter: wp_travel_payment_status_list #

WP Travel all payment status list.

Source

File: /inc/helpers.php
Used by: /inc/helpers.php

Parameters
$status

Example:

function prefix_wp_travel_payment_status_list( $status ) {
    $status[‘custom status’] = array(
    ‘color’ => ‘#FFFFFF’,
    ‘text’ => __( ‘Custom Status’, ‘wp-travel’),
    );
    return $status;
}
add_filter( 'wp_travel_payment_status_list', 'prefix_wp_travel_payment_status_list' );

Filter: wp_travel_payment_mode_list #

WP Travel all payment mode list.

Active Since v1.0.5

Source

File: /inc/helpers.php
Used by: /inc/helpers.php

Parameters
$mode

Example:

function prefix_wp_travel_payment_mode_list( $mode ) {
    $mode[‘custom status’] = array(
    ‘color’ => ‘#FFFFFF’,
    ‘text’ => __( ‘Custom Status’, ‘wp-travel’),
    );
    return $mode;
}
add_filter( 'wp_travel_payment_mode_list', 'prefix_wp_travel_payment_mode_list' );

Filter: wp_travel_custom_partial_payment_string #

WP Travel custom partial payment label.

Active Since v3.0.7

Source

File: /inc/admin/extras/views/tabs/tab-contents/itineraries/price.php
Used by: /inc/admin/extras/views/tabs/tab-contents/itineraries/price.php

Parameters
$custom_partial_payout_string

Example:

function prefix_wp_travel_custom_partial_payment_string(
    $custom_partial_payout_string ) {
    $custom_partial_payout_string = ‘__( 'Partial Payout (MIN)(%)', 'wp-travel' )’;
    return $custom_partial_payout_string;
}
add_filter( 'wp_travel_custom_partial_payment_string', 'prefix_wp_travel_custom_partial_payment_string' );

Filter :wp_travel_partial_payment_string #

WP Travel custom partial payment label.

Source

File: /inc/admin/extras/views/tabs/tab-contents/settings/payment.php
Used by: /inc/admin/extras/views/tabs/tab-contents/settings/payment.php

Parameters
$partial_payment_string, $settings

Example:

function prefix_wp_travel_partial_payment_string( $partial_payment_string, $settings ) {
    $partial_payment_string = ‘__( ‘Payout (MIN)(%)', 'wp-travel' )’;
    return $partial_payment_string;
}
add_filter( 'wp_travel_partial_payment_string', 'prefix_wp_travel_partial_payment_string', 12, 2 );

Filter: wp_travel_payment_modes #

Filter for WP Travel payment modes.

Source

File: /inc/helpers/helpers-price.php
Used by: /inc/helpers/helpers-price.php

Parameters
$modes

Example:

function prefix_wp_travel_payment_modes( $modes ) {
    $mode[‘custom_mode’] = esc_html__( ‘Custom Payment’, ‘wp-travel’ );
    return $mode;
}
add_filter( 'wp_travel_payment_modes', 'prefix_wp_travel_payment_modes' );

Filter: wp_travel_payment_gateway_lists #

WP Travel payment gateway list.

Active Since v1.1.0

Source

File: /inc/payments/wp-travel-payments.php
Used by: /inc/payments/wp-travel-payments.php

Parameters
$gateway

Example:

function prefix_wp_travel_payment_gateway_lists( $gateway ) {
    $gateway[‘payfast’] = __( ‘PayFast Checkout’, ‘wp-travel’ );
    return $gateway;
}
add_filter( 'wp_travel_payment_gateway_lists', 'prefix_wp_travel_payment_gateway_lists' );

Filter: wp_travel_payout_percent #

WP Travel minimum payout percent.

Source

File: /inc/payments/wp-travel-payments.php
Used by: /inc/payments/wp-travel-payments.php

Parameters
$payout_percent, $post_id

Example:

function prefix_wp_travel_payout_percent( $payout_percent, $post_id ) {
    $payout_percent = array( 15 );
    return $payout_percent;
}
add_filter( 'wp_travel_payout_percent', 'prefix_wp_travel_payout_percent', 12, 2 );

Filter: wp_travel_selected_payment_gateway #

WP Travel currently selected payment gateway.

Source

File: /inc/payments/wp-travel-payments.php
Used by: /inc/payments/wp-travel-payments.php

Parameters
$selected_payment

Example:

function prefix_wp_travel_selected_payment_gateway( $selected_payment ) {
    $selected_payment = ‘Manage Payment’;
    return $selected_payment;
}
add_filter( 'wp_travel_selected_payment_gateway', 'prefix_wp_travel_selected_payment_gateway' );