kukuminer / ta-app

Online application and selection platform for teaching assistants
0 stars 0 forks source link

Add seniority for unit 2 applicants #69

Open jonatanschroeder opened 10 months ago

jonatanschroeder commented 10 months ago
kukuminer commented 3 months ago

table ( id: serial employeeID: varchar(9) NOT NULL seniority: float NOT NULL )

kukuminer commented 3 months ago
kukuminer commented 3 months ago

@jonatanschroeder I've discovered a bug(?). In the sql query that fetches applicants for a particular section in professor view, it filters by applications to that specific campus (since sections now have a campus. Before we added campuses, it would coalesce 2 (the default interest/qualification) to this value. However, now that we also filter by campus, this value is lost since campus is blank for the coalesced rows.

Basically, in instructor.js at https://github.com/kukuminer/ta-app/blob/7a28bb86c72c9f1b1dafa21ea7b3b0aef29b572e/server/api/instructor.js#L82C1-L83C1

If I keep line 82, it does not show any preferences that were not explicitly stated by the user (no default values, probably a bug). If I remove it, it shows both campuses as separate preferences for the same user in the same section (objectively wrong). I think allowing campus to be blank will fix this, but I want your opinion. We can discuss this in our meeting today if this comment is too wordy or incomprehensible.

jonatanschroeder commented 3 months ago

You can move the test in line 82 to the JOIN condition in line 75.