EC-CUBE4 APIドキュメント

ProductClass extends AbstractEntity

ProductClass

Tags
ORM\Table

(name="dtb_product_class", indexes={@ORM\Index (name="dtb_product_class_price02_idx", columns={"price02"}), @ORM\Index(name="dtb_product_class_stock_stock_unlimited_idx", columns={"stock", "stock_unlimited"})})

ORM\InheritanceType

("SINGLE_TABLE")

ORM\DiscriminatorColumn

(name="discriminator_type", type="string", length=255)

ORM\HasLifecycleCallbacks

()

ORM\Entity

(repositoryClass="Eccube\Repository\ProductClassRepository")

Table of Contents

$price01_inc_tax
$price02_inc_tax
$tax_rate
$id int
$code string|null
$stock string|null
$stock_unlimited bool
$sale_limit string|null
$price01 string|null
$price02 string
$delivery_fee string|null
$visible bool
$create_date DateTime
$update_date DateTime
$currency_code string|null
$point_rate string
$ProductStock ProductStock
$TaxRule TaxRule
$Product Product
$SaleType SaleType
$ClassCategory1 ClassCategory
$ClassCategory2 ClassCategory
$DeliveryDuration DeliveryDuration
$Creator Member
$AnnotationReader
formattedProductName() 商品規格名を含めた商品名を返す. string
isEnable() Is Enable bool
setPrice01IncTax() Set price01 IncTax ProductClass
getPrice01IncTax() Get price01 IncTax string
setPrice02IncTax() Set price02 IncTax ProductClass
getPrice02IncTax() Get price02 IncTax string
getStockFind() Get StockFind bool
setTaxRate() Set tax_rate ProductClass
getTaxRate() Get tax_rate bool
hasClassCategory1() Has ClassCategory1 bool
hasClassCategory2() Has ClassCategory1 bool
__clone() mixed
getId() Get id. int
setCode() Set code. ProductClass
getCode() Get code. string|null
setStock() Set stock. ProductClass
getStock() Get stock. string|null
setStockUnlimited() Set stockUnlimited. ProductClass
isStockUnlimited() Get stockUnlimited. bool
setSaleLimit() Set saleLimit. ProductClass
getSaleLimit() Get saleLimit. string|null
setPrice01() Set price01. ProductClass
getPrice01() Get price01. string|null
setPrice02() Set price02. ProductClass
getPrice02() Get price02. string
setDeliveryFee() Set deliveryFee. ProductClass
getDeliveryFee() Get deliveryFee. string|null
isVisible() bool
setVisible() ProductClass
setCreateDate() Set createDate. ProductClass
getCreateDate() Get createDate. DateTime
setUpdateDate() Set updateDate. ProductClass
getUpdateDate() Get updateDate. DateTime
getCurrencyCode() Get currencyCode. string
setCurrencyCode() Set currencyCode. $this
setProductStock() Set productStock. ProductClass
getProductStock() Get productStock. ProductStock|null
setTaxRule() Set taxRule. ProductClass
getTaxRule() Get taxRule. TaxRule|null
setProduct() Set product. ProductClass
getProduct() Get product. Product|null
setSaleType() Set saleType. ProductClass
getSaleType() Get saleType. SaleType|null
setClassCategory1() Set classCategory1. ProductClass
getClassCategory1() Get classCategory1. ClassCategory|null
setClassCategory2() Set classCategory2. ProductClass
getClassCategory2() Get classCategory2. ClassCategory|null
setDeliveryDuration() Set deliveryDuration. ProductClass
getDeliveryDuration() Get deliveryDuration. DeliveryDuration|null
setCreator() Set creator. ProductClass
getCreator() Get creator. Member|null
setPointRate() Set pointRate ProductClass
getPointRate() Get pointRate string
offsetExists() mixed
offsetSet() mixed
offsetGet() mixed
offsetUnset() mixed
setPropertiesFromArray() 引数の連想配列を元にプロパティを設定します. mixed
toArray() Convert to associative array. array
toNormalizedArray() Convert to associative array, and normalize to association properties. array
toJSON() Convert to JSON. string
toXML() Convert to XML. string
copyProperties() コピー元のオブジェクトのフィールド名を指定して、同名のフィールドに値をコピー AbstractEntity
setAnnotationReader() Set AnnotationReader. AbstractEntity
getAnnotationReader() Get AnnotationReader. Reader
getEntityIdentifierAsArray() Convert to Entity of Identity value to associative array. array

Properties

$id

private int $id
Tags
ORM\Column

(name="id", type="integer", options={"unsigned":true})

ORM\Id
ORM\GeneratedValue

(strategy="IDENTITY")

$code

private string|null $code
Tags
ORM\Column

(name="product_code", type="string", length=255, nullable=true)

$stock

private string|null $stock
Tags
ORM\Column

(name="stock", type="decimal", precision=10, scale=0, nullable=true)

$stock_unlimited

private bool $stock_unlimited = false
Tags
ORM\Column

(name="stock_unlimited", type="boolean", options={"default":false})

$sale_limit

private string|null $sale_limit
Tags
ORM\Column

(name="sale_limit", type="decimal", precision=10, scale=0, nullable=true, options={"unsigned":true})

$price01

private string|null $price01
Tags
ORM\Column

(name="price01", type="decimal", precision=12, scale=2, nullable=true)

$price02

private string $price02
Tags
ORM\Column

(name="price02", type="decimal", precision=12, scale=2)

$delivery_fee

private string|null $delivery_fee
Tags
ORM\Column

(name="delivery_fee", type="decimal", precision=12, scale=2, nullable=true, options={"unsigned":true})

$visible

private bool $visible
Tags
ORM\Column

(name="visible", type="boolean", options={"default":true})

$create_date

private DateTime $create_date
Tags
ORM\Column

(name="create_date", type="datetimetz")

$update_date

private DateTime $update_date
Tags
ORM\Column

(name="update_date", type="datetimetz")

$currency_code

private string|null $currency_code
Tags
ORM\Column

(name="currency_code", type="string", nullable=true)

$point_rate

private string $point_rate
Tags
ORM\Column

(name="point_rate", type="decimal", precision=10, scale=0, options={"unsigned":true}, nullable=true)

$ProductStock

private ProductStock $ProductStock
Tags
ORM\OneToOne

(targetEntity="Eccube\Entity\ProductStock", mappedBy="ProductClass", cascade={"persist","remove"})

$TaxRule

private TaxRule $TaxRule
Tags
ORM\OneToOne

(targetEntity="Eccube\Entity\TaxRule", mappedBy="ProductClass", cascade={"persist","remove"})

$Product

private Product $Product
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\Product", inversedBy="ProductClasses")

ORM\JoinColumns

({ @ORM\JoinColumn(name="product_id", referencedColumnName="id") })

$SaleType

private SaleType $SaleType
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\Master\SaleType")

ORM\JoinColumns

({ @ORM\JoinColumn(name="sale_type_id", referencedColumnName="id") })

$ClassCategory1

private ClassCategory $ClassCategory1
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\ClassCategory")

ORM\JoinColumns

({ @ORM\JoinColumn(name="class_category_id1", referencedColumnName="id", nullable=true) })

$ClassCategory2

private ClassCategory $ClassCategory2
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\ClassCategory")

ORM\JoinColumns

({ @ORM\JoinColumn(name="class_category_id2", referencedColumnName="id", nullable=true) })

$DeliveryDuration

private DeliveryDuration $DeliveryDuration
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\DeliveryDuration")

ORM\JoinColumns

({ @ORM\JoinColumn(name="delivery_duration_id", referencedColumnName="id") })

$Creator

private Member $Creator
Tags
ORM\ManyToOne

(targetEntity="Eccube\Entity\Member")

ORM\JoinColumns

({ @ORM\JoinColumn(name="creator_id", referencedColumnName="id") })

Methods

formattedProductName()

商品規格名を含めた商品名を返す.

public formattedProductName( ) : string
Return values
string

isEnable()

Is Enable

public isEnable( ) : bool
Tags
deprecated
Return values
bool

getPrice01IncTax()

Get price01 IncTax

public getPrice01IncTax( ) : string
Return values
string

getPrice02IncTax()

Get price02 IncTax

public getPrice02IncTax( ) : string
Return values
string

getStockFind()

Get StockFind

public getStockFind( ) : bool
Return values
bool

getTaxRate()

Get tax_rate

public getTaxRate( ) : bool
Return values
bool

hasClassCategory1()

Has ClassCategory1

public hasClassCategory1( ) : bool
Return values
bool

hasClassCategory2()

Has ClassCategory1

public hasClassCategory2( ) : bool
Return values
bool

__clone()

public __clone( ) : mixed
Return values
mixed

getId()

Get id.

public getId( ) : int
Return values
int

getCode()

Get code.

public getCode( ) : string|null
Return values
string|null

getStock()

Get stock.

public getStock( ) : string|null
Return values
string|null

isStockUnlimited()

Get stockUnlimited.

public isStockUnlimited( ) : bool
Return values
bool

getSaleLimit()

Get saleLimit.

public getSaleLimit( ) : string|null
Return values
string|null

getPrice01()

Get price01.

public getPrice01( ) : string|null
Return values
string|null

getPrice02()

Get price02.

public getPrice02( ) : string
Return values
string

setDeliveryFee()

Set deliveryFee.

public setDeliveryFee( [ $deliveryFee : string|null = null ] ) : ProductClass
Parameters
$deliveryFee : string|null = null
Return values
ProductClass

getDeliveryFee()

Get deliveryFee.

public getDeliveryFee( ) : string|null
Return values
string|null

isVisible()

public isVisible( ) : bool
Return values
bool

getCreateDate()

Get createDate.

public getCreateDate( ) : DateTime
Return values
DateTime

getUpdateDate()

Get updateDate.

public getUpdateDate( ) : DateTime
Return values
DateTime

getCurrencyCode()

Get currencyCode.

public getCurrencyCode( ) : string
Return values
string

setCurrencyCode()

Set currencyCode.

public setCurrencyCode( [ $currencyCode : string|null = null ] ) : $this
Parameters
$currencyCode : string|null = null
Return values
$this

getPointRate()

Get pointRate

public getPointRate( ) : string
Return values
string

offsetExists()

public offsetExists( $offset : mixed ) : mixed
Parameters
$offset : mixed
Return values
mixed

offsetSet()

public offsetSet( $offset : mixed , $value : mixed ) : mixed
Parameters
$offset : mixed
$value : mixed
Return values
mixed

offsetGet()

public offsetGet( $offset : mixed ) : mixed
Parameters
$offset : mixed
Return values
mixed

offsetUnset()

public offsetUnset( $offset : mixed ) : mixed
Parameters
$offset : mixed
Return values
mixed

setPropertiesFromArray()

引数の連想配列を元にプロパティを設定します.

public setPropertiesFromArray( $arrProps : array [, $excludeAttribute : string[] = [] ] [, $parentClass : ReflectionClass = null ] ) : mixed

DBから取り出した連想配列を, プロパティへ設定する際に使用します.

Parameters
$arrProps : array

プロパティの情報を格納した連想配列

$excludeAttribute : string[] = []

除外したいフィールド名の配列

$parentClass : ReflectionClass = null

親のクラス. 本メソッドの内部的に使用します.

Return values
mixed

toArray()

Convert to associative array.

public toArray( [ $excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader'] ] [, $parentClass : ReflectionClass = null ] ) : array

Symfony Serializer Component is expensive, and hard to implementation. Use for encoder only.

Parameters
$excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader']

Array of field names to exclusion.

$parentClass : ReflectionClass = null

parent class. Use internally of this method..

Return values
array

toNormalizedArray()

Convert to associative array, and normalize to association properties.

public toNormalizedArray( [ $excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader'] ] ) : array

The type conversion such as:

  • Datetime :: W3C datetime format string
  • AbstractEntity :: associative array such as [id => value]
  • PersistentCollection :: associative array of [[id => value], [id => value], ...]
Parameters
$excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader']

Array of field names to exclusion.

Return values
array

toJSON()

Convert to JSON.

public toJSON( [ $excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader'] ] ) : string
Parameters
$excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader']

Array of field names to exclusion.

Return values
string

toXML()

Convert to XML.

public toXML( [ $excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader'] ] ) : string
Parameters
$excludeAttribute : array = ['__initializer__', '__cloner__', '__isInitialized__', 'AnnotationReader']

Array of field names to exclusion.

Return values
string

copyProperties()

コピー元のオブジェクトのフィールド名を指定して、同名のフィールドに値をコピー

public copyProperties( $srcObject : object [, $excludeAttribute : string[] = [] ] ) : AbstractEntity
Parameters
$srcObject : object

コピー元のオブジェクト

$excludeAttribute : string[] = []

除外したいフィールド名の配列

Return values
AbstractEntity

getAnnotationReader()

Get AnnotationReader.

public getAnnotationReader( ) : Reader
Return values
Reader

getEntityIdentifierAsArray()

Convert to Entity of Identity value to associative array.

public getEntityIdentifierAsArray( $Entity : AbstractEntity ) : array
Parameters
$Entity : AbstractEntity
Return values
array

associative array of [[id => value], [id => value], ...]

Search results