$def with (products,bag,sessionkey,productname,inbag,db,getprice,getrate,category,markdown) $ totsats = 0 $ toteuro = 0 $ x = 0 $if sessionkey != 'empty':
in your cart:
$for i in bag: $code: price = getprice(i.product) quantity = i.quantity p_totsats=i.quantity*price[0] p_toteuro=i.quantity*price[1] $i.quantity x $productname(i.product) $p_toteuro€ remove
$code: totsats += p_totsats toteuro += p_toteuro $if totsats > 0: total: $toteuro €
Checkout 🛒 -->
~
$ siteconfig = db.select('siteconfig', what='id, name, description, description2')[0] $ categories = db.select('categories', what='id, category')

~*~


$siteconfig.name

$:markdown.markdown(siteconfig.description) $:markdown.markdown(siteconfig.description2)
All $for c in categories: | $c.category

$for i in products: $if category == i.category or category == None: $if i.available > 0:
~*~

$i.name

$i.category


$ goodies = db.query("SELECT * FROM soundlink WHERE id='" +i.id+"';") $for g in goodies: $if g.soundname[-5:] == '.jpeg' or g.soundname[-4:] == '.png':

$code: sat, euro = getprice(i.id) $:markdown.markdown(i.description) product: $i.name
category: $i.category

$if i.available > 0: Price $euro € add to cart
Available $i.available pcs $else: SOLD OUT! check back later.

~-~

powered by thiswebshoprules and web.py