コード例 #1
0
ファイル: app.py プロジェクト: TongyanX/lec24
def fball():
    model.init_ball('umfootball.csv')
    if request.method == 'POST':
        sortby = request.form['sortby']
        sortorder = request.form['sortorder']
        seasons = model.get_ball_seasons(sortby, sortorder)
    else:
        seasons = model.get_ball_seasons()

    return render_template("seasons.html", seasons=seasons, ball='fball')
コード例 #2
0
def football():
    model.init_ball(model.FB_FILE_NAME)
    if request.method == 'POST':
        sortby = request.form['sortby']
        sortorder = request.form['sortorder']
        seasons = model.get_seasons(sortby, sortorder)
    else:
        seasons = model.get_seasons()
    return render_template("seasons.html",
                           seasons=seasons,
                           ball='Football',
                           ac='football')
コード例 #3
0
ファイル: app.py プロジェクト: xinyu0721g/lec24
def bball():
    model.init_ball('BB')
    if request.method == 'POST':
        sortby = request.form['sortby']
        sortorder = request.form['sortorder']
        seasons = model.get_ball_seasons(sortby, sortorder)
    else:
        seasons = model.get_ball_seasons()
    return render_template("seasons.html",
                           seasons=seasons,
                           ball='Basketball',
                           ball_d='bball')