more header changes
This commit is contained in:
@@ -1,47 +1,50 @@
|
||||
{% extends "common/base.html" %}
|
||||
{% from 'components/header.html' import header %}
|
||||
|
||||
{% block title %}Edit Room - {{ room.name }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container mt-4">
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-md-8">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h2 class="card-title mb-0">Edit Room</h2>
|
||||
{{ header(
|
||||
title="Edit Room",
|
||||
description="Update room details and settings",
|
||||
button_text="Cancel",
|
||||
button_url=url_for('rooms.rooms'),
|
||||
icon="fa-door-open",
|
||||
button_class="btn-secondary",
|
||||
button_icon="fa-times"
|
||||
) }}
|
||||
|
||||
<div class="container-fluid py-4">
|
||||
<div class="card shadow-sm">
|
||||
<div class="card-body">
|
||||
<form method="POST" action="{{ url_for('rooms.edit_room', room_id=room.id) }}">
|
||||
{{ form.hidden_tag() }}
|
||||
<div class="mb-3">
|
||||
{{ form.name.label(class="form-label") }}
|
||||
{{ form.name(class="form-control") }}
|
||||
{% if form.name.errors %}
|
||||
<div class="text-danger">
|
||||
{% for error in form.name.errors %}
|
||||
<small>{{ error }}</small>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<form method="POST" action="{{ url_for('rooms.edit_room', room_id=room.id) }}">
|
||||
{{ form.hidden_tag() }}
|
||||
<div class="mb-3">
|
||||
{{ form.name.label(class="form-label") }}
|
||||
{{ form.name(class="form-control") }}
|
||||
{% if form.name.errors %}
|
||||
<div class="text-danger">
|
||||
{% for error in form.name.errors %}
|
||||
<small>{{ error }}</small>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="{{ form.description.id }}" class="form-label">Description (Optional)</label>
|
||||
{{ form.description(class="form-control", rows="3", placeholder="Enter a description (optional)") }}
|
||||
{% if form.description.errors %}
|
||||
<div class="text-danger">
|
||||
{% for error in form.description.errors %}
|
||||
<small>{{ error }}</small>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="d-flex justify-content-between">
|
||||
<a href="{{ url_for('rooms.rooms') }}" class="btn btn-secondary">Cancel</a>
|
||||
{{ form.submit(class="btn btn-primary", value="Update Room") }}
|
||||
</div>
|
||||
</form>
|
||||
<div class="mb-3">
|
||||
<label for="{{ form.description.id }}" class="form-label">Description (Optional)</label>
|
||||
{{ form.description(class="form-control", rows="3", placeholder="Enter a description (optional)") }}
|
||||
{% if form.description.errors %}
|
||||
<div class="text-danger">
|
||||
{% for error in form.description.errors %}
|
||||
<small>{{ error }}</small>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-end">
|
||||
{{ form.submit(class="btn btn-primary", value="Update Room") }}
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user