"""
Routes and views for the flask application.
"""

from datetime import datetime
from flask import render_template
from FlaskWebProject1 import app, models
from sqlalchemy.orm import relationship, synonym, sessionmaker
from sqlalchemy.ext.declarative import declarative_base

#models.Base.metadata.create_all(engine)
#Session = sessionmaker(bind=engine)
#session = Session()

@app.route('/')
@app.route('/home')
def home():
    """Renders the home page."""
    return render_template(
        'index.html',
        title='Home Page',
        year=datetime.now().year,
    )

@app.route('/tvmedia')
def tvmedia():
    """Renders the TV Media page."""
    return render_template(
        'tvmedia.html',
        title='TV Media',
        year=datetime.now().year,
        message='Your tv media description page.'
    )

@app.route('/resume')
def resume():
    """Renders the Resume page."""
    return render_template(
        'resume.html',
        title='My Resume',
        year=datetime.now().year,
        message='Your Resume description page.'
    )

@app.route('/contact')
def contact():
    """Renders the contact page."""
    return render_template(
        'contact.html',
        title='Contact',
        year=datetime.now().year,
        message='Your contact page.'
    )

@app.route('/about')
def about():
    """Renders the about page."""
    return render_template(
        'about.html',
        title='About',
        year=datetime.now().year,
        message='Your application description page.'
    )

