KunalThakare279 commited on
Commit
3a256a2
·
verified ·
1 Parent(s): a944881

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -19,7 +19,7 @@ categories = ['OPEN', 'SC', 'ST', 'VJ', 'NT1', 'NT2', 'NT3', 'OBC', 'DEFOPEN',
19
 
20
  @app.route('/', methods=['GET', 'POST'])
21
  def index():
22
- colleges = []
23
  if request.method == 'POST':
24
  # Get data from the form
25
  marks = float(request.form['marks'])
@@ -32,9 +32,9 @@ def index():
32
 
33
  print(marks, zone, course, category, gender, seat_level, round)
34
  # Call the get_colleges function to predict the list of colleges
35
- colleges = get_colleges(marks, zone, course, category, gender, seat_level, round)
36
 
37
- return render_template('index.html', colleges=colleges, zones = zones, categories = categories, seat_levels = seat_levels)
38
 
39
  @app.route('/get_courses', methods=['POST'])
40
  def get_courses():
 
19
 
20
  @app.route('/', methods=['GET', 'POST'])
21
  def index():
22
+ colleges_data = None
23
  if request.method == 'POST':
24
  # Get data from the form
25
  marks = float(request.form['marks'])
 
32
 
33
  print(marks, zone, course, category, gender, seat_level, round)
34
  # Call the get_colleges function to predict the list of colleges
35
+ colleges_data = get_colleges(marks, zone, course, category, gender, seat_level, round)
36
 
37
+ return render_template('index.html', colleges_data=colleges_data, zones = zones, categories = categories, seat_levels = seat_levels)
38
 
39
  @app.route('/get_courses', methods=['POST'])
40
  def get_courses():