diff --git a/services/web/project/__init__.py b/services/web/project/__init__.py index 730b00d..0db3a0f 100644 --- a/services/web/project/__init__.py +++ b/services/web/project/__init__.py @@ -227,13 +227,22 @@ def start_register(): lastname= data.get('lastname') email= data.get('email') +# mycursor = mydb.cursor() +# +# sql = "INSERT INTO customers (name, address) VALUES (%s, %s)" +# val = ("John", "Highway 21") +# mycursor.execute(sql, val) +# +# mydb.commit() INSERT_MEMBERS = "INSERT INTO members_pending(email,firstname,lastname) VALUES('"+firstname+"','"+lastname+"','"+email+"')" with connection: with connection.cursor(cursor_factory=psycopg2.extras.DictCursor) as cursor: cursor.execute(INSERT_MEMBERS) - return jsonify(hello="ameye signup path world") + last_row_id=cursor.cursor + + return jsonify(hello="ameye signup path world", last_row_id=last_row_id) except Exception as e: return {