function object_order(id){
 if($('#catalog_order_amount').val()==0)   return;
 $.ajax({
          type: "POST",
          url: "/modules/catalog/catalog.ajax.php",
          data: ({
              mode : 'order',
              catalog_object_id : id,
              catalog_order_amount: $('#catalog_order_amount').val()
           }),
           success: function(data){
                if(data=='ok') {
                    $('#form_object_order .result').html('<b>Добавлено!<b>').stop(true, true).css('opacity',1).animate({opacity:0.2},4000);
                    $('#TB_window').delay(1000).fadeOut(500,  tb_remove());
                    refresh_basket_slot()
                } else  {
                    $('#form_object_order .error').html(data);
                }
           }
    });
}

function refresh_basket_slot() {
    $.ajax({
          type: "POST",
          url: "/modules/catalog/catalog.ajax.php",
          data: ({
              mode : 'basket_slot'
           }),
           success: function(data){
                $('.basket').html(data);
           }
    });

}
