public function PriceList::setStartDate in Commerce Pricelist 8.2
Same name and namespace in other branches
- 8 src/Entity/PriceList.php \Drupal\commerce_pricelist\Entity\PriceList::setStartDate()
Sets the start date.
Parameters
\Drupal\Core\Datetime\DrupalDateTime $start_date: The start date.
Return value
$this
Overrides PriceListInterface::setStartDate
File
- src/
Entity/ PriceList.php, line 212
Class
- PriceList
- Defines the Price list entity.
Namespace
Drupal\commerce_pricelist\EntityCode
public function setStartDate(DrupalDateTime $start_date) {
$this
->get('start_date')->value = $start_date
->format(DateTimeItemInterface::DATETIME_STORAGE_FORMAT);
return $this;
}