PHP Class Elcodi\Plugin\StoreSetupWizardBundle\Services\WizardStatus

Show file Open project: elcodi/bamboo Class Usage Examples

Protected Properties

Property Type Description
$productRepository Elcodi\Component\Product\Repository\ProductRepository Product repository
$store Elcodi\Component\Store\Entity\Interfaces\StoreInterface Store

Public Methods

Method Description
__construct ( Elcodi\Component\Product\Repository\ProductRepository $productRepository, Elcodi\Component\Store\Entity\Interfaces\StoreInterface $store, array $enabledPaymentPlugins, array $enabledShippingPlugins ) Builds a new WizardStepChecker
getNextStep ( ) : integer | null Get the next step.
getStepsFinishStatus ( ) : boolean[] Gets the finish status for all the steps
isStepFinished ( integer $stepNumber ) : boolean Checks if the received step is finished.
isWizardFinished ( ) : boolean Checks if the wizard has already been finished

Protected Methods

Method Description
isAddressFulfilled ( ) : boolean Checks if the address has been fulfilled.
isPaymentFulfilled ( ) : boolean Checks if the payment has been fulfilled
isShippingFulfilled ( ) : boolean Checks if any shipping range has been added to the store.
isThereAnyProduct ( ) : boolean Checks if there is any product on the store.

Method Details

__construct() public method

Builds a new WizardStepChecker
public __construct ( Elcodi\Component\Product\Repository\ProductRepository $productRepository, Elcodi\Component\Store\Entity\Interfaces\StoreInterface $store, array $enabledPaymentPlugins, array $enabledShippingPlugins )
$productRepository Elcodi\Component\Product\Repository\ProductRepository Product repository
$store Elcodi\Component\Store\Entity\Interfaces\StoreInterface Store
$enabledPaymentPlugins array The enabled payment methods
$enabledShippingPlugins array The enabled shipping methods

getNextStep() public method

Get the next step.
public getNextStep ( ) : integer | null
return integer | null The next step, null if the wizard is finished.

getStepsFinishStatus() public method

Gets the finish status for all the steps
public getStepsFinishStatus ( ) : boolean[]
return boolean[]

isAddressFulfilled() protected method

Checks if the address has been fulfilled.
protected isAddressFulfilled ( ) : boolean
return boolean

isPaymentFulfilled() protected method

Checks if the payment has been fulfilled
protected isPaymentFulfilled ( ) : boolean
return boolean

isShippingFulfilled() protected method

Checks if any shipping range has been added to the store.
protected isShippingFulfilled ( ) : boolean
return boolean

isStepFinished() public method

Checks if the received step is finished.
public isStepFinished ( integer $stepNumber ) : boolean
$stepNumber integer A step number.
return boolean If the step is finished

isThereAnyProduct() protected method

Checks if there is any product on the store.
protected isThereAnyProduct ( ) : boolean
return boolean

isWizardFinished() public method

Checks if the wizard has already been finished
public isWizardFinished ( ) : boolean
return boolean

Property Details

$productRepository protected property

Product repository
protected ProductRepository,Elcodi\Component\Product\Repository $productRepository
return Elcodi\Component\Product\Repository\ProductRepository

$store protected property

Store
protected StoreInterface,Elcodi\Component\Store\Entity\Interfaces $store
return Elcodi\Component\Store\Entity\Interfaces\StoreInterface