Commit e3f9e1b7 authored by Administrator's avatar Administrator

[FEATURE] Templates. Form in popover to add project. OK

parent ab62bc50
......@@ -75,7 +75,15 @@ $(function() {
</script>
<script src="{% static "js/bootstrap.min.js" %}"></script>
<script>$(function () { $("[data-toggle='popover']").popover({html:true});});</script>
<script>$(function () { $("[data-toggle='popover']").popover({
html:true,
title: function() {
return $("#popover-head").html();
},
content: function() {
return $("#popover-content").html();
}
});});</script>
</body>
</html>
......
......@@ -19,16 +19,18 @@
<p>Template showing my working space</p>
</div>
<div class="col-md-4"></div>
<div class="col-md-4"></div>
<div class="col-md-4"></div>
<div class="col-md-4">
<form enctype="multipart/form-data" action="/projects/" method="post">
{% csrf_token %}
{{ form.non_field_errors }}
{{ form.as_p}}
<input type="submit" value="Add project" />
</form>
</div>
<button
type="button"
class="btn btn-primary btn-lg"
data-container="body"
data-toggle="popover"
data-placement="bottom"
>Add project</button>
<div id="popover-content" class="hide">
<form enctype='multipart/form-data' action='/projects/' method='post'>{% csrf_token %}{{ form.non_field_errors }}{{ form.as_p}}<input type='submit' value='Add project'/></form>">
</div>
</div>
</div>
</div>
</div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment