You are here

public function Invoice::setStore in Commerce Invoice 8.2

Sets the store.

Parameters

\Drupal\commerce_store\Entity\StoreInterface $store: The store entity.

Return value

$this

Overrides EntityStoreInterface::setStore

File

src/Entity/Invoice.php, line 127

Class

Invoice
Defines the invoice entity class.

Namespace

Drupal\commerce_invoice\Entity

Code

public function setStore(StoreInterface $store) {
  $this
    ->set('store_id', $store
    ->id());
  return $this;
}