PDF results engine

This is set of functions, consts and global variables to get data from system that can be printed out using pdf

Table of contents
  1. doc
  2. regularText
  3. boldText
  4. findExtremeByProp
  5. Table
  6. fileName
  7. moment
  8. game
  9. customData
  10. tl
  11. tg

doc

pdfkit document


regularText

font of regular text


boldText

font of bold text


findExtremeByProp

find max or min from players data

Params

  • players - IEvPlayers[] list of players game.result.evaluationPlayers
  • attr - key of IEvPlayers
  • findMin - optionally parameter by default max is searched if min required use true

Usage

 const {extreme: playerPrecision, playerName, playerIndex} = findExtremeByProp(
   game.result.evaluationPlayers, "playerPrecision")

Table

class for helping generate table TODO: document class


fileName

random generated filename


moment

moment package


game

whole QueueGame object selected from database


customData

extracted template customData


tl

translate function for local template translations


tg

translate function for global translations