{% extends "main.html" %}{% block contents %}<table class="table" style="border: 8px blue;" > <thead> <th>입항일</th> <th>본선명</th> </thead> <tbody> {% for d_list in d_lists %} <tr> <td>{{d_list.date}}</td> <td>{{d_list.mv_name}}</td> </tr> {% endfor %} </tbody></table>{% endblock %}
{% extends "main.html" %}
{% block contents %}
<table class="table" style="border: 8px blue;" >
<thead>
<th>입항일</th>
<th>본선명</th>
</thead>
<tbody>
{% for d_list in d_lists %}
<tr>
<td>{{d_list.date}}</td>
<td>{{d_list.mv_name}}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}
from main import *
from flask import Blueprint
bp = Blueprint("d_bar", __name__, url_prefix='/d_bar')
@bp.route('/d_list')
def d_list():
d_lists = list(db.mv.find({"cago_name": "철근"}))
print (d_lists)
return render_template("d_list.html",d_lists=d_lists,title="철근상세")