Internal: Add missing repositoryClass config in entities

pull/5329/head
Angel Fernando Quiroz Campos 1 year ago
parent 6df47b1b19
commit 8fd3d187ff
  1. 3
      src/CoreBundle/Entity/TicketMessageAttachment.php
  2. 4
      src/CourseBundle/Entity/CLpCategory.php
  3. 3
      src/CourseBundle/Entity/CLpItem.php
  4. 3
      src/CourseBundle/Entity/CToolIntro.php

@ -6,12 +6,13 @@ declare(strict_types=1);
namespace Chamilo\CoreBundle\Entity;
use Chamilo\CoreBundle\Repository\Node\TicketMessageAttachmentRepository;
use DateTime;
use Doctrine\ORM\Mapping as ORM;
use Stringable;
#[ORM\Table(name: 'ticket_message_attachments')]
#[ORM\Entity]
#[ORM\Entity(repositoryClass: TicketMessageAttachmentRepository::class)]
class TicketMessageAttachment extends AbstractResource implements ResourceInterface, Stringable
{
#[ORM\Column(name: 'id', type: 'integer')]

@ -10,11 +10,11 @@ use Chamilo\CoreBundle\Entity\AbstractResource;
use Chamilo\CoreBundle\Entity\ResourceInterface;
use Chamilo\CoreBundle\Entity\ResourceShowCourseResourcesInSessionInterface;
use Chamilo\CoreBundle\Entity\User;
use Chamilo\CourseBundle\Repository\CLpCategoryRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\Common\Collections\Criteria;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Sortable\Entity\Repository\SortableRepository;
use Stringable;
use Symfony\Component\Validator\Constraints as Assert;
@ -22,7 +22,7 @@ use Symfony\Component\Validator\Constraints as Assert;
* Learning paths categories.
*/
#[ORM\Table(name: 'c_lp_category')]
#[ORM\Entity(repositoryClass: SortableRepository::class)]
#[ORM\Entity(repositoryClass: CLpCategoryRepository::class)]
class CLpCategory extends AbstractResource implements ResourceInterface, ResourceShowCourseResourcesInSessionInterface, Stringable
{
#[ORM\Column(name: 'iid', type: 'integer')]

@ -6,6 +6,7 @@ declare(strict_types=1);
namespace Chamilo\CourseBundle\Entity;
use Chamilo\CourseBundle\Repository\CLpItemRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
@ -19,7 +20,7 @@ use Symfony\Component\Validator\Constraints as Assert;
#[ORM\Table(name: 'c_lp_item')]
#[ORM\Index(name: 'lp_id', columns: ['lp_id'])]
#[Gedmo\Tree(type: 'nested')]
#[ORM\Entity]
#[ORM\Entity(repositoryClass: CLpItemRepository::class)]
class CLpItem implements Stringable
{
#[ORM\Column(name: 'iid', type: 'integer')]

@ -17,6 +17,7 @@ use ApiPlatform\Metadata\Put;
use Chamilo\CoreBundle\Entity\AbstractResource;
use Chamilo\CoreBundle\Entity\ResourceInterface;
use Chamilo\CoreBundle\Entity\ResourceShowCourseResourcesInSessionInterface;
use Chamilo\CourseBundle\Repository\CToolIntroRepository;
use Doctrine\ORM\Mapping as ORM;
use Stringable;
use Symfony\Component\Serializer\Annotation\Groups;
@ -25,7 +26,7 @@ use Symfony\Component\Validator\Constraints as Assert;
#[ApiResource(operations: [new Get(security: 'is_granted(\'VIEW\', object)'), new Put(security: 'is_granted(\'EDIT\', object)'), new Delete(security: 'is_granted(\'DELETE\', object)'), new GetCollection(security: 'is_granted(\'ROLE_USER\')'), new Post(securityPostDenormalize: 'is_granted(\'CREATE\', object)')], security: 'is_granted(\'ROLE_ADMIN\') or is_granted(\'ROLE_CURRENT_COURSE_TEACHER\')', denormalizationContext: ['groups' => ['c_tool_intro:write']], normalizationContext: ['groups' => ['c_tool_intro:read']])]
#[ORM\Table(name: 'c_tool_intro')]
#[ORM\Entity]
#[ORM\Entity(repositoryClass: CToolIntroRepository::class)]
#[ApiFilter(filterClass: SearchFilter::class, properties: ['courseTool' => 'exact'])]
class CToolIntro extends AbstractResource implements ResourceInterface, ResourceShowCourseResourcesInSessionInterface, Stringable
{

Loading…
Cancel
Save