If you put ajax tab before preloaded tabs,
preloaded tabs won't work properly (tab content won't be shown).

To fix you have to change theme_tabpage function
(don't add div if tab is ajax loaded):

The correct function:

<?php
function theme_tabpage($element) {
  $output = '';
  // Ensure the tab has content before rendering it.
  if (!empty($element['#content']) || !empty($element['#children'])) {
    $output .= '<div id="' . $element['#tab_name'] . '" class="tabs-' . $element['#tabset_name'] . '">';
    $output .= '<h2 class="drupal-tabs-title js-hide">'. $element['#title'] .'</h2>';
    $output .= $element['#content'] . (!empty($element['#children']) ? $element['#children'] : '');
    $output .='</div>';
  }
  return $output;
}
?>