תבנית:שליפת נתוני משחקים: הבדלים בין גרסאות בדף

מתוך ויקיפועל
קפיצה לניווט קפיצה לחיפוש
אין תקציר עריכה
אין תקציר עריכה
שורה 1: שורה 1:
{{#vardefine:fromday|'{{{מיום}}}'}}
{{#vardefine:oponent|{{החלפת שם יריב שאילתא|יריבה={{{יריבה|}}}}}}}
{{#vardefine:whereclause|
{{#vardefine:whereclause|
{{#ifeq:{{{ליגה}}}|1| liga='1' |{{#ifeq:{{{ליגה}}}|0|liga='0'|liga IS NOT NULL}}}}
{{#ifeq:{{{ליגה}}}|1| liga='1' |{{#ifeq:{{{ליגה}}}|0|liga='0'|liga IS NOT NULL}}}}
שורה 11: שורה 13:
{{#cargo_query:
{{#cargo_query:
tables=Games
tables=Games
|fields=CONCAT(case liga when '1' then 'ליגה' else mifal end),COUNT(*),SUM(case result when '1' then 1 else 0 end),SUM(case result when 'x' then 1 else 0 end),SUM(case result when '0' then 1 else 0 end),SUM(case host when 'הפועל ת"א' then homescore  else 0 end)+SUM(case oponent when 'הפועל ת"א' then awayscore else 0 end),SUM(case host when 'הפועל ת"א' then awayscore  else 0 end)+SUM(case oponent when 'הפועל ת"א' then homescore else 0 end)
|fields=CONCAT(case liga when '1' then 'ליגה' else mifal end),COUNT(*),SUM(case result when '1' then 1 else 0 end),SUM(case result when 'x' then 1 else 0 end),SUM(case result when '0' then 1 else 0 end),SUM(case host when 'הפועל ת"א' then homescore  else 0 end)+SUM(case oponent when 'הפועל ת"א' then awayscore else 0 end),SUM(case host when 'הפועל ת"א' then awayscore  else 0 end)+SUM(case oponent when 'הפועל ת"א' then homescore else 0 end),department,{{#var:fromday}}=fromday,'{{{מחודש}}}'=frommonth,'{{{משנה}}}'=fromyear,'{{{ליום}}}'=today,'{{{לחודש}}}'=tomonth,'{{{לשנה}}}'=toyear,'{{{יריבה}}}'=against
|where={{#var:whereclause}}
|where={{#var:whereclause}}
|format=template
|format=template
|template=שורת מפגשים ראש בראש
|template=שורת מפגשים ראש בראש
|order by=year,month,day
|order by=year,month,day
|rows per page=100
|default=
|default=
}}
}}

גרסה מ־20:51, 4 באוגוסט 2022