Update biz_v.html
Browse files- biz_v.html +16 -2
biz_v.html
CHANGED
|
@@ -48,35 +48,46 @@
|
|
| 48 |
<body>
|
| 49 |
<h1>Комменты Бизон 365</h1>
|
| 50 |
|
|
|
|
| 51 |
<label for="tokenInput">Enter Token:</label>
|
| 52 |
<input type="text" id="tokenInput" placeholder="Your Token">
|
| 53 |
|
|
|
|
| 54 |
<label for="dateSelect">Select Min Date:</label>
|
| 55 |
<input type="datetime-local" id="dateSelect">
|
| 56 |
|
|
|
|
| 57 |
<label for="maxDateSelect">Select Max Date:</label>
|
| 58 |
<input type="datetime-local" id="maxDateSelect">
|
| 59 |
|
|
|
|
| 60 |
<label for="limitInput">Limit:</label>
|
| 61 |
-
<input type="number" id="limitInput"
|
| 62 |
|
|
|
|
| 63 |
<label for="typeSelect">Type:</label>
|
| 64 |
<select id="typeSelect">
|
| 65 |
<option value="LiveWebinars">Live Webinars</option>
|
| 66 |
<option value="AutoWebinars">Auto Webinars</option>
|
| 67 |
</select>
|
| 68 |
|
|
|
|
| 69 |
<button id="sendRequestButton">Send Request</button>
|
| 70 |
|
|
|
|
| 71 |
<textarea id="responseArea" rows="10" cols="50" readonly></textarea>
|
| 72 |
|
|
|
|
| 73 |
<div id="dropdown-container"></div>
|
| 74 |
|
|
|
|
| 75 |
<button id="sendGetRequestButton">Send GET Request</button>
|
| 76 |
|
|
|
|
| 77 |
<textarea id="secondResponseArea" rows="10" cols="50" readonly></textarea>
|
| 78 |
|
| 79 |
<script>
|
|
|
|
| 80 |
document.getElementById('sendRequestButton').addEventListener('click', function() {
|
| 81 |
const token = document.getElementById('tokenInput').value;
|
| 82 |
const minDate = document.getElementById('dateSelect').value;
|
|
@@ -111,6 +122,7 @@
|
|
| 111 |
});
|
| 112 |
});
|
| 113 |
|
|
|
|
| 114 |
function createDropdown(data) {
|
| 115 |
const container = document.getElementById('dropdown-container');
|
| 116 |
container.innerHTML = ''; // Очистить контейнер перед добавлением нового списка
|
|
@@ -125,10 +137,12 @@
|
|
| 125 |
container.appendChild(select);
|
| 126 |
}
|
| 127 |
|
|
|
|
| 128 |
document.getElementById('sendGetRequestButton').addEventListener('click', function() {
|
| 129 |
const selectedValue = document.getElementById('dropdown').value;
|
| 130 |
const token = document.getElementById('tokenInput').value;
|
| 131 |
-
const getUrl =
|
|
|
|
| 132 |
fetch(getUrl, {
|
| 133 |
method: 'GET'
|
| 134 |
})
|
|
|
|
| 48 |
<body>
|
| 49 |
<h1>Комменты Бизон 365</h1>
|
| 50 |
|
| 51 |
+
<!-- Поле для ввода токена -->
|
| 52 |
<label for="tokenInput">Enter Token:</label>
|
| 53 |
<input type="text" id="tokenInput" placeholder="Your Token">
|
| 54 |
|
| 55 |
+
<!-- Поле для выбора минимальной даты -->
|
| 56 |
<label for="dateSelect">Select Min Date:</label>
|
| 57 |
<input type="datetime-local" id="dateSelect">
|
| 58 |
|
| 59 |
+
<!-- Поле для выбора максимальной даты -->
|
| 60 |
<label for="maxDateSelect">Select Max Date:</label>
|
| 61 |
<input type="datetime-local" id="maxDateSelect">
|
| 62 |
|
| 63 |
+
<!-- Поле для ввода лимита -->
|
| 64 |
<label for="limitInput">Limit:</label>
|
| 65 |
+
<input type="number" id="limitInput" value="20" min="1" max="100">
|
| 66 |
|
| 67 |
+
<!-- Поле для выбора типа вебинаров -->
|
| 68 |
<label for="typeSelect">Type:</label>
|
| 69 |
<select id="typeSelect">
|
| 70 |
<option value="LiveWebinars">Live Webinars</option>
|
| 71 |
<option value="AutoWebinars">Auto Webinars</option>
|
| 72 |
</select>
|
| 73 |
|
| 74 |
+
<!-- Кнопка для отправки запроса -->
|
| 75 |
<button id="sendRequestButton">Send Request</button>
|
| 76 |
|
| 77 |
+
<!-- Текстовое поле для отображения ответа на запрос -->
|
| 78 |
<textarea id="responseArea" rows="10" cols="50" readonly></textarea>
|
| 79 |
|
| 80 |
+
<!-- Контейнер для выпадающего списка -->
|
| 81 |
<div id="dropdown-container"></div>
|
| 82 |
|
| 83 |
+
<!-- Кнопка для отправки GET-запроса -->
|
| 84 |
<button id="sendGetRequestButton">Send GET Request</button>
|
| 85 |
|
| 86 |
+
<!-- Текстовое поле для отображения ответа на GET-запрос -->
|
| 87 |
<textarea id="secondResponseArea" rows="10" cols="50" readonly></textarea>
|
| 88 |
|
| 89 |
<script>
|
| 90 |
+
// Обработчик клика по кнопке отправки запроса
|
| 91 |
document.getElementById('sendRequestButton').addEventListener('click', function() {
|
| 92 |
const token = document.getElementById('tokenInput').value;
|
| 93 |
const minDate = document.getElementById('dateSelect').value;
|
|
|
|
| 122 |
});
|
| 123 |
});
|
| 124 |
|
| 125 |
+
// Функция для создания выпадающего списка
|
| 126 |
function createDropdown(data) {
|
| 127 |
const container = document.getElementById('dropdown-container');
|
| 128 |
container.innerHTML = ''; // Очистить контейнер перед добавлением нового списка
|
|
|
|
| 137 |
container.appendChild(select);
|
| 138 |
}
|
| 139 |
|
| 140 |
+
// Обработчик клика по кнопке отправки GET-запроса
|
| 141 |
document.getElementById('sendGetRequestButton').addEventListener('click', function() {
|
| 142 |
const selectedValue = document.getElementById('dropdown').value;
|
| 143 |
const token = document.getElementById('tokenInput').value;
|
| 144 |
+
const getUrl = `/send_get_request?token=${encodeURIComponent(token)}&webinarId=${encodeURIComponent(selectedValue)}`;
|
| 145 |
+
|
| 146 |
fetch(getUrl, {
|
| 147 |
method: 'GET'
|
| 148 |
})
|