jQuery.noConflict();

jQuery(function ($){
  /*$("#schools").tablesorter({
    sortList: [[2,0],[0,0]]
  });*/
  $("#schools tr td p").hide();
  $("#schools tr td > a").click(function() {
    var index = $("#schools tr td a").index(this);
    $("#schools tr td a:eq("+index+")").siblings("p").toggle();
    return false;
  });
});

jQuery(function() {
  jQuery("#schools2 tr .school-info p").hide();
  jQuery("#schools2 tr .school-info > a").click(function() {
    var index = jQuery("#schools2 tr .school-info a").index(this);
    jQuery("#schools2 tr .school-info a:eq("+index+") p").toggle();
    return false;
  });
});

jQuery(document).ready(function() {
  jQuery('td:empty').html('&nbsp;');  
  jQuery('#_chart_show').click(show_chart);
  show_chart();
});

if(jQuery('#tab-container-1')[0]) { 
  var tabber1 = new Yetii({
    id: 'tab-container-1'
  });
}  

function show_chart() {
  var period_id = jQuery('#_chart_period_id').val();
  var item_x_id = jQuery('#_chart_item_x_id').val();
  var type      = jQuery('#_chart_type').val();     
  jQuery('#_chart').text('Prosím čekejte').load('http://www.sipkhk.cz/ajax-charts', { period_id: period_id, item_x_id: item_x_id, type: type });
}


