forked from enviPath/enviPy
Fixes #89 Co-authored-by: Tim Lorsbach <tim@lorsba.ch> Reviewed-on: enviPath/enviPy#92
45 lines
1.8 KiB
HTML
45 lines
1.8 KiB
HTML
{% load static %}
|
|
<!-- Edit Model -->
|
|
<div id="edit_model_modal" class="modal" tabindex="-1">
|
|
<div class="modal-dialog">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
|
<span aria-hidden="true">×</span>
|
|
</button>
|
|
<h3 class="modal-title">Update Model</h3>
|
|
</div>
|
|
<div class="modal-body">
|
|
<p>Alter Name and Description of the Model.</p>
|
|
<form id="edit-model-modal-form" accept-charset="UTF-8" action="" data-remote="true" method="post">
|
|
{% csrf_token %}
|
|
<p>
|
|
<label for="model-name">Name</label>
|
|
<input id="model-name" type="text" class="form-control" name="model-name"
|
|
value="{{ model.name }}">
|
|
</p>
|
|
<p>
|
|
<label for="model-description">Description</label>
|
|
<input id="model-description" type="text" class="form-control" name="model-description"
|
|
value="{{ model.description }}">
|
|
</p>
|
|
</form>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
|
<button type="button" class="btn btn-primary" id="edit-model-modal-submit">Update</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script>
|
|
$(function () {
|
|
|
|
$('#edit-model-modal-submit').click(function (e) {
|
|
e.preventDefault();
|
|
$('#edit-model-modal-form').submit();
|
|
});
|
|
|
|
})
|
|
</script>
|