$stock[$a_counter] = '<b>' . intval($p['qty_stock']) . '</b>';
     $stock_target[$a_counter] = '<b>-</b>';
     $qty_ordered[$a_counter] = '<b>' . intval($p['qty_order']) . '</b>';
     $qty_missing[$a_counter] = '<b>-</b>';
     $levelling_target[$a_counter] = '<b>-</b>';
     $levelling_orders[$a_counter] = '<b>-</b>';
     $levelling_orders_ptb[$a_counter] = '<b>-</b>';
     $levelling_orders_os[$a_counter] = '<b>-</b>';
     $total_target[$a_counter] = '<b>-</b>';
     $total_qty_missing[$a_counter] = '<b>-</b>';
     $levelling_orders_today[$a_counter] = '<b>-</b>';
     $order_qty[$a_counter] = '<b>-</b>';
 }
 foreach ($p['articles'] as $aid => $a) {
     $a_counter++;
     $fc_base_daily = $obj_product->getForecastDailyBaseValue($aid);
     $size[$a_counter] = $a['article_length'] > 0 ? textLength($a['article_length']) : 'None';
     $ean[$a_counter] = $a['article_ean'];
     $sold_last_month_nopromo[$a_counter] = intval($a['article_fc_base_monthly']);
     $sold_last_month[$a_counter] = intval($a['article_sold_monthly_1']);
     $stock[$a_counter] = intval($a['article_stock']);
     $stock_target[$a_counter] = $obj_product->getDIOHstockTarget($aid);
     $qty_ordered[$a_counter] = intval($a['article_orders_qty']);
     $qty_missing[$a_counter] = $stock_target[$a_counter] - ($stock[$a_counter] + $qty_ordered[$a_counter]);
     if ($qty_missing[$a_counter] < 0) {
         $qty_missing[$a_counter] = 0;
     }
     $levelling_target[$a_counter] = $fc->calcLevellingTarget($fc_base_daily, $current_month);
     $count_levelling_orders = $class_do->countOrdersLevellingDetailsByArticle($pid, $aid);
     $count_levelling_orders_today = $class_do->countOrdersLevellingByArticleAndDate($pid, $aid, 'today');
     $levelling_orders[$a_counter] = $count_levelling_orders['total'];
         $levelling_orders_real[$mp] = $no_values;
         $levelling_orders_real_ptb[$mp] = $no_values;
         $levelling_orders_real_out[$mp] = $no_values;
         $levelling_orders_real_out_open[$mp] = $no_values;
     }
     if ($mp_value < $month_now) {
         $levelling_orders_forecast[$mp] = $no_values;
         $levelling_target_forecast[$mp] = $no_values;
     } else {
         $levelling_orders_forecast[$mp] = 0;
         $levelling_target_forecast[$mp] = 0;
     }
 }
 foreach ($pids as $pid) {
     $p = new Product($pid);
     $fc_base_daily = $p->getForecastDailyBaseValue();
     foreach ($months as $mp => $mtext) {
         $sales_real[$mp] += $p->getSoldMonthlyExcludingPromotionOrders($year, $mp);
         if (intval($mp) >= date('n')) {
             $sales_forecast[$mp] += $fc->calcForecastMonthly($fc_base_daily, $mp);
             $levelling_orders_forecast[$mp] += $fc->calcLevellingSplit($fc_base_daily, $mp);
             $levelling_target_forecast[$mp] += $fc->calcLevellingTarget($fc_base_daily, $mp);
         }
     }
 }
 $result = '<div class="draw-table">';
 $result .= '<table border="0" cellpadding="0" cellspacing="0">';
 //THEAD
 $result .= '<thead>';
 $result .= '<tr>';
 $result .= '<th class="w250">Description</th>';