7 changed files with 243 additions and 17 deletions
@ -0,0 +1,74 @@
|
||||
{% extends "portal_base.html" %} |
||||
|
||||
{% block title %}Upload Files - OTB Cloud{% endblock %} |
||||
|
||||
{% block portal_content %} |
||||
<div class="portal-page-header"> |
||||
<div> |
||||
<h1 class="portal-page-title">Upload Files</h1> |
||||
<p class="portal-client-name">{{ user_email }}</p> |
||||
<p class="portal-page-subtitle"> |
||||
Upload files into the <strong>{{ device.device_name }}</strong> device originals area. |
||||
</p> |
||||
</div> |
||||
|
||||
<div class="portal-toolbar" style="display:flex;flex-direction:column;align-items:flex-end;gap:10px;"> |
||||
<div style="display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap;"> |
||||
<a class="portal-btn" href="{{ url_for('main.dashboard') }}">Back to Dashboard</a> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
{% with messages = get_flashed_messages(with_categories=true) %} |
||||
{% if messages %} |
||||
<section style="margin-bottom:22px;"> |
||||
{% for category, message in messages %} |
||||
<div class="service-card" style="padding:14px 18px; margin-bottom:10px;"> |
||||
<strong>{{ category|capitalize }}:</strong> {{ message }} |
||||
</div> |
||||
{% endfor %} |
||||
</section> |
||||
{% endif %} |
||||
{% endwith %} |
||||
|
||||
<section class="services-grid"> |
||||
<article class="service-card status-beta" style="max-width:900px;"> |
||||
<div class="service-card-header"> |
||||
<div> |
||||
<h2>Upload to {{ device.device_name }}</h2> |
||||
<p>Selected files will be stored as immutable originals.</p> |
||||
</div> |
||||
<div> |
||||
<span class="service-badge service-badge-beta">{{ device.device_type|capitalize }}</span> |
||||
</div> |
||||
</div> |
||||
|
||||
<div class="service-card-actions"> |
||||
<form method="post" action="{{ url_for('main.upload_files', device_id=device.id) }}" enctype="multipart/form-data"> |
||||
<div style="display:grid;gap:16px;max-width:780px;"> |
||||
<div> |
||||
<label for="files" style="display:block;margin-bottom:6px;font-weight:700;">Choose Files</label> |
||||
<input |
||||
id="files" |
||||
name="files" |
||||
type="file" |
||||
multiple |
||||
required |
||||
style="width:100%;padding:12px 14px;border-radius:12px;border:1px solid rgba(255,255,255,0.14);background:rgba(255,255,255,0.04);color:white;" |
||||
> |
||||
</div> |
||||
|
||||
<div style="display:flex;gap:10px;flex-wrap:wrap;"> |
||||
<button class="portal-btn primary" type="submit">Upload Selected Files</button> |
||||
<a class="portal-btn" href="{{ url_for('main.dashboard') }}">Cancel</a> |
||||
</div> |
||||
|
||||
<div style="opacity:0.8;font-size:0.95rem;"> |
||||
Files uploaded here are stored in the device originals folder and recorded in the database. |
||||
</div> |
||||
</div> |
||||
</form> |
||||
</div> |
||||
</article> |
||||
</section> |
||||
{% endblock %} |
||||
Loading…
Reference in new issue