DmitrMakeev
commited on
Commit
•
4c7da00
1
Parent(s):
6b46630
Update biz_v.html
Browse files- biz_v.html +119 -1
biz_v.html
CHANGED
@@ -216,8 +216,33 @@
|
|
216 |
<input id="uploadButton" type="submit" value="Загрузить пользователей">
|
217 |
</form>
|
218 |
<div id="result"></div>
|
219 |
-
</div>
|
220 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
221 |
<div class="block">
|
222 |
<h2>Бизон 365 - API</h2>
|
223 |
<div class="form-group">
|
@@ -241,6 +266,39 @@
|
|
241 |
</div>
|
242 |
</div>
|
243 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
244 |
<!-- Подключение скрипта Notyf -->
|
245 |
<script src="https://cdn.jsdelivr.net/npm/notyf/notyf.min.js"></script>
|
246 |
<script>
|
@@ -361,5 +419,65 @@
|
|
361 |
});
|
362 |
}
|
363 |
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
364 |
</body>
|
365 |
</html>
|
|
|
216 |
<input id="uploadButton" type="submit" value="Загрузить пользователей">
|
217 |
</form>
|
218 |
<div id="result"></div>
|
|
|
219 |
|
220 |
+
|
221 |
+
<title>Upload JSON</title>
|
222 |
+
|
223 |
+
|
224 |
+
|
225 |
+
<h1>Upload JSON File</h1>
|
226 |
+
<form id="uploadForm" onsubmit="handleFormSubmit(event)" enctype="multipart/form-data">
|
227 |
+
<label for="file">Select JSON file:</label>
|
228 |
+
<input type="file" id="file" name="file" accept=".json" required><br><br>
|
229 |
+
<input type="submit" value="Upload">
|
230 |
+
</form>
|
231 |
+
<div id="message" style="display:none; margin-top:20px;"></div>
|
232 |
+
|
233 |
+
|
234 |
+
|
235 |
+
</div>
|
236 |
+
|
237 |
+
|
238 |
+
|
239 |
+
|
240 |
+
|
241 |
+
|
242 |
+
|
243 |
+
|
244 |
+
|
245 |
+
|
246 |
<div class="block">
|
247 |
<h2>Бизон 365 - API</h2>
|
248 |
<div class="form-group">
|
|
|
266 |
</div>
|
267 |
</div>
|
268 |
|
269 |
+
|
270 |
+
|
271 |
+
|
272 |
+
|
273 |
+
|
274 |
+
|
275 |
+
|
276 |
+
|
277 |
+
|
278 |
+
|
279 |
+
|
280 |
+
|
281 |
+
|
282 |
+
|
283 |
+
|
284 |
+
|
285 |
+
|
286 |
+
|
287 |
+
|
288 |
+
|
289 |
+
|
290 |
+
|
291 |
+
|
292 |
+
|
293 |
+
|
294 |
+
|
295 |
+
|
296 |
+
|
297 |
+
|
298 |
+
|
299 |
+
|
300 |
+
|
301 |
+
|
302 |
<!-- Подключение скрипта Notyf -->
|
303 |
<script src="https://cdn.jsdelivr.net/npm/notyf/notyf.min.js"></script>
|
304 |
<script>
|
|
|
419 |
});
|
420 |
}
|
421 |
</script>
|
422 |
+
|
423 |
+
|
424 |
+
|
425 |
+
|
426 |
+
|
427 |
+
|
428 |
+
|
429 |
+
|
430 |
+
|
431 |
+
|
432 |
+
|
433 |
+
|
434 |
+
|
435 |
+
|
436 |
+
|
437 |
+
|
438 |
+
|
439 |
+
<script>
|
440 |
+
function showMessage(message) {
|
441 |
+
var messageDiv = document.getElementById('message');
|
442 |
+
messageDiv.innerText = message;
|
443 |
+
messageDiv.style.display = 'block';
|
444 |
+
}
|
445 |
+
function handleFormSubmit(event) {
|
446 |
+
event.preventDefault();
|
447 |
+
var formData = new FormData(event.target);
|
448 |
+
fetch('/upload_json', {
|
449 |
+
method: 'POST',
|
450 |
+
body: formData
|
451 |
+
})
|
452 |
+
.then(response => response.json())
|
453 |
+
.then(data => {
|
454 |
+
if (data.message) {
|
455 |
+
showMessage(data.message);
|
456 |
+
} else if (data.error) {
|
457 |
+
showMessage(data.error);
|
458 |
+
}
|
459 |
+
})
|
460 |
+
.catch(error => {
|
461 |
+
showMessage("An error occurred: " + error);
|
462 |
+
});
|
463 |
+
}
|
464 |
+
</script>
|
465 |
+
|
466 |
+
|
467 |
+
|
468 |
+
|
469 |
+
|
470 |
+
|
471 |
+
|
472 |
+
|
473 |
+
|
474 |
+
|
475 |
+
|
476 |
+
|
477 |
+
|
478 |
+
|
479 |
+
|
480 |
+
|
481 |
+
|
482 |
</body>
|
483 |
</html>
|