Пример #1
0
 protected function ViewPilotDetails()
 {
     //This is for the main tab
     $this->set('pilotinfo', PilotData::GetPilotData($this->get->pilotid));
     $this->set('customfields', PilotData::GetFieldData($this->get->pilotid, true));
     $this->set('allawards', AwardsData::GetPilotAwards($this->get->pilotid));
     $this->set('pireps', PIREPData::GetAllReportsForPilot($this->get->pilotid));
     $this->set('countries', Countries::getAllCountries());
     $this->SetGroupsData($this->get->pilotid);
     // For the PIREP list
     $this->set('pending', false);
     $this->set('load', 'pilotpireps');
     $this->render('pilots_detailtabs.tpl');
 }
Пример #2
0
 public function editprofile()
 {
     if (!Auth::LoggedIn()) {
         $this->set('message', 'You must be logged in to access this feature!');
         $this->render('core_error.tpl');
         return;
     }
     $this->set('userinfo', Auth::$userinfo);
     $this->set('customfields', PilotData::GetFieldData(Auth::$pilotid, true));
     $this->set('bgimages', PilotData::GetBackgroundImages());
     $this->set('countries', Countries::getAllCountries());
     $this->set('pilotcode', PilotData::GetPilotCode(Auth::$userinfo->code, Auth::$userinfo->pilotid));
     $this->render('profile_edit.tpl');
 }
Пример #3
0
 /**
  * PilotAdmin::ViewPilotDetails()
  * 
  * @return
  */
 protected function ViewPilotDetails()
 {
     //This is for the main tab
     if (PilotGroups::group_has_perm(Auth::$usergroups, EDIT_PILOTS) || PilotGroups::group_has_perm(Auth::$usergroups, EDIT_GROUPS) || PilotGroups::group_has_perm(Auth::$usergroups, EDIT_AWARDS) || PilotGroups::group_has_perm(Auth::$usergroups, MODERATE_PIREPS)) {
         $this->set('pilotinfo', PilotData::GetPilotData($this->get->pilotid));
         $this->set('customfields', PilotData::GetFieldData($this->get->pilotid, true));
         $this->set('allawards', AwardsData::GetPilotAwards($this->get->pilotid));
         $this->set('pireps', PIREPData::GetAllReportsForPilot($this->get->pilotid));
         $this->set('countries', Countries::getAllCountries());
         $this->SetGroupsData($this->get->pilotid);
         // For the PIREP list
         $this->set('pending', false);
         $this->set('load', 'pilotpireps');
         $this->render('pilots_detailtabs.php');
     } else {
         Debug::showCritical('Unauthorized access - Invalid Permissions.');
         die;
     }
 }