SiteEventFeedbackController

struct SiteEventFeedbackController : SiteControllerUtils
  • Declaration

    Swift

    struct EventFeedbackFormContent : Codable
  • Declaration

    Swift

    func registerRoutes(_ app: Application) throws
  • eventSelector(_:) Asynchronous

    GET /eventfeedback

    Start of the Shadow Event Feedback flow. First page is where the user chooses the event they’re giving feedback on. Current design is that this page isn’t going to have inbound links from the rest of the site; instead the page will usually be accessed via QR code, with a link structured as: “https://twitarr.com/eventfeedback?room=Stuyvesant

    See more

    Declaration

    Swift

    func eventSelector(_ req: Request) async throws -> Response
  • eventFeedbackForm(_:) Asynchronous

    GET /eventfeedback/form/:event_uid

    Takes in a user-selected event ID, returns a page with a feedback form.

    See more

    Declaration

    Swift

    func eventFeedbackForm(_ req: Request) async throws -> View
  • postEventForm(_:) Asynchronous

    POST /eventfeedback/form

    POST for event feedback form.

    Declaration

    Swift

    func postEventForm(_ req: Request) async throws -> HTTPStatus
  • GET /eventfeedback/form/submitted

    Shows the “Feedback Recieved” flow completion page.

    See more

    Declaration

    Swift

    func eventFeedbackFormSubmitted(_ req: Request) async throws -> View
  • getFeedbackRoot(_:) Asynchronous

    Declaration

    Swift

    func getFeedbackRoot(_ req: Request) async throws -> View
  • feedbackReporting(_:) Asynchronous

    GET /admin/eventfeedback/reports GET /admin/eventfeedback/reports/table

    Displays all feedback reports from shadow event hosts, either as a list (with links to individual reports) or a table.

    Query Parameters:

    • location=STRING Filter reports by room name (actually text search; can use partial names)
    • userid=STRING Filter reports by Twitarr userID of the reporter
    See more

    Declaration

    Swift

    func feedbackReporting(_ req: Request) async throws -> View
  • viewReport(_:) Asynchronous

    GET /admin/eventfeedback/report/:report_id

    Displays a single event feedback report.

    See more

    Declaration

    Swift

    func viewReport(_ req: Request) async throws -> View
  • downloadReports(_:) Asynchronous

    GET /admin/eventfeedback/reports/download

    Initiates a download of a .CSV file containing all the Event Feedback Reports.

    See more

    Declaration

    Swift

    func downloadReports(_ req: Request) async throws -> Response
  • POST /admin/eventfeedback/report/:report_id/mark DELETE /admin/eventfeedback/report/:report_id/mark

    Adds or rmoves an ‘actionable’ mark to the specified feedback report. Returns 201/204 on success.

    Declaration

    Swift

    func addRemoveActionableMark(_ req: Request) async throws -> HTTPStatus
  • roomPosterSelector(_:) Asynchronous

    GET /admin/eventfeedback/roomposters

    Displays a form pre-filled with all the room names that are hosting shadow events, scraped from the schedule. After editing, this will go to a print-optimized HTML document with one room poster per page. Each room poster has the name of the room, instructions for the host, and a QR code that goes to the feedback flow. The URL embedded in each QR code has a query option specifying the room name, which allows the event selector page to filter the list of events to those happening in that room.

    See more

    Declaration

    Swift

    func roomPosterSelector(_ req: Request) async throws -> View
  • printRoomPosters(_:) Asynchronous

    POST /admin/eventfeedback/roomposters

    The POST form in the request contents contains a list of all the room names for which to print signs. Returns an HTML page meant to be printed out onto letter-size paper (one sheet per room name), and taped up to the walls of various rooms on the ship.

    The returned page uses special css for printing, but doesn’t contain a ‘Print’ button that opens the print dialog in the browser.

    Each sheet contains a QR Code, and the URL encoded in that QR code

    See more

    Declaration

    Swift

    func printRoomPosters(_ req: Request) async throws -> View
  • Declaration

    Swift

    struct RoomInfo : Encodable