Skip to content
Snippets Groups Projects
  1. Sep 23, 2016
  2. Sep 21, 2016
  3. Sep 20, 2016
  4. Sep 16, 2016
  5. Sep 15, 2016
  6. Sep 14, 2016
  7. Sep 13, 2016
  8. Sep 12, 2016
  9. Sep 06, 2016
  10. Sep 05, 2016
    • Vytor Calixto's avatar
      Merge branch 'refactor_enrollments' into 'development' · 12645f17
      Vytor Calixto authored
      Refactor enrollments route to include query building
      
      Changes:
      - Add error handling in the database query function. When a database error
      occurs, it is logged in the server and a plain text response is returned to the
      user.
      - Implement building of SQL queries inside the API, which removes the
        need to have stored functions/procedures on the database, since the former
      approach is not flexible or efficient to maintain/extend.
      - Use route chaining to determine which function will build the query
        that needs to be executed. The last function is the one that actually
        sends the query to the database and send the response.
      
      Future Work:
      - Instead of returning a plain text response, return a HTTP 501 status,
        which is currently not possible. When one attempts to send such status
        the framework throws an error that the headers were already sent for
        the current request.
      - Chaining based on the route might not be the best solution here.
      
      See merge request !7
      12645f17
    • João Victor Tozatti Risso's avatar
Loading