<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use ApiPlatform\Core\Annotation\ApiResource;
use App\Repository\UserAcademicTitleRepository;
use Symfony\Component\Serializer\Annotation\Groups;
/**
* @ApiResource(
* attributes={"security"="is_granted('ROLE_SUPER_ADMIN')"},
* normalizationContext={"groups"={"UserAcademicTitle:Read"}, "skip_null_values"=false},
* denormalizationContext={"groups"={"UserAcademicTitle:Write"}},
* collectionOperations={
* "post",
* "get"
* },
* itemOperations={
* "get"
* }
* )
* @ORM\Entity(repositoryClass=UserAcademicTitleRepository::class)
* @ORM\Table(name="rel_user_academic_title")
*/
class UserAcademicTitle
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="integer")
* @Groups({"User:Imp", "User:Read", "User:Get-Admin","User:Write","User:Me", "User:Attendee-List", "User:Attendee-List-O", "User:Change-Profile", "User:Get-Limited","Session:Select","VideoGalleryHistory:Read" , "JobQueue:Read", "AccessLog:Read", "EventLog:Read", "WatchTime:Read", "CommonComment:Read", "CommonCommentLike:Read", "SessionQuestionLike:Read", "NewsfeedLike:Read", "SessionReaction:Read", "SessionComment:Read", "Session:Read", "DocFile:Read", "Session:PRead", "Conference:Read", "Conference:PRead", "ElCourse:PRead", "Session:Agenda", "Newsfeed:Read", "NewsfeedComment:Read", "ChatThread:Read", "ChatMessage:Read", "Session:VideoLibrary", "VoteResult:Read", "VoteResult:Exp", "SessionQuestion:Read", "Meeting:Read", "MeetingBooking:Read", "Import:Read", "SessionQuestion:Exp", "VoucherCode:Read", "ElCourse:Read", "ElTask:Read", "VideoLibrary:Read", "ElExamAttempt:Read", "ElExamAnswer:Read", "ElCourseJoin:Read", "ElTaskAttempt:Read", "ElExamAttempt:Read", "VideoGallery:Read", "VideoGallery:Read-Public", "VideoGallery:PRead", "SurveyResult:Read", "User:PRead", "User:PSRead", "Certificate:Read", "ElLession:Detail", "User:Assign-List", "Company:Read", "ElCourseRating:Read", "User:Get-Open"})
*/
private $ord;
/**
* @ORM\ManyToOne(targetEntity=AcademicTitle::class)
* @ORM\JoinColumn(nullable=false, onDelete="CASCADE")
* @Groups({"User:EL", "User:Imp", "User:Read", "User:Get-Admin","User:Write","User:Me", "User:Attendee-List", "User:Attendee-List-O", "User:Change-Profile", "User:Get-Limited","Session:Select","VideoGalleryHistory:Read" , "JobQueue:Read", "AccessLog:Read", "EventLog:Read", "WatchTime:Read", "CommonComment:Read", "CommonCommentLike:Read", "SessionQuestionLike:Read", "NewsfeedLike:Read", "SessionReaction:Read", "SessionComment:Read", "Session:Read", "DocFile:Read", "Session:PRead", "Conference:Read", "Conference:PRead", "ElCourse:PRead", "Session:Agenda", "Newsfeed:Read", "NewsfeedComment:Read", "ChatThread:Read", "ChatMessage:Read", "Session:VideoLibrary", "VoteResult:Read", "VoteResult:Exp", "SessionQuestion:Read", "Meeting:Read", "MeetingBooking:Read", "Import:Read", "SessionQuestion:Exp", "VoucherCode:Read", "ElCourse:Read", "ElTask:Read", "VideoLibrary:Read", "ElExamAttempt:Read", "ElExamAnswer:Read", "ElCourseJoin:Read", "ElTaskAttempt:Read", "ElExamAttempt:Read", "VideoGallery:Read", "VideoGallery:Read-Public", "VideoGallery:PRead", "SurveyResult:Read", "User:PRead", "User:PSRead", "Certificate:Read", "ElLession:Detail", "User:Assign-List", "Company:Read", "ElCourseRating:Read", "User:Get-Open"})
*/
private $academicTitle;
/**
* @ORM\ManyToOne(targetEntity=User::class, inversedBy="userAcademicTitles")
* @ORM\JoinColumn(nullable=false, onDelete="CASCADE")
*/
private $user;
public function getId(): ?int
{
return $this->id;
}
public function getOrd(): ?int
{
return $this->ord;
}
public function setOrd(int $ord): self
{
$this->ord = $ord;
return $this;
}
public function getAcademicTitle(): ?AcademicTitle
{
return $this->academicTitle;
}
public function setAcademicTitle(?AcademicTitle $academicTitle): self
{
$this->academicTitle = $academicTitle;
return $this;
}
public function getUser(): ?User
{
return $this->user;
}
public function setUser(?User $user): self
{
$this->user = $user;
return $this;
}
}