morozovka-portal/app/templates/admin_schedule_import.html
2026-10-20 03:27:14 +03:00

55 lines
3.1 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="ru">
<head>
<meta charset="UTF-8">
<title>Импорт расписания — Morozovka Portal</title>
<style>
body { background: #0d1117; color: #e6edf3; font-family: sans-serif; padding: 40px; }
.container { max-width: 600px; margin: 0 auto; }
h2 { color: #58a6ff; }
.card { background: #161b22; border: 1px solid #30363d; border-radius: 8px; padding: 30px; margin-top: 20px; }
.upload-area { border: 2px dashed #30363d; border-radius: 8px; padding: 40px; text-align: center; margin-bottom: 20px; transition: border-color 0.2s; }
.upload-area:hover { border-color: #58a6ff; }
input[type="file"] { display: none; }
.btn-file { display: inline-block; padding: 10px 20px; background: #21262d; color: white; border: 1px solid #30363d; border-radius: 5px; cursor: pointer; font-weight: bold; }
.btn-file:hover { background: #30363d; }
button[type="submit"] { width: 100%; padding: 12px; background: #238636; color: white; border: none; border-radius: 5px; cursor: pointer; font-weight: bold; font-size: 1rem; }
button[type="submit"]:hover { background: #2ea043; }
.back-link { display: inline-block; margin-bottom: 20px; color: #8b949e; text-decoration: none; }
.back-link:hover { color: #58a6ff; }
.hint { color: #8b949e; font-size: 0.85rem; margin-top: 15px; line-height: 1.5; }
</style>
</head>
<body>
<div class="container">
<a href="/admin/schedule" class="back-link">← Назад к расписанию</a>
<h2>Импорт расписания</h2>
<div class="card">
<form action="/admin/schedule/import" method="POST" enctype="multipart/form-data">
<div class="upload-area">
<label for="file-upload" class="btn-file">Выбрать .ics файл</label>
<input id="file-upload" type="file" name="file" accept=".ics" required onchange="document.getElementById('file-name').textContent = this.files[0].name">
<p id="file-name" style="margin-top: 15px; color: #3fb950;">Файл не выбран</p>
</div>
<button type="submit">Загрузить и импортировать</button>
</form>
<div class="hint">
<b>Как выгрузить расписание из Google Calendar?</b><br>
1. Зайдите в Google Calendar на компьютере.<br>
2. Нажмите на три точки рядом с нужным календарем.<br>
3. Выберите «Настройки и общий доступ».<br>
4. Прокрутите вниз до раздела «Экспорт календаря» и скачайте ZIP-архив.<br>
5. Распакуйте архив и загрузите сюда файл с расширением .ics.
</div>
</div>
</div>
</body>
</html>