diff options
Diffstat (limited to 'src/Wallabag/CoreBundle/Entity')
-rw-r--r-- | src/Wallabag/CoreBundle/Entity/Entry.php | 83 | ||||
-rw-r--r-- | src/Wallabag/CoreBundle/Entity/TaggingRule.php | 4 |
2 files changed, 60 insertions, 27 deletions
diff --git a/src/Wallabag/CoreBundle/Entity/Entry.php b/src/Wallabag/CoreBundle/Entity/Entry.php index 7276b437..b71c467c 100644 --- a/src/Wallabag/CoreBundle/Entity/Entry.php +++ b/src/Wallabag/CoreBundle/Entity/Entry.php | |||
@@ -122,6 +122,24 @@ class Entry | |||
122 | private $updatedAt; | 122 | private $updatedAt; |
123 | 123 | ||
124 | /** | 124 | /** |
125 | * @var \DateTime | ||
126 | * | ||
127 | * @ORM\Column(name="published_at", type="datetime", nullable=true) | ||
128 | * | ||
129 | * @Groups({"entries_for_user", "export_all"}) | ||
130 | */ | ||
131 | private $publishedAt; | ||
132 | |||
133 | /** | ||
134 | * @var array | ||
135 | * | ||
136 | * @ORM\Column(name="published_by", type="json_array", nullable=true) | ||
137 | * | ||
138 | * @Groups({"entries_for_user", "export_all"}) | ||
139 | */ | ||
140 | private $publishedBy; | ||
141 | |||
142 | /** | ||
125 | * @ORM\OneToMany(targetEntity="Wallabag\AnnotationBundle\Entity\Annotation", mappedBy="entry", cascade={"persist", "remove"}) | 143 | * @ORM\OneToMany(targetEntity="Wallabag\AnnotationBundle\Entity\Annotation", mappedBy="entry", cascade={"persist", "remove"}) |
126 | * @ORM\JoinTable | 144 | * @ORM\JoinTable |
127 | * | 145 | * |
@@ -175,15 +193,6 @@ class Entry | |||
175 | private $previewPicture; | 193 | private $previewPicture; |
176 | 194 | ||
177 | /** | 195 | /** |
178 | * @var bool | ||
179 | * | ||
180 | * @ORM\Column(name="is_public", type="boolean", nullable=true, options={"default" = false}) | ||
181 | * | ||
182 | * @Groups({"export_all"}) | ||
183 | */ | ||
184 | private $isPublic; | ||
185 | |||
186 | /** | ||
187 | * @var string | 196 | * @var string |
188 | * | 197 | * |
189 | * @ORM\Column(name="http_status", type="string", length=3, nullable=true) | 198 | * @ORM\Column(name="http_status", type="string", length=3, nullable=true) |
@@ -532,22 +541,6 @@ class Entry | |||
532 | } | 541 | } |
533 | 542 | ||
534 | /** | 543 | /** |
535 | * @return bool | ||
536 | */ | ||
537 | public function isPublic() | ||
538 | { | ||
539 | return $this->isPublic; | ||
540 | } | ||
541 | |||
542 | /** | ||
543 | * @param bool $isPublic | ||
544 | */ | ||
545 | public function setIsPublic($isPublic) | ||
546 | { | ||
547 | $this->isPublic = $isPublic; | ||
548 | } | ||
549 | |||
550 | /** | ||
551 | * @return ArrayCollection<Tag> | 544 | * @return ArrayCollection<Tag> |
552 | */ | 545 | */ |
553 | public function getTags() | 546 | public function getTags() |
@@ -701,4 +694,44 @@ class Entry | |||
701 | 694 | ||
702 | return $this; | 695 | return $this; |
703 | } | 696 | } |
697 | |||
698 | /** | ||
699 | * @return \Datetime | ||
700 | */ | ||
701 | public function getPublishedAt() | ||
702 | { | ||
703 | return $this->publishedAt; | ||
704 | } | ||
705 | |||
706 | /** | ||
707 | * @param \Datetime $publishedAt | ||
708 | * | ||
709 | * @return Entry | ||
710 | */ | ||
711 | public function setPublishedAt(\Datetime $publishedAt) | ||
712 | { | ||
713 | $this->publishedAt = $publishedAt; | ||
714 | |||
715 | return $this; | ||
716 | } | ||
717 | |||
718 | /** | ||
719 | * @return string | ||
720 | */ | ||
721 | public function getPublishedBy() | ||
722 | { | ||
723 | return $this->publishedBy; | ||
724 | } | ||
725 | |||
726 | /** | ||
727 | * @param string $publishedBy | ||
728 | * | ||
729 | * @return Entry | ||
730 | */ | ||
731 | public function setPublishedBy($publishedBy) | ||
732 | { | ||
733 | $this->publishedBy = $publishedBy; | ||
734 | |||
735 | return $this; | ||
736 | } | ||
704 | } | 737 | } |
diff --git a/src/Wallabag/CoreBundle/Entity/TaggingRule.php b/src/Wallabag/CoreBundle/Entity/TaggingRule.php index 72651b19..84e11e26 100644 --- a/src/Wallabag/CoreBundle/Entity/TaggingRule.php +++ b/src/Wallabag/CoreBundle/Entity/TaggingRule.php | |||
@@ -31,7 +31,7 @@ class TaggingRule | |||
31 | * @Assert\Length(max=255) | 31 | * @Assert\Length(max=255) |
32 | * @RulerZAssert\ValidRule( | 32 | * @RulerZAssert\ValidRule( |
33 | * allowed_variables={"title", "url", "isArchived", "isStared", "content", "language", "mimetype", "readingTime", "domainName"}, | 33 | * allowed_variables={"title", "url", "isArchived", "isStared", "content", "language", "mimetype", "readingTime", "domainName"}, |
34 | * allowed_operators={">", "<", ">=", "<=", "=", "is", "!=", "and", "not", "or", "matches"} | 34 | * allowed_operators={">", "<", ">=", "<=", "=", "is", "!=", "and", "not", "or", "matches", "notmatches"} |
35 | * ) | 35 | * ) |
36 | * @ORM\Column(name="rule", type="string", nullable=false) | 36 | * @ORM\Column(name="rule", type="string", nullable=false) |
37 | */ | 37 | */ |
@@ -87,7 +87,7 @@ class TaggingRule | |||
87 | /** | 87 | /** |
88 | * Set tags. | 88 | * Set tags. |
89 | * | 89 | * |
90 | * @param array<string> $tags | 90 | * @param array <string> $tags |
91 | * | 91 | * |
92 | * @return TaggingRule | 92 | * @return TaggingRule |
93 | */ | 93 | */ |