057
This commit is contained in:
parent
5b351712a4
commit
e39e69fb47
BIN
db5.sqlite3
BIN
db5.sqlite3
Binary file not shown.
13
src/a3.nim
13
src/a3.nim
@ -208,8 +208,6 @@ import
|
||||
productName = form.getOrDefault("prod", "")
|
||||
quantity = parseInt(form.getOrDefault("quantity", "0"))
|
||||
|
||||
echo productName
|
||||
|
||||
var
|
||||
country = form["c_country"]
|
||||
firstName = form["c_fname"]
|
||||
@ -220,16 +218,12 @@ import
|
||||
email1 = form["c_email_address"]
|
||||
phone = form["c_phone"]
|
||||
password1: string
|
||||
|
||||
echo 3
|
||||
|
||||
password1 = form.getOrDefault("password", "")
|
||||
|
||||
if email != "":
|
||||
productCount = micsCartProductCount(email, password)
|
||||
|
||||
echo 4
|
||||
|
||||
if country != "" and firstName != "" and lastName != "" and address != "" and state != "" and zip != "" and email != "" and phone != "":
|
||||
var
|
||||
userId = db.getUserId(email, password)
|
||||
@ -263,8 +257,6 @@ import
|
||||
ctx.send(sendThankYou())
|
||||
|
||||
else:
|
||||
|
||||
echo 5
|
||||
|
||||
for a, b in form:
|
||||
if form[a] == "":
|
||||
@ -278,8 +270,6 @@ import
|
||||
val.mark = ""
|
||||
validity[a] = val
|
||||
|
||||
echo productName
|
||||
|
||||
if productName == "":
|
||||
var
|
||||
userId = db.getUserId(email, password)
|
||||
@ -295,11 +285,8 @@ import
|
||||
ca: Cart
|
||||
|
||||
product.id = 1
|
||||
echo product
|
||||
product.name = productName
|
||||
echo product
|
||||
product.price = db.getPriceByProductName(productName)
|
||||
echo product
|
||||
ca.quantity = quantity
|
||||
products.add(product)
|
||||
cart.add(ca)
|
||||
|
Loading…
Reference in New Issue
Block a user