Improve modal
This commit is contained in:
parent
019ffa34cd
commit
c598694eb4
@ -1,7 +1,9 @@
|
||||
{{define "budget-new"}}
|
||||
<div id="newbudgetmodal" class="modal">
|
||||
<div id="newbudgetmodal" class="modal fade">
|
||||
<div class="modal-dialog" role="document">
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
$('#errorcreatingbudget').hide();
|
||||
$('#newbudgetform').ajaxForm({
|
||||
error: function() {
|
||||
$('#errorcreatingbudget').show();
|
||||
@ -9,8 +11,15 @@
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<h3>New Budget</h3>
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">New Budget</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form id="newbudgetform" action="/api/v1/budget/new" method="POST">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label for="name">Name</label>
|
||||
<input type="text" name="name" class="form-control" placeholder="Name" />
|
||||
@ -19,8 +28,13 @@
|
||||
<div id="errorcreatingbudget">
|
||||
Error creating budget.
|
||||
</div>
|
||||
|
||||
<input type="submit" value="Create" class="form-control" />
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
||||
<input type="submit" class="btn btn-primary" value="Create" class="form-control" />
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{end}}
|
Loading…
x
Reference in New Issue
Block a user