Minor: format code

pull/4677/head^2
Angel Fernando Quiroz Campos 2 years ago
parent cbf42874bd
commit c4f16dc835
  1. 18
      src/CoreBundle/Entity/AgendaReminder.php
  2. 1
      src/CoreBundle/Entity/Course.php
  3. 2
      src/CoreBundle/Entity/GradebookCategory.php
  4. 3
      src/CoreBundle/Entity/MessageFeedback.php
  5. 3
      src/CoreBundle/Entity/PortfolioAttachment.php
  6. 4
      src/CoreBundle/Entity/PortfolioComment.php
  7. 6
      src/CoreBundle/Entity/ResourceLink.php
  8. 16
      src/CoreBundle/Entity/ResourceNode.php

@ -19,19 +19,19 @@ class AgendaReminder
#[ORM\Id]
#[ORM\Column(type: 'bigint')]
#[ORM\GeneratedValue(strategy: 'AUTO')]
protected $id;
protected int $id;
#[ORM\Column(type: 'string', name: 'type')]
protected $type;
#[ORM\Column(name: 'type', type: 'string')]
protected string $type;
#[ORM\Column(type: 'integer', name: 'event_id')]
protected $eventId;
#[ORM\Column(name: 'event_id', type: 'integer')]
protected int $eventId;
#[ORM\Column(type: 'dateinterval', name: 'date_interval')]
protected $dateInterval;
#[ORM\Column(name: 'date_interval', type: 'dateinterval')]
protected DateInterval $dateInterval;
#[ORM\Column(type: 'boolean', name: 'sent')]
protected $sent;
#[ORM\Column(name: 'sent', type: 'boolean')]
protected bool $sent;
public function __construct()
{

@ -13,7 +13,6 @@ use ApiPlatform\Metadata\ApiProperty;
use ApiPlatform\Metadata\ApiResource;
use ApiPlatform\Metadata\Get;
use ApiPlatform\Metadata\GetCollection;
use ApiPlatform\Metadata\Link;
use ApiPlatform\Metadata\Post;
use ApiPlatform\Serializer\Filter\PropertyFilter;
use Chamilo\CoreBundle\Entity\Listener\CourseListener;

@ -120,7 +120,7 @@ class GradebookCategory
protected ?int $gradeBooksToValidateInDependence = null;
#[ORM\Column(name: 'allow_skills_by_subcategory', type: 'integer', nullable: true, options: ['default' => 1])]
protected $allowSkillsBySubcategory;
protected ?int $allowSkillsBySubcategory;
public function __construct()
{

@ -8,9 +8,6 @@ namespace Chamilo\CoreBundle\Entity;
use DateTime;
use Doctrine\ORM\Mapping as ORM;
/**
* Class MessageFeedback.
*/
#[ORM\Table(
name: 'message_feedback'
)]

@ -8,9 +8,6 @@ namespace Chamilo\CoreBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* Class PortfolioAttachment.
*/
#[ORM\Table(name: 'portfolio_attachment')]
#[ORM\Entity(repositoryClass: 'Chamilo\\CoreBundle\\Entity\\Repository\\PortfolioAttachmentRepository')]
class PortfolioAttachment

@ -11,9 +11,6 @@ use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
/**
* Class PortfolioComment.
*/
#[ORM\Entity(repositoryClass: PortfolioCommentRepository::class)]
#[ORM\Table(name: 'portfolio_comment')]
#[Gedmo\Tree(type: 'nested')]
@ -76,7 +73,6 @@ class PortfolioComment
#[ORM\Column(type: 'boolean', options: ['default' => false])]
private bool $isTemplate = false;
public function __construct()
{
$this->isImportant = false;

@ -7,14 +7,8 @@ declare(strict_types=1);
namespace Chamilo\CoreBundle\Entity;
use ApiPlatform\Metadata\ApiResource;
use ApiPlatform\Metadata\GetCollection;
use ApiPlatform\Metadata\Link;
use Chamilo\CoreBundle\Traits\TimestampableTypedEntity;
use Chamilo\CourseBundle\Entity\CCalendarEvent;
use Chamilo\CourseBundle\Entity\CDocument;
use Chamilo\CourseBundle\Entity\CGroup;
use Chamilo\CourseBundle\Entity\CTool;
use Chamilo\CourseBundle\Entity\CToolIntro;
use DateTimeInterface;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;

@ -13,7 +13,6 @@ use ApiPlatform\Metadata\ApiResource;
use ApiPlatform\Metadata\Delete;
use ApiPlatform\Metadata\Get;
use ApiPlatform\Metadata\GetCollection;
use ApiPlatform\Metadata\Link;
use ApiPlatform\Metadata\Patch;
use ApiPlatform\Metadata\Put;
use ApiPlatform\Serializer\Filter\PropertyFilter;
@ -21,12 +20,7 @@ use Chamilo\CoreBundle\Entity\Listener\ResourceNodeListener;
use Chamilo\CoreBundle\Repository\ResourceNodeRepository;
use Chamilo\CoreBundle\Traits\TimestampableAgoTrait;
use Chamilo\CoreBundle\Traits\TimestampableTypedEntity;
use Chamilo\CourseBundle\Entity\CCalendarEvent;
use Chamilo\CourseBundle\Entity\CDocument;
use Chamilo\CourseBundle\Entity\CGroup;
use Chamilo\CourseBundle\Entity\CShortcut;
use Chamilo\CourseBundle\Entity\CTool;
use Chamilo\CourseBundle\Entity\CToolIntro;
use DateTime;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
@ -55,19 +49,19 @@ use Symfony\Component\Validator\Constraints as Assert;
new Put(),
new Patch(),
new Delete(),
new GetCollection()
new GetCollection(),
],
normalizationContext: [
'groups' => [
'resource_node:read',
'document:read'
]
'document:read',
],
],
denormalizationContext: [
'groups' => [
'resource_node:write',
'document:write'
]
'document:write',
],
]
)]
#[ApiFilter(filterClass: OrderFilter::class, properties: ['id', 'title', 'resourceFile', 'createdAt', 'updatedAt'])]

Loading…
Cancel
Save