def getlist(): cur = DictCursor(mysql.get_db()) cur.execute("SELECT * FROM attend;") return jsonify(cur.fetchall())
def record_callback_fetch_all(cursor: DictCursor): return cursor.fetchall()
def getpayment(): cur = DictCursor(mysql.get_db()) cur.execute( "SELECT id,stu_name,stu_unit,price FROM attend WHERE paid=0 AND attendance=1;" ) return dumps(cur.fetchall(), ensure_ascii=False)