48 lines
1.3 KiB
HTML
48 lines
1.3 KiB
HTML
|
|
{% extends "auctions/layout.html" %}
|
|
|
|
{% block body %}
|
|
<h2>Listing : {{ Listing.title}}</h2>
|
|
|
|
<img src = "{{Listing.picture}}" width = "100%" height= "100%"></img>
|
|
<hr>
|
|
|
|
<p>{{Listing.desc}}</p>
|
|
|
|
|
|
<h3>${{Listing.price}}</h3>
|
|
bids so far
|
|
<div class="form-group">
|
|
<input class="form-control" autofocus type="number" name="bid" placeholder="Bid">
|
|
</div>
|
|
<input class="btn btn-primary" type="submit" value="Place Bid">
|
|
<h4>Comments ...</h4>
|
|
|
|
{% if not Listing.comments.all %}
|
|
No comments Yet....
|
|
{% else %}
|
|
{% for comment in Listing.comments.all %}
|
|
<strong>{{comment.user}} - {{comment.date_added}}</strong>
|
|
<br/>
|
|
{{ comment.body }}
|
|
<br/>
|
|
{% endfor %}
|
|
|
|
|
|
{% endif %}
|
|
{% if user.is_authenticated %}
|
|
<h5>add comment..</h5>
|
|
<p>
|
|
<form method="POST">
|
|
{% csrf_token %}
|
|
<input class = "form-control" name="comment_body" autofocus type="text" rows=4 cols= 50 placeholder="Comment here!">
|
|
<input class="btn btn-primary" type="submit" value="Submit">
|
|
</form>
|
|
</p>
|
|
{% else %}
|
|
<br/>
|
|
<hr>
|
|
Log In to comment on this listing
|
|
{% endif %}
|
|
|
|
{% endblock %} |