$tasks=\DB::getAll("SELECT * FROM `tasks` WHERE `user_id`=? OR `isp_id`=? ORDER BY `id` DESC LIMIT 10",array($_SESSION['user_id'],$_SESSION['user_id']));
$smarty->assign('stat_tovar_show',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='tovar_show' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_tovar_cat',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='tovar_cat' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_main',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='main' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_cart',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='cart' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_sitemap',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='qsitemap' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_css',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='css' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_lk',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='lk' ORDER BY `t` DESC LIMIT 10000"),4));
$smarty->assign('stat_act',round(\DB::getValue("SELECT AVG(speed) FROM `site_speed` WHERE `mod`='act' ORDER BY `t` DESC LIMIT 10000"),4));