project/templates/edit_supplier.html

45 lines
1.7 KiB
HTML

{% extends "base.html" %}
{% block content %}
<h1>✏️ Редактировать поставщика</h1>
<div style="max-width: 600px; margin: 0 auto;">
<form method="POST" style="background: #FDF5E6; padding: 2rem; border-radius: 10px;">
<div class="form-group">
<label>Название *</label>
<input type="text" name="name" value="{{ supplier.name }}" required style="width: 100%; padding: 0.5rem;">
</div>
<div class="form-group">
<label>Контактное лицо</label>
<input type="text" name="contact" value="{{ supplier.contact }}" style="width: 100%; padding: 0.5rem;">
</div>
<div class="form-group">
<label>Телефон</label>
<input type="text" name="phone" value="{{ supplier.phone }}" id="phone" style="width: 100%; padding: 0.5rem;">
<small style="color: #666; display: block; margin-top: 0.25rem;">
📞 Форматы: +7 (999) 123-45-67, 8-999-123-45-67, 9991234567
</small>
</div>
<div style="display: flex; gap: 1rem;">
<button type="submit" style="background: #CD853F; color: white; padding: 0.5rem 1rem; border: none; border-radius: 5px;">💾 Сохранить</button>
<a href="/suppliers" style="background: #666; color: white; padding: 0.5rem 1rem; text-decoration: none; border-radius: 5px;">❌ Отмена</a>
</div>
</form>
</div>
<style>
.form-group {
margin-bottom: 1rem;
}
.form-group label {
display: block;
margin-bottom: 0.5rem;
font-weight: bold;
color: #CD853F;
}
</style>
{% endblock %}