Minor - format entity annotations

pull/3844/head
Julio Montoya 4 years ago
parent b119e2443f
commit 67e16cafe5
  1. 4
      src/CourseBundle/Entity/CCalendarEvent.php
  2. 5
      src/CourseBundle/Entity/CCalendarEventRepeat.php
  3. 2
      src/CourseBundle/Entity/CLp.php
  4. 14
      src/CourseBundle/Entity/CQuizQuestion.php
  5. 2
      src/CourseBundle/Entity/CWikiMailcue.php
  6. 2
      src/CourseBundle/Repository/CShortcutRepository.php
  7. 2
      src/CourseBundle/Settings/SettingsCourseManager.php

@ -284,7 +284,7 @@ class CCalendarEvent extends AbstractResource implements ResourceInterface
} }
/** /**
* @return Collection|CCalendarEventAttachment[] * @return Collection
*/ */
public function getAttachments() public function getAttachments()
{ {
@ -292,7 +292,7 @@ class CCalendarEvent extends AbstractResource implements ResourceInterface
} }
/** /**
* @param Collection|CCalendarEventAttachment[] $attachments * @param Collection $attachments
*/ */
public function setAttachments($attachments): self public function setAttachments($attachments): self
{ {

@ -142,4 +142,9 @@ class CCalendarEventRepeat
{ {
return $this->calDays; return $this->calDays;
} }
public function getEvent(): CCalendarEvent
{
return $this->event;
}
} }

@ -16,8 +16,6 @@ use Gedmo\Mapping\Annotation as Gedmo;
use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\Validator\Constraints as Assert;
/** /**
* CLp.
*
* @ORM\Table( * @ORM\Table(
* name="c_lp" * name="c_lp"
* ) * )

@ -90,8 +90,12 @@ class CQuizQuestion extends AbstractResource implements ResourceInterface
* *
* @ORM\ManyToMany(targetEntity="Chamilo\CourseBundle\Entity\CQuizQuestionCategory", inversedBy="questions") * @ORM\ManyToMany(targetEntity="Chamilo\CourseBundle\Entity\CQuizQuestionCategory", inversedBy="questions")
* @ORM\JoinTable(name="c_quiz_question_rel_category", * @ORM\JoinTable(name="c_quiz_question_rel_category",
* joinColumns={@ORM\JoinColumn(name="category_id", referencedColumnName="iid")}, * joinColumns={
* inverseJoinColumns={@ORM\JoinColumn(name="question_id", referencedColumnName="iid")} * @ORM\JoinColumn(name="category_id", referencedColumnName="iid")
* },
* inverseJoinColumns={
* @ORM\JoinColumn(name="question_id", referencedColumnName="iid")
* }
* ) * )
*/ */
protected $categories; protected $categories;
@ -205,9 +209,6 @@ class CQuizQuestion extends AbstractResource implements ResourceInterface
return $this->description; return $this->description;
} }
/**
* Set ponderation.
*/
public function setPonderation(float $ponderation): self public function setPonderation(float $ponderation): self
{ {
$this->ponderation = $ponderation; $this->ponderation = $ponderation;
@ -225,9 +226,6 @@ class CQuizQuestion extends AbstractResource implements ResourceInterface
return $this->ponderation; return $this->ponderation;
} }
/**
* Set position.
*/
public function setPosition(int $position): self public function setPosition(int $position): self
{ {
$this->position = $position; $this->position = $position;

@ -9,8 +9,6 @@ namespace Chamilo\CourseBundle\Entity;
use Doctrine\ORM\Mapping as ORM; use Doctrine\ORM\Mapping as ORM;
/** /**
* CWikiMailcue.
*
* @ORM\Table( * @ORM\Table(
* name="c_wiki_mailcue", * name="c_wiki_mailcue",
* indexes={ * indexes={

@ -34,7 +34,7 @@ final class CShortcutRepository extends ResourceRepository
return $this->findOneBy($criteria); return $this->findOneBy($criteria);
} }
public function addShortCut(AbstractResource $resource, ResourceInterface $parent, Course $course, Session $session = null): ?CShortcut public function addShortCut(AbstractResource $resource, ResourceInterface $parent, Course $course, Session $session = null): CShortcut
{ {
$shortcut = $this->getShortcutFromResource($resource); $shortcut = $this->getShortcutFromResource($resource);

@ -51,7 +51,7 @@ class SettingsCourseManager extends SettingsManager
$schema->buildSettings($settingsBuilder); $schema->buildSettings($settingsBuilder);
// Remove unknown settings' parameters (e.g. From a previous version of the settings schema) // Remove unknown settings' parameters (e.g. From a previous version of the settings schema)
if (true === $ignoreUnknown) { if ($ignoreUnknown) {
foreach ($parameters as $name => $value) { foreach ($parameters as $name => $value) {
if (!$settingsBuilder->isDefined($name)) { if (!$settingsBuilder->isDefined($name)) {
unset($parameters[$name]); unset($parameters[$name]);

Loading…
Cancel
Save