src/Models/Vacancy.php
public function hasRoomBetween(Carbon $startAt, Carbon $finishAt)
    {
        return $this->capacity > $this->business
                                      ->bookings()
                                      ->active()
                                      ->affectingInterval($startAt, $finishAt)
                                      ->affectingHumanresource($this->humanresource_id)
                                      ->count() &&
            ($this->start_at <= $startAt && $this->finish_at >= $finishAt);
    }
public function hasRoomBetween(Carbon $startAt, Carbon $finishAt)
    {
        return $this->capacity > $this->business
                                      ->bookings()
                                      ->active()
                                      ->affectingInterval($startAt, $finishAt)
                                      ->affectingHumanresource($this->humanresource_id)
                                      ->count() &&
            ($this->start_at <= $startAt && $this->finish_at >= $finishAt);
    }
public function hasRoomBetween ( Carbon $ startAt , Carbon $ finishAt ) { return $ this -> capacity > $ this -> business -> bookings ( ) -> active ( ) -> affectingInterval ( $ startAt , $ finishAt ) -> affectingHumanresource ( $ this -> humanresource_id ) -> count ( ) && ( $ this -> start_at <= $ startAt && $ this -> finish_at >= $ finishAt ) ; }
has Room between time.

@return bool There is more capacity than used
has Room between time .