Skip to content

Instantly share code, notes, and snippets.

View neandher's full-sized avatar

Neandher Carlos neandher

  • Vila Velha, Espírito Santo, Brazil
View GitHub Profile
@neandher
neandher / ReputationNotificationSubscriber.php
Last active February 5, 2021 12:48
Exemplos de inscrições em eventos no symfony / api platform
<?php
namespace App\EventSubscriber;
use App\Entity\Reputation;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Security\Core\Security;
use Symfony\Component\HttpKernel\KernelEvents;
use Symfony\Component\HttpKernel\Event\ViewEvent;
@neandher
neandher / FormController.php
Created January 25, 2019 20:13
Felipy Form
<?php
namespace App\Controller;
use App\Entity\Religiao;
use App\Entity\Sociocomportamental;
use App\Form\SociocomportamentalType;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
@neandher
neandher / PaginatedCollection.php
Created April 2, 2016 15:40
KnpUniversity Symfony REST: Using @link with the PaginatedCollection
<?php
namespace AppBundle\Pagination;
use AppBundle\Annotation\Link;
use JMS\Serializer\Annotation as Serializer;
/**
* @Link(
* "self",