Loan result
This commit is contained in:
+5
-3
@@ -160,7 +160,7 @@ def salary_demousers():
|
|||||||
return {
|
return {
|
||||||
"demo_data": result_demo_data,
|
"demo_data": result_demo_data,
|
||||||
}, 200
|
}, 200
|
||||||
|
|
||||||
|
|
||||||
# VARCHAR(125),
|
# VARCHAR(125),
|
||||||
# offers INT DEFAULT 0,
|
# offers INT DEFAULT 0,
|
||||||
@@ -245,14 +245,16 @@ def salary_loanselect2():
|
|||||||
# validate input
|
# validate input
|
||||||
loan = data["loan"]
|
loan = data["loan"]
|
||||||
bvn = data["bvn"]
|
bvn = data["bvn"]
|
||||||
|
print ("here - 001 ")
|
||||||
if loan != '' and bvn != '' :
|
if loan != '' and bvn != '' :
|
||||||
loan = load_offer(loan,bvn)
|
print ("here - 002 ")
|
||||||
|
loan_result = load_offer(loan,bvn)
|
||||||
INSERT_LOAN ="INSERT INTO loan_select (loan, bvn) VALUES(%s, %s)"
|
INSERT_LOAN ="INSERT INTO loan_select (loan, bvn) VALUES(%s, %s)"
|
||||||
new_data = (loan,bvn)
|
new_data = (loan,bvn)
|
||||||
with connection:
|
with connection:
|
||||||
with connection.cursor(cursor_factory=psycopg2.extras.DictCursor) as cursor:
|
with connection.cursor(cursor_factory=psycopg2.extras.DictCursor) as cursor:
|
||||||
cursor.execute(INSERT_LOAN, new_data)
|
cursor.execute(INSERT_LOAN, new_data)
|
||||||
|
print ("here - 003 ")
|
||||||
return {
|
return {
|
||||||
"message": "REQUEST_AMOUNT",
|
"message": "REQUEST_AMOUNT",
|
||||||
"loan": loan,
|
"loan": loan,
|
||||||
|
|||||||
Reference in New Issue
Block a user