from __init__ import app
from flask import Flask, render_template, flash
import sqlalchemy as sa
from models import *


@app.route('/')
def index():
    username = sa.select('username'.where) 
    return render_template('home.html', username=username)




@app.route('/products')
def products():
    name = sa.select('name'.where) 
    image = sa.select('image'.where)
    sell = sa.select('sell'.where)
    return render_template('products.html', id=id, name=name, image=image, sell=sell)
    

@app.route('/product/<int:id>')
def product(id):
    name = sa.select('name'.where) 
    image = sa.select('image'.where)
    sell = sa.select('sell'.where)
    return render_template('product.html', id=id, name=name, image=image, sell=sell)
    