public function build($project_id, ProjectUGroup $ugroup)
 {
     $this->id = $project_id . '_' . $ugroup->getId();
     $this->uri = UserGroupRepresentation::ROUTE . '/' . $this->id;
     $this->label = \User_ForgeUGroup::getUserGroupDisplayName($ugroup->getName());
     $this->key = $ugroup->getName();
     $this->users_uri = self::ROUTE . '/' . $this->id . '/users';
 }
 private function getOptions($user_groups, $selected_ids = array())
 {
     $options = '';
     foreach ($user_groups as $user_group) {
         $id = $user_group->getId();
         $selected = in_array($id, $selected_ids) ? 'selected="selected"' : '';
         $options .= '<option value="' . $id . '" ' . $selected . '>';
         $options .= User_ForgeUGroup::getUserGroupDisplayName($user_group->getName());
         $options .= '</option>';
     }
     return $options;
 }