public static function groupOrderId() { $doctrine = self::$servicelocator->get('doctrine'); $orderModel = new orderdetailModel($doctrine); $array = $orderModel->groupOrder(); $return = array(); foreach ($array as $item) { $return[$item['orderId']] = $item['count_table']; } return $return; }