function __construct()
 {
     parent::__construct();
     $this->projectid = JRequest::getInt('p', 0);
     $this->personid = JRequest::getInt('pid', 0);
     $this->teamid = JRequest::getInt('tid', 0);
 }
Example #2
0
 public function __construct()
 {
     parent::__construct();
     $app = JFactory::getApplication();
     $jinput = $app->input;
     $this->projectid = JLHelperFront::stringToInt($jinput->getInt('p', 0));
     $this->personid = JLHelperFront::stringToInt($jinput->getInt('pid', 0));
 }
Example #3
0
 function isContactDataVisible($config_showContactDataOnlyTeamMembers)
 {
     $user = JFactory::getUser();
     $result = true;
     // project admin and editor,see contact always
     if ($config_showContactDataOnlyTeamMembers && !$this->isUserProjectAdminOrEditor($user->id, $this->getProject())) {
         $result = false;
         if ($user->id > 0) {
             // get project_team id to user-id from team-player or team-staff
             $projectTeamIds = JoomleagueModelPerson::_getProjectTeamIds4UserId($user->id);
             $teamplayer = JoomleagueModelPlayer::getTeamPlayer();
             if (isset($teamplayer->projectteam_id)) {
                 $result = in_array($teamplayer->projectteam_id, $projectTeamIds);
             }
         }
     }
     return $result;
 }