BConnect POS - Reference PHP

SaleItem
in package

Attributes
#[ApiResource]
$operations: [new \ApiPlatform\Metadata\GetCollection(paginationEnabled: true, paginationItemsPerPage: 10, paginationMaximumItemsPerPage: 50, paginationClientItemsPerPage: true, normalizationContext: ['groups' => ['saleItem:read']]), new \ApiPlatform\Metadata\Post(denormalizationContext: ['groups' => ['saleItem:write']])]
#[Entity]
$repositoryClass: \App\Repository\OrderItemRepository::class

Table of Contents

Properties

$created_at  : DateTimeImmutable|null
$id  : int|null
$price  : float|null
$product  : Product|null
$quantity  : int|null
$sale  : Sale|null
$type  : bool|null

Methods

__construct()  : mixed
getCreatedAt()  : DateTimeImmutable|null
getId()  : int|null
getPrice()  : float|null
getProduct()  : Product|null
getQuantity()  : int|null
getSale()  : Sale|null
isType()  : bool|null
setCreatedAt()  : static
setPrice()  : static
setProduct()  : static
setQuantity()  : static
setSale()  : static
setType()  : static

Properties

$created_at

private DateTimeImmutable|null $created_at = null
Attributes
#[Column]

$id

private int|null $id = null
Attributes
#[Column]
#[GeneratedValue]
#[Groups]
['saleItem:read', 'session:read', 'sale:write']
#[Id]

$price

private float|null $price = null
Attributes
#[Column]
#[Groups]
['saleItem:read', 'saleItem:write', 'session:read', 'sale:write']

$product

private Product|null $product = null
Attributes
#[Groups]
['saleItem:read', 'saleItem:write', 'session:read', 'sale:write']
#[JoinColumn]
$nullable: false
#[ManyToOne]

$quantity

private int|null $quantity = null
Attributes
#[Column]
#[Groups]
['saleItem:read', 'saleItem:write', 'session:read', 'sale:write']

$sale

private Sale|null $sale = null
Attributes
#[Groups]
['saleItem:read', 'saleItem:write']
#[JoinColumn]
$nullable: false
#[ManyToOne]
$inversedBy: 'saleItems'

$type

private bool|null $type = null
Attributes
#[Column]
#[Groups]
['saleItem:read', 'saleItem:write', 'session:read', 'sale:write']

Methods

__construct()

public __construct() : mixed

getCreatedAt()

public getCreatedAt() : DateTimeImmutable|null
Return values
DateTimeImmutable|null

getId()

public getId() : int|null
Return values
int|null

getPrice()

public getPrice() : float|null
Return values
float|null

getQuantity()

public getQuantity() : int|null
Return values
int|null

isType()

public isType() : bool|null
Return values
bool|null

setCreatedAt()

public setCreatedAt(DateTimeImmutable $created_at) : static
Parameters
$created_at : DateTimeImmutable
Return values
static

setPrice()

public setPrice(float $price) : static
Parameters
$price : float
Return values
static

setProduct()

public setProduct(Product|null $product) : static
Parameters
$product : Product|null
Return values
static

setQuantity()

public setQuantity(int $quantity) : static
Parameters
$quantity : int
Return values
static

setSale()

public setSale(Sale|null $sale) : static
Parameters
$sale : Sale|null
Return values
static

setType()

public setType(bool $type) : static
Parameters
$type : bool
Return values
static
On this page

Search results