review_details.html 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. {% extends 'base.html' %}
  2. {% load crispy_forms_tags %}
  3. {% block content %}
  4. <div class="review__content-detail">
  5. <div>
  6. <a class="review__remove-btn" type="button" data-toggle="modal" data-target="#exampleModal">
  7. <i class="fa fa-trash fa-3x" aria-hidden="true"></i>
  8. </a>
  9. </div>
  10. <div class="review-content">
  11. <div><img src="{{ review.reviewer_photo }}" alt="" height="144px"></div>
  12. <div class="review__description">
  13. <h3>{{ review.reviewer_name }}</h3>
  14. <span>Posted on {{ review.location.care_name }}</span> <br>
  15. <span>Posted at {{ review.create_time | date:"M dS, Y" }}</span>
  16. <div>
  17. {% for i in "x"|rjust:review.star_rating %}
  18. <span style="color: #a41515;">&#9733</span>
  19. {% endfor %}
  20. </div>
  21. </div>
  22. </div>
  23. <p class="mt-5">{{ review.comment }}</p>
  24. <p class="mt-5">{{ review.reply.replied_text }}</p>
  25. <!-- Modal -->
  26. <div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  27. <div class="modal-dialog" role="document">
  28. <div class="modal-content">
  29. <div class="modal-header">
  30. <h5 class="modal-title" id="exampleModalLabel">Do you want to remove this reivew?</h5>
  31. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  32. <span aria-hidden="true">&times;</span>
  33. </button>
  34. </div>
  35. <div class="modal-body">
  36. This will delete the review from the database and might add it while syncing with the google review API.
  37. </div>
  38. <div class="modal-footer">
  39. <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
  40. <a type="button" class="btn btn-primary" href="{% url 'delete-review' review.review_id %}">Remove</a>
  41. </div>
  42. </div>
  43. </div>
  44. </div>
  45. </div>
  46. {% endblock content %}