PHP Class Sonata\InvoiceBundle\Entity\BaseInvoice

Inheritance: implements Sonata\Component\Invoice\InvoiceInterface
Show file Open project: sonata-project/ecommerce Class Usage Examples

Protected Properties

Property Type Description
$address1 string
$address2 string
$address3 string
$city string
$country string
$createdAt DateTime
$currency Sonata\Component\Currency\CurrencyInterface
$customer integer
$email string
$fax string
$invoiceElements array
$locale string
$mobile string
$name string
$paymentMethod string
$phone string
$postcode string
$reference string
$status integer
$totalExcl float
$totalInc float
$user Sonata\UserBundle\Model\UserInterface

Public Methods

Method Description
__construct ( ) Constructor.
__toString ( ) : string
addInvoiceElement ( Sonata\Component\Invoice\InvoiceElementInterface $element )
getAddress1 ( ) : string Get address1.
getAddress2 ( ) : string Get address2.
getAddress3 ( ) : string Get address3.
getBillingAsArray ( ) : array
getCity ( ) : string Get city.
getCountry ( ) : string Get country.
getCreatedAt ( ) : DateTime
getCurrency ( ) : Sonata\Component\Currency\CurrencyInterface Get currency.
getCustomer ( ) : integer Get userId.
getEmail ( ) : string Get email.
getFax ( ) : string Get fax.
getFullBilling ( string $sep = ', ' ) : string Returns formatted billing address.
getInvoiceElements ( )
getLocale ( ) : string Gets the locale.
getMobile ( ) : string Get mobile.
getName ( ) : string Get name.
getPaymentMethod ( )
getPhone ( ) : string Get phone.
getPostcode ( ) : string Get postcode.
getReference ( ) : string Get reference.
getStatus ( ) : integer Get status.
getStatusList ( ) : array
getStatusName ( ) : string
getTotalExcl ( ) : float Get totalExcl.
getTotalInc ( ) : float Get totalInc.
getUser ( ) : Sonata\UserBundle\Model\UserInterface Get user.
getValidationStatusList ( ) : array
getVatAmounts ( ) : array Returns all VAT amounts contained in elements.
setAddress1 ( string $address1 ) Set address1.
setAddress2 ( string $address2 ) Set address2.
setAddress3 ( string $address3 ) Set address3.
setCity ( string $city ) Set city.
setCountry ( string $country ) Set country.
setCreatedAt ( DateTime $createdAt )
setCurrency ( Sonata\Component\Currency\CurrencyInterface $currency ) Set currency.
setCustomer ( Sonata\Component\Customer\CustomerInterface $customer = null ) Set userId R.
setEmail ( string $email ) Set email.
setFax ( string $fax ) Set fax.
setInvoiceElements ( array $elements )
setLocale ( string $locale ) Sets the locale.
setMobile ( string $mobile ) Set mobile.
setName ( string $name ) Set name.
setPaymentMethod ( $paymentMethod )
setPhone ( string $phone ) Set phone.
setPostcode ( string $postcode ) Set postcode.
setReference ( string $reference ) Set reference.
setStatus ( integer $status ) Set status.
setTotalExcl ( float $totalExcl ) Set totalExcl.
setTotalInc ( float $totalInc ) Set totalInc.
setUser ( Sonata\UserBundle\Model\UserInterface $user ) Set user.

Method Details

__construct() public method

Constructor.
public __construct ( )

__toString() public method

public __toString ( ) : string
return string

addInvoiceElement() public method

public addInvoiceElement ( Sonata\Component\Invoice\InvoiceElementInterface $element )
$element Sonata\Component\Invoice\InvoiceElementInterface

getAddress1() public method

Get address1.
public getAddress1 ( ) : string
return string $address1

getAddress2() public method

Get address2.
public getAddress2 ( ) : string
return string $address2

getAddress3() public method

Get address3.
public getAddress3 ( ) : string
return string $address3

getBillingAsArray() public method

public getBillingAsArray ( ) : array
return array

getCity() public method

Get city.
public getCity ( ) : string
return string $city

getCountry() public method

Get country.
public getCountry ( ) : string
return string $country

getCreatedAt() public method

public getCreatedAt ( ) : DateTime
return DateTime

getCurrency() public method

Get currency.
public getCurrency ( ) : Sonata\Component\Currency\CurrencyInterface
return Sonata\Component\Currency\CurrencyInterface $currency

getCustomer() public method

Get userId.
public getCustomer ( ) : integer
return integer $customer

getEmail() public method

Get email.
public getEmail ( ) : string
return string $email

getFax() public method

Get fax.
public getFax ( ) : string
return string $fax

getFullBilling() public method

Returns formatted billing address.
public getFullBilling ( string $sep = ', ' ) : string
$sep string
return string

getInvoiceElements() public method

public getInvoiceElements ( )

getLocale() public method

Gets the locale.
public getLocale ( ) : string
return string

getMobile() public method

Get mobile.
public getMobile ( ) : string
return string $mobile

getName() public method

Get name.
public getName ( ) : string
return string $name

getPaymentMethod() public method

public getPaymentMethod ( )

getPhone() public method

Get phone.
public getPhone ( ) : string
return string $phone

getPostcode() public method

Get postcode.
public getPostcode ( ) : string
return string $postcode

getReference() public method

Get reference.
public getReference ( ) : string
return string $reference

getStatus() public method

Get status.
public getStatus ( ) : integer
return integer $status

getStatusList() public static method

public static getStatusList ( ) : array
return array

getStatusName() public method

public getStatusName ( ) : string
return string

getTotalExcl() public method

Get totalExcl.
public getTotalExcl ( ) : float
return float $totalExcl

getTotalInc() public method

Get totalInc.
public getTotalInc ( ) : float
return float $totalInc

getUser() public method

Get user.
public getUser ( ) : Sonata\UserBundle\Model\UserInterface
return Sonata\UserBundle\Model\UserInterface $user

getValidationStatusList() public static method

public static getValidationStatusList ( ) : array
return array

getVatAmounts() public method

Returns all VAT amounts contained in elements.
public getVatAmounts ( ) : array
return array

setAddress1() public method

Set address1.
public setAddress1 ( string $address1 )
$address1 string

setAddress2() public method

Set address2.
public setAddress2 ( string $address2 )
$address2 string

setAddress3() public method

Set address3.
public setAddress3 ( string $address3 )
$address3 string

setCity() public method

Set city.
public setCity ( string $city )
$city string

setCountry() public method

Set country.
public setCountry ( string $country )
$country string

setCreatedAt() public method

public setCreatedAt ( DateTime $createdAt )
$createdAt DateTime

setCurrency() public method

Set currency.
public setCurrency ( Sonata\Component\Currency\CurrencyInterface $currency )
$currency Sonata\Component\Currency\CurrencyInterface

setCustomer() public method

Set userId R.
public setCustomer ( Sonata\Component\Customer\CustomerInterface $customer = null )
$customer Sonata\Component\Customer\CustomerInterface

setEmail() public method

Set email.
public setEmail ( string $email )
$email string

setFax() public method

Set fax.
public setFax ( string $fax )
$fax string

setInvoiceElements() public method

public setInvoiceElements ( array $elements )
$elements array

setLocale() public method

Sets the locale.
public setLocale ( string $locale )
$locale string

setMobile() public method

Set mobile.
public setMobile ( string $mobile )
$mobile string

setName() public method

Set name.
public setName ( string $name )
$name string

setPaymentMethod() public method

public setPaymentMethod ( $paymentMethod )

setPhone() public method

Set phone.
public setPhone ( string $phone )
$phone string

setPostcode() public method

Set postcode.
public setPostcode ( string $postcode )
$postcode string

setReference() public method

Set reference.
public setReference ( string $reference )
$reference string

setStatus() public method

Set status.
public setStatus ( integer $status )
$status integer

setTotalExcl() public method

Set totalExcl.
public setTotalExcl ( float $totalExcl )
$totalExcl float

setTotalInc() public method

Set totalInc.
public setTotalInc ( float $totalInc )
$totalInc float

setUser() public method

Set user.
public setUser ( Sonata\UserBundle\Model\UserInterface $user )
$user Sonata\UserBundle\Model\UserInterface

Property Details

$address1 protected property

protected string $address1
return string

$address2 protected property

protected string $address2
return string

$address3 protected property

protected string $address3
return string

$city protected property

protected string $city
return string

$country protected property

protected string $country
return string

$createdAt protected property

protected DateTime $createdAt
return DateTime

$currency protected property

protected CurrencyInterface,Sonata\Component\Currency $currency
return Sonata\Component\Currency\CurrencyInterface

$customer protected property

protected int $customer
return integer

$email protected property

protected string $email
return string

$fax protected property

protected string $fax
return string

$invoiceElements protected property

protected array $invoiceElements
return array

$locale protected property

protected string $locale
return string

$mobile protected property

protected string $mobile
return string

$name protected property

protected string $name
return string

$paymentMethod protected property

protected string $paymentMethod
return string

$phone protected property

protected string $phone
return string

$postcode protected property

protected string $postcode
return string

$reference protected property

protected string $reference
return string

$status protected property

protected int $status
return integer

$totalExcl protected property

protected float $totalExcl
return float

$totalInc protected property

protected float $totalInc
return float

$user protected property

protected UserInterface,Sonata\UserBundle\Model $user
return Sonata\UserBundle\Model\UserInterface