Jump to content

Module:Sports table/Rugby/doc

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by WOSlinker (talk | contribs) at 10:45, 10 May 2023 (syntaxhighlight lang="wikitext"). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

This style for Lua-based Module:Sports table is meant to build group and league tables for rugby competitions with the following optional columns

  1. Played / Wins / Draws / Losses
  2. Points for / Points against / Point difference
  3. Tries for / Tries against
  4. Try bonus points
  5. Loss bonus points
  6. Competition points

The input syntax for this module is similar to the WDL module, but specialized for Rugby competitions.

Usage

Basic usage

In its simplest form only several parameters need to be used to build a table

What you type
{{#invoke:sports table|main|style=Rugby
| res_col_header = Q
| title = Wikipedia Cup
| team1 = AAA | name_AAA = Team AAA
| team2 = BBB | name_BBB = Team BBB
| team3 = CCC | name_CCC = Team CCC
| team4 = DDD | name_DDD = Team DDD
| team5 = EEE | name_EEE = Team EEE
| team6 = FFF | name_FFF = Team FFF
| team7 = GGG | name_GGG = Team GGG
| team8 = HHH | name_HHH = Team HHH
| win_AAA = 10 | draw_AAA =0| loss_AAA =4| pf_AAA =492| pa_AAA =300| tf_AAA =62| ta_AAA =30| tbp_AAA =9 | lbp_AAA =3
| win_BBB = 10 | draw_BBB =0| loss_BBB =4| pf_BBB =520| pa_BBB =280| tf_BBB =59| ta_BBB =28| tbp_BBB =6 | lbp_BBB =2
| win_CCC = 10 | draw_CCC =0| loss_CCC =4| pf_CCC =488| pa_CCC =323| tf_CCC =60| ta_CCC =33| tbp_CCC =6 | lbp_CCC =1
| win_DDD = 9 | draw_DDD =0| loss_DDD =5| pf_DDD =437| pa_DDD =374| tf_DDD =49| ta_DDD =39| tbp_DDD =6 | lbp_DDD =5
| win_EEE = 7 | draw_EEE =0| loss_EEE =7| pf_EEE =401| pa_EEE =407| tf_EEE =45| ta_EEE =46| tbp_EEE =7 | lbp_EEE =4
| win_FFF = 6 | draw_FFF =0| loss_FFF =8| pf_FFF =477| pa_FFF =496| tf_FFF =60| ta_FFF =61| tbp_FFF =10 | lbp_FFF =3
| win_GGG = 4 | draw_GGG =0| loss_GGG =10| pf_GGG =329| pa_GGG =573| tf_GGG =45| ta_GGG =78| tbp_GGG =6 | lbp_GGG =1
| win_HHH = 0 | draw_HHH =0| loss_HHH =14| pf_HHH =263| pa_HHH =654| tf_HHH =30| ta_HHH =93| tbp_HHH =2 | lbp_HHH =3
| class_rules = 4 points for a win; 2 points for a draw; 1 bonus point for a loss by seven points or less; 1 bonus point for scoring four or more tries in a match
| col_SF = green2 | text_SF = Title Play-Off Semi-Final
| result1 = SF | result2 = SF | result3 = SF | result4 = SF
| col_RP = red2 | text_RP = Promotion/Relegation Play-Off
| result7 = RP | result8 = RP
| update =complete|source=example.com
}}
What it looks like
Wikipedia Cup
Pos Team Pld W D L PF PA PD TF TA TB LB Pts Qualification
1 Team AAA 14 10 0 4 492 300 +192 62 30 0 0 40 Title Play-Off Semi-Final
2 Team BBB 14 10 0 4 520 280 +240 59 28 0 0 40
3 Team CCC 14 10 0 4 488 323 +165 60 33 0 0 40
4 Team DDD 14 9 0 5 437 374 +63 49 39 0 0 36
5 Team EEE 14 7 0 7 401 407 −6 45 46 0 0 28
6 Team FFF 14 6 0 8 477 496 −19 60 61 0 0 24
7 Team GGG 14 4 0 10 329 573 −244 45 78 0 0 16 Promotion/Relegation Play-Off
8 Team HHH 14 0 0 14 263 654 −391 30 93 0 0 0
Source: example.com
Rules for classification: 4 points for a win; 2 points for a draw; 1 bonus point for a loss by seven points or less; 1 bonus point for scoring four or more tries in a match

Additional parameters

  1. To hide the "bonus points" columns, use |show_bonus=no
  2. To hide the "draws" column, use |show_draw=no
  3. To hide the "tries for" column, use |show_tries_for=no
  4. To hide the "tries against" column, use |show_tries_against=no
  5. To add "points carried forward" to the next round, use |show_cf=yes
  6. To override the default number of "win points", use |winpoints=
  7. To override the default number of "draw points", use |drawpoints=
  8. To override the default number of "loss points", use |losspoints=