public static function DateRecurRRule::massageDateValueForStorage in Recurring Dates Field 8
2 calls to DateRecurRRule::massageDateValueForStorage()
- DateRecurRRule::getOccurrencesForCacheStorage in src/
DateRecurRRule.php - Get the occurrences for storage in the cache table (for views).
- DefaultDateRecurOccurrenceHandler::getOccurrencesForCacheStorage in src/
Plugin/ DateRecurOccurrenceHandler/ DefaultDateRecurOccurrenceHandler.php
File
- src/
DateRecurRRule.php, line 324
Class
Namespace
Drupal\date_recurCode
public static function massageDateValueForStorage($date, $format) {
if ($format == DATETIME_DATE_STORAGE_FORMAT) {
datetime_date_default_time($date);
}
$date
->setTimezone(new \DateTimeZone(DATETIME_STORAGE_TIMEZONE));
// Adjust the date for storage.
return $date
->format($format);
}