mirror of
https://forge.chapril.org/tykayn/caisse-bliss
synced 2025-10-09 17:02:47 +02:00
up login
This commit is contained in:
parent
d8c1b7c0f6
commit
d01ecdabba
13 changed files with 198 additions and 25 deletions
|
@ -3,12 +3,17 @@
|
|||
namespace App\Entity;
|
||||
|
||||
use ApiPlatform\Metadata\ApiResource;
|
||||
use ApiPlatform\Metadata\ApiProperty;
|
||||
|
||||
use App\Repository\ProductRepository;
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
use Doctrine\Common\Collections\Collection;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
use App\Filter\UserProductsFilter;
|
||||
use App\DTO\UserDTO;
|
||||
|
||||
#[ApiResource(paginationEnabled: false)]
|
||||
#[UserProductsFilter]
|
||||
#[ORM\Entity(repositoryClass: ProductRepository::class)]
|
||||
class Product
|
||||
{
|
||||
|
@ -30,12 +35,14 @@ class Product
|
|||
* @var Collection<int, GroupOfProducts>
|
||||
*/
|
||||
#[ORM\ManyToMany(targetEntity: GroupOfProducts::class, mappedBy: 'products')]
|
||||
#[ApiProperty(readable: false)]
|
||||
private Collection $groupOfProducts;
|
||||
|
||||
/**
|
||||
* @var Collection<int, Selling>
|
||||
*/
|
||||
#[ORM\ManyToMany(targetEntity: Selling::class, mappedBy: 'products')]
|
||||
#[ApiProperty(readable: false)]
|
||||
private Collection $sellings;
|
||||
|
||||
#[ORM\ManyToOne(inversedBy: 'products')]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue