mirror of
https://github.com/perstarkse/minne.git
synced 2026-03-29 22:01:59 +02:00
feat: modal component, edit functionality
This commit is contained in:
31
templates/knowledge/edit_knowledge_entity_modal.html
Normal file
31
templates/knowledge/edit_knowledge_entity_modal.html
Normal file
@@ -0,0 +1,31 @@
|
||||
{% extends "modal_base.html" %}
|
||||
|
||||
{% block form_attributes %}
|
||||
hx-patch="/knowledge-entity/{{entity.id}}"
|
||||
hx-target="#entity-list"
|
||||
hx-swap="outerHTML"
|
||||
{% endblock %}
|
||||
|
||||
{% block modal_content %}
|
||||
<h3 class="text-lg font-bold mb-4">Edit Entity</h3>
|
||||
|
||||
<div class="form-control">
|
||||
<label class="label">
|
||||
<span class="label-text">Entity Name</span>
|
||||
</label>
|
||||
<input type="text" name="name" value="{{ entity.name }}" class="input input-bordered">
|
||||
</div>
|
||||
|
||||
<div class="form-control mt-4">
|
||||
<label class="label">
|
||||
<span class="label-text">Description</span>
|
||||
</label>
|
||||
<textarea name="description" class="textarea textarea-bordered h-32">{{ entity.description }}</textarea>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block primary_actions %}
|
||||
<button type="submit" class="btn btn-primary">
|
||||
Save Changes
|
||||
</button>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user