| 1 |
<?php |
| 2 |
if(isset($this)) |
| 3 |
$usces = &$this; |
| 4 |
|
| 5 |
$payments = usces_get_system_option( 'usces_payment_method', 'sort' ); |
| 6 |
$payments = apply_filters( 'usces_filter_available_payment_method', $payments ); |
| 7 |
foreach ( (array)$payments as $id => $payment ) { |
| 8 |
if( !empty( $payment['settlement'] ) ){ |
| 9 |
|
| 10 |
switch( $payment['settlement'] ){ |
| 11 |
case 'acting_remise_card': |
| 12 |
$paymod_id = 'remise'; |
| 13 |
$have_continue_charge = usces_have_continue_charge(); |
| 14 |
$have_regular_order = usces_have_regular_order(); |
| 15 |
|
| 16 |
if( 'on' != $usces->options['acting_settings'][$paymod_id]['card_activate'] |
| 17 |
|| 'on' != $usces->options['acting_settings'][$paymod_id]['howpay'] |
| 18 |
|| 'on' != $usces->options['acting_settings'][$paymod_id]['activate'] |
| 19 |
|| 'activate' != $payment['use'] |
| 20 |
|| ( $have_continue_charge || $have_regular_order ) ){ |
| 21 |
break; |
| 22 |
} |
| 23 |
|
| 24 |
$div = isset( $_POST['div'] ) ? esc_html($_POST['div']) : '0'; |
| 25 |
|
| 26 |
$html .= ' |
| 27 |
<table class="customer_form" id="' . $paymod_id . '"> |
| 28 |
<tr> |
| 29 |
<th scope="row">'.__('payment method', 'usces').'</th> |
| 30 |
<td colspan="2"> |
| 31 |
<select name="offer[div]" id="div_remise"> |
| 32 |
<option value="0"' . (('0' === $div) ? ' selected="selected"' : '') . '>'.__('Single payment', 'usces').'</option> |
| 33 |
<option value="1"' . (('1' === $div) ? ' selected="selected"' : '') . '>2'.__('-time payment', 'usces').'</option> |
| 34 |
<option value="2"' . (('2' === $div) ? ' selected="selected"' : '') . '>'.__('Libor Funding pay', 'usces').'</option> |
| 35 |
</select> |
| 36 |
</td> |
| 37 |
</tr> |
| 38 |
</table>'; |
| 39 |
break; |
| 40 |
} |
| 41 |
$html .= apply_filters( 'usces_filter_delivery_secure_form_loop', '', $payment ); |
| 42 |
} |
| 43 |
} |
| 44 |
$html = apply_filters( 'usces_filter_delivery_secure_form', $html, $payments ); |
| 45 |
$html .= wp_nonce_field( 'wc_delivery_secure_nonce', 'wc_nonce', false, false ); |
| 46 |
|