# Restrict When (events can be created) / (events can be drag/dropped)

![](https://1857871955-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MdYYYaX6u6mOCBpjLIC%2F-MdjewnJWEsMTH51-vc9%2F-Mdjk-Z_QFUEr83CpvaX%2FUntitled%20\(11\).png?alt=media\&token=424cc3e9-0644-431d-95f6-30d091a89c77)

## Restrict when events can be created

* Limits user selection to certain windows of time.

## Restrict when events can be drag-and-dropped

* Limits event dragging and resizing to certain windows of time.
* If [business hours](https://jared-gibb.gitbook.io/fullcalendar-plugin-suite/elements/calendar/input-fields/business-hours) are given, events being dragged or resized must be fully contained within the week’s business hours (Monday-Friday 9am-5pm by default). This field will be ignored.&#x20;

## &#x20;Event \[ Select / Drag-and-Drop ] Restraint input fields

### Daily Start Times

* This is the start of the window of time
* This will apply for ***all*** [applicable days](#applicable-days)
* This input takes time in a 24:00 hour format. Do not include any spaces or any other formatting. This input&#x20;
* The following are some acceptable examples but be aware that at this time, ***the calendar will only accept 1 value***

```javascript
[00:00, 9:00, 12:30, 18:45]
    //only include one time.
    //do not include seconds or any am/pm or other formatting pieces here
```

### Daily End Times

* This is the end of the window of time
* This will apply for ***all*** [applicable days](#applicable-days)
* This input takes time in a 24:00 hour format. Do not include any spaces or any other formatting. This input&#x20;
* The following are some acceptable examples but be aware that at this time, ***the calendar will only accept 1 value***

```javascript
[00:00, 9:00, 12:30, 18:45] 
    //only include one time.
    //do not include seconds or any am/pm or other formatting pieces here
```

### Applicable Days&#x20;

* For now, when using either of these settings, the times chosen above will apply to all provided days.
* Days are represented as numbers and are 0-indexed meaning Sunday = 0, Monday = 1, Tuesday = 2, and so on.&#x20;
* This field accepts a list or a comma separated string

```javascript
[1,2,3,4,5] //this list would represent Mon - Fri
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://jared-gibb.gitbook.io/fullcalendar-plugin-suite/elements/calendar/input-fields/event-select-drag-and-drop-restraint.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
