Untitled

mail@pastecode.io avatar
unknown
php
2 years ago
824 B
3
Indexable
Never
 add_action('salesking_my_orders_custom_columns', function(){
    ?>
    <th class="nk-tb-col tb-col-sm"><span class="sub-text"><?php esc_html_e('Payment Link','salesking'); ?></span></th>
    <?php
});

add_action('salesking_my_orders_custom_columns_footer', function(){
     ?>
     <th class="nk-tb-col tb-col-sm"><span class="sub-text"><?php esc_html_e('link','salesking'); ?></span></th>
     <?php
 });
add_action('salesking_my_orders_custom_columns_content', function($order){
     ?>
     <td class="nk-tb-col tb-col-sm">
         <div>
              <span class="tb-sub">
              	<?php if ($order->get_status() == 'pending'){
              		echo '<a href="'.$order->get_checkout_payment_url().'">Payment URL</a>'; 
              	}?>
              </span>
          </div>
      </td>
     <?php
 }, 10, 1);