function renderTraining()
{
    $instructors = QMModel::getInstructors(get_the_id());
    $training = QMModel::getTrainingCourses($instructors);
    $designCourses = array();
    $teachingCourses = array();
    $designCount = 0;
    $teachingCount = 0;
    if (empty($instructors)) {
        return;
    }
    $training = QMModel::getTrainingCourses($instructors);
    if (empty($training)) {
        return;
    }
    $atcCourses = $training["atc"];
    $designCourse = "Designing a Quality Online Course";
    if (isset($atcCourses[$designCourse])) {
        $designCourses = $atcCourses[$designCourse];
        //              $designCount = count($designCourses);
        //  print_r($designCourses);
        if (!empty($designCourses)) {
            renderTrainingTable($designCourses, 'Faculty that completed the Designing a Quality Online Course', 'design');
        }
    }
    $teachingCourse = "Teaching a Quality Online Course";
    if (isset($atcCourses[$teachingCourse])) {
        $teachingCourses = $atcCourses[$teachingCourse];
        //                $teachingCount = count($teachingCourses);
        if (!empty($teachingCourses)) {
            renderTrainingTable($teachingCourses, 'Faculty that completed the Teaching a Quality Online Course', 'teaching');
        }
    }
}
 static function getDepartmentsData()
 {
     //	echo "Get Departments Data";
     //	echo date("m-d-Y H:i:s.u");
     //	$instructors = QMModel::getInstructors();
     //	$courses = QMModel::getCourses();
     //print_r($instructors);
     //print_r($courses);
     $posts_array = get_posts(array('post_type' => 'department', 'posts_per_page' => -1, 'cache_results' => false));
     //	echo "======Departments======";
     //	print_r($posts_array);
     $departments = array();
     foreach ($posts_array as $department) {
         $dept = new Department();
         $courseReviews = QMModel::fastGetCourses($department->ID, false);
         $dept->reviews = $courseReviews["all"];
         $dept->internalReviews = $courseReviews["internal"];
         $dept->externalReviews = $courseReviews["external"];
         $dept->ID = $department->ID;
         $dept->name = $department->post_title;
         $dept->instructors = QMModel::getInstructors($department->ID);
         if (!empty($dept->instructors)) {
             $dept->training = QMModel::getTrainingCourses($dept->instructors);
         }
         $departments[] = $dept;
     }
     return $departments;
 }
// $trainingCount = getTrainingCoursesCount();
/**Internal*/
$coursesCount = QMModel::getReviewedCoursesCount();
$intCount = $coursesCount["internal"];
/**External*/
$extCount = $coursesCount["external"];
$atcTrainingData = QMModel::getTrainingData(false, 'ATC');
$qmTrainingData = QMModel::getTrainingData(false, 'QM');
/**QM Training */
$qmCount = count($qmTrainingData);
/**ATC Training */
$atcCount = count($atcTrainingData);
/**All Revieved Courses*/
$courses = QMModel::getReviewedCourses();
/**All Training Courses*/
$training = QMModel::getTrainingCourses();
/**Internal*/
$int = $courses["internal"];
/**External*/
$ext = $courses["external"];
/**QM Training */
$qm = $training["qm"];
/**ATC Training */
$atc = $training["atc"];
//  function testGetDepartments(){
// 	 $array = QMModel::getDepartmentsData();
// 	 echo " ".count($array);
// 	 return array;
//  }
function testGetInstructors($id)
{