public function ScheduleData::addWeekdayOff in Loft Data Grids 7.2
Mark a single weekday as unworked.
Parameters
string $value Three char word ,e.g. 'Sun', 'Mon'...:
Return value
$this
File
- vendor/
aklump/ loft_data_grids/ src/ AKlump/ LoftDataGrids/ ScheduleData.php, line 288
Class
- ScheduleData
- Class ScheduleData
Namespace
AKlump\LoftDataGridsCode
public function addWeekdayOff($value) {
$value = ucfirst(strtolower($value));
if (!date_create_from_format('D', $value)) {
throw new \InvalidArgumentException("Bad format of day of week.");
}
$this->weekdaysOff[] = $value;
return $this;
}