def list_cards(): log('调用路由') cs = Card.all() # for test # cs 是什么 # c = cs[0] # log(f'c: {c.keys()}') # log(f'c: {type(c)}') if not cs: flash('没有一张卡片。') return render_template('list_cards.html', cs=cs)
def index(): cards = Card.all() return render_template('cards/cards_index.html', cards=cards)