您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

95 行
2.0KB

  1. <?php
  2. namespace Lc\SovBundle\Model\Ticket;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Gedmo\Mapping\Annotation as Gedmo;
  5. use Lc\SovBundle\Doctrine\EntityInterface;
  6. use Lc\SovBundle\Doctrine\Extension\BlameableNullableTrait;
  7. use Lc\SovBundle\Doctrine\Extension\StatusInterface;
  8. use Lc\SovBundle\Doctrine\Extension\StatusTrait;
  9. use Lc\SovBundle\Doctrine\Pattern\AbstractLightEntity;
  10. /**
  11. * @ORM\MappedSuperclass()
  12. */
  13. abstract class TicketMessageModel extends AbstractLightEntity implements TicketMessageInterface, EntityInterface, StatusInterface
  14. {
  15. use StatusTrait;
  16. /**
  17. * @ORM\Column(type="text")
  18. */
  19. protected $message;
  20. /**
  21. * @ORM\ManyToOne(targetEntity="Lc\SovBundle\Model\Ticket\TicketInterface", inversedBy="ticketMessages")
  22. * @ORM\JoinColumn(nullable=false)
  23. */
  24. protected $ticket;
  25. /**
  26. * @ORM\Column(type="boolean", nullable=true)
  27. */
  28. protected $answerByAdmin;
  29. /**
  30. * @ORM\Column(type="string", length=255, nullable=true)
  31. */
  32. protected $imageFilename;
  33. public function __toString()
  34. {
  35. return $this->message;
  36. }
  37. public function getMessage(): ?string
  38. {
  39. return $this->message;
  40. }
  41. public function setMessage(string $message): self
  42. {
  43. $this->message = $message;
  44. return $this;
  45. }
  46. public function getTicket(): TicketInterface
  47. {
  48. return $this->ticket;
  49. }
  50. public function setTicket(TicketInterface $ticket): self
  51. {
  52. $this->ticket = $ticket;
  53. return $this;
  54. }
  55. public function getAnswerByAdmin(): ?bool
  56. {
  57. return $this->answerByAdmin;
  58. }
  59. public function setAnswerByAdmin(?bool $answerByAdmin): self
  60. {
  61. $this->answerByAdmin = $answerByAdmin;
  62. return $this;
  63. }
  64. public function getImageFilename(): ?string
  65. {
  66. return $this->imageFilename;
  67. }
  68. public function setImageFilename(?string $imageFilename): self
  69. {
  70. $this->imageFilename = $imageFilename;
  71. return $this;
  72. }
  73. }