<div class="container my-3"
<table class="table"
<tr class="table-dark"

Introduction
Get started with Bootstrap, the world’s most popular framework for building responsive, mobile-first sites, with jsDelivr and a template starter page....
getbootstrap.com
{% load static %}
<link rel="stylesheet" type="text/css" href="{% static 'bootstrap.min.css' %}">
{% if question_list %}
<div class="container my-3">
<table class="table">
<thead>
<tr class="table-dark">
<th>출발일</th>
<th>상품번호</th>
<th>상품명</th>
<th>출발확정</th>
<th>예약가능석</th>
</tr>
</thead>
<tbody>
{% if question_list %}
{% for q in question_list %}
<tr>
<td>{{ q.create_date }}</td>
<td>{{ q.subject }} </td>
<td>{{ q.content }}</td>
<td>{{ forloop.counter }}</td>
<td>{{ q.id }} </td>
</tr>
{% endfor %}
{% else %}
<tr>
<td colspan="5">등록된 상품이 없습니다.</td>
</tr>
{% endif %}
</tbody>
</table>
</div>
2-08 부트스트랩
* `[완성 소스]` : [github.com/pahkey/jump2django/tree/2-08](https://github.com/pahkey/jump2django/tree/…...
wikidocs.net
'장고 > 점프투장고' 카테고리의 다른 글
로그인 로그아웃 구현 + 리다이렉트 URL ( config/urls.py ) (0) | 2023.11.15 |
---|---|
urls.py <int:pk> <------- views.py : redirect(___, pk=question.id) (0) | 2023.11.14 |
폼 에러 표시. class , form.errors/field.label/field.errors (0) | 2023.11.13 |
forms.py 에서 폼디자인( form.as_p 폼위젯, 수동폼 사용) (0) | 2023.11.12 |
settings.py : templates , static, media_url (0) | 2023.11.12 |
폼 + 상품의 총 구매수 {{ q.answer_set.count }} 출력 (0) | 2023.11.12 |
NoReverseMatch at /b2b/2/ Reverse for '....' with arguments 오류 (1) | 2023.11.12 |
url 네임스페이스(app_name) 과 url 별칭. {% url '' , redirect (1) | 2023.11.12 |
댓글