Class: SessionsController

SessionsController()

HTTP handlers for sessions.

Constructor

new SessionsController()

Source:

Members

formValidation :Array.<express.RequestHandler>

Validation for the session management form. Field rules run for create and update only, and new sessions cannot be dated before today.

Type:
  • Array.<express.RequestHandler>
Source:

routes :express.Router

Type:
  • express.Router
Source:

Methods

(async, static) create()

Source:

(async, static) delete()

Source:

(async, static) getById()

Source:

(static) handleSessionManagement()

Creates, updates or deletes a session from the validated management form.

Source:

(async, static) list()

Source:

(async, static) update()

Source:

(static) viewSessionManagement()

Renders the session management page with sessions for the next seven days, filtered by search term and trainer, and loads the session in the URL into the edit form.

Source: