book_server_api.routers.rslogging module¶
- async book_server_api.routers.rslogging.create_upload_file(request: Request, file: UploadFile, div_id: str)¶
- async book_server_api.routers.rslogging.getAllCompletionStatus(request: Request)¶
- async book_server_api.routers.rslogging.getCompletionStatus(request: Request, lastPageUrl: str, isPtxBook: bool)¶
- async book_server_api.routers.rslogging.getlastpage(request: Request, course: str)¶
- async book_server_api.routers.rslogging.log_book_event(entry: LogItemIncoming, request: Request, user=Depends(LoginManager))¶
This endpoint is called to log information for nearly every click that happens in the textbook. It uses the
LogItemIncoming
object to define the JSON payload it gets from a page of a book.- Parameters:
entry – The JSON payload from the textbook page.
request – The request object.
user – The user object.
- async book_server_api.routers.rslogging.runlog(request: Request, response: Response, data: LogRunIncoming)¶
Make an entry in the Code table to record an activecode run.
- Parameters:
request – A FastAPI Request object
response (JSONResponse) – A FastAPI Response object
data (LogRunIncoming) – the post data
- Returns:
JSONResponse
- async book_server_api.routers.rslogging.same_class(user1: AuthUserValidator, user2: str) bool ¶
- book_server_api.routers.rslogging.set_tz_offset(tzreq: ~rsptx.validation.schemas.TimezoneRequest, RS_info: ~typing.Optional[str] = Cookie(None), response_class=<class 'starlette.responses.JSONResponse'>)¶
Set the timezone offset in the session cookie.
- Parameters:
tzreq – The timezone offset.
RS_info – Cookie defaults to Cookie(None)
response_class – JSONResponse
- Returns:
JSONResponse
- async book_server_api.routers.rslogging.updatelastpage(request: Request, request_data: LastPageDataIncoming, RS_info: Optional[str] = Cookie(None))¶