} $udt_obj->Save(); } $i++; } } Redirect::Page(URLBuilder::getURL(array('user_id' => $user_id, 'filter_date' => $filter_date), 'UserDateTotalList.php')); break; default: if ((!isset($user_date_id) or isset($user_date_id) and $user_date_id == '') and $user_id != '' and $filter_date != '') { Debug::Text('User Date ID not passed, inserting one.', __FILE__, __LINE__, __METHOD__, 10); $user_date_id = UserDateFactory::findOrInsertUserDate($user_id, $filter_date); } if ($user_date_id != '') { $udtlf = new UserDateTotalListFactory(); $udtlf->getByUserDateIDAndStatusAndType($user_date_id, array(10, 20, 30), array(10, 20, 30, 40, 100), $current_user_prefs->getItemsPerPage(), $page, NULL, $sort_array); $pager = new Pager($udtlf); $blf = new BranchListFactory(); $branch_options = $blf->getByCompanyIdArray($current_company->getId()); $dlf = new DepartmentListFactory(); $department_options = $dlf->getByCompanyIdArray($current_company->getId()); //Absence policies $otplf = new AbsencePolicyListFactory(); $absence_policy_options = $otplf->getByCompanyIDArray($current_company->getId(), TRUE); //Overtime policies $otplf = new OverTimePolicyListFactory(); $over_time_policy_options = $otplf->getByCompanyIDArray($current_company->getId(), TRUE); //Premium policies $pplf = new PremiumPolicyListFactory(); $premium_policy_options = $pplf->getByCompanyIDArray($current_company->getId(), TRUE); $job_options = array();