User:QuickNick/GoldTrackerSummary

{|class="wikitable" style="text-align:center; border:2px solid #6C93B1; background-color: transparent; width: 100%;" ! scope="col" style="background: #6C93B1;" | ! scope="col" style="background: #6C93B1;" | Count ! scope="col" style="background: #6C93B1;" | Average ! scope="col" style="background: #6C93B1;" | Total {{#ifeq:{{lc:{{{SummaryTypes|}}}}}|y|{{#ifexpr:{{#var:c}}>0| {{!}}- {{#ifeq:{{lc:{{{Summary|}}}}}|y| {{!}} colspan=4 {{!}} {{!}}- }} {{!}} colspan=4 {{!}} Types Summary {{#ifexpr:{{#var:cntach}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Achievements|Count={{#var:cntach}}|Sum={{#var:sumach}}}}}} {{#ifexpr:{{#var:cntads}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Ad Views|Count={{#var:cntads}}|Sum={{#var:sumads}}}}}} {{#ifexpr:{{#var:cntcbuy}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Car Purchase|Count={{#var:cntcbuy}}|Sum={{#var:sumcbuy}}}}}} {{#ifexpr:{{#var:cntcrew}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Agent/Manager/Engineer Hire|Count={{#var:cntcrew}}|Sum={{#var:sumcrew}}}}}} {{#ifexpr:{{#var:cntser}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Career Special Event Reward|Count={{#var:cntcser}}|Sum={{#var:sumcser}}}}}} {{#ifexpr:{{#var:cntcupg}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Car Upgrade|Count={{#var:cntcupg}}|Sum={{#var:sumcupg}}}}}} {{#ifexpr:{{#var:cntcus}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Customization|Count={{#var:cntcus}}|Sum={{#var:sumcus}}}}}} {{#ifexpr:{{#var:cntdc}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Check-In Bonus|Count={{#var:cntdc}}|Sum={{#var:sumdc}}}}}} {{#ifexpr:{{#var:cntdrv}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Drive (Increase or Refill)|Count={{#var:cntdrv}}|Sum={{#var:sumdrv}}}}}} {{#ifexpr:{{#var:cntltsr}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=LTS Reward|Count={{#var:cntltsr}}|Sum={{#var:sumltsr}}}}}} {{#ifexpr:{{#var:cntlvup}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Level Up|Count={{#var:cntlvup}}|Sum={{#var:sumlvup}}}}}} {{#ifexpr:{{#var:cntomp}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Online Multiplayer Reward|Count={{#var:cntomp}}|Sum={{#var:sumomp}}}}}} {{#ifexpr:{{#var:cntser}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Special Event Reward|Count={{#var:cntser}}|Sum={{#var:sumser}}}}}} {{#ifexpr:{{#var:cntsr}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Series Reward|Count={{#var:cntsr}}|Sum={{#var:sumsr}}}}}} {{#ifexpr:{{#var:cntsk}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Skip|Count={{#var:cntsk}}|Sum={{#var:sumsk}}}}}} {{#ifexpr:{{#var:cntsvc}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Service (Increase Mechanics or Reduce Time)|Count={{#var:cntsvc}}|Sum={{#var:sumsvc}}}}}} {{#ifexpr:{{#var:cnttr}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Team Reward|Count={{#var:cnttr}}|Sum={{#var:sumtr}}}}}} {{#ifexpr:{{#var:cntwttt}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=Weekly Time Trial Tournament Reward|Count={{#var:cntwttt}}|Sum={{#var:sumwttt}}}}}} {{#ifexpr:{{#var:cntUNKNOWN}}>0|{{User:QuickNick/R/GoldTrackerSummary|Align=left|Text=UNKNOWN|Count={{#var:cntUNKNOWN}}|Sum={{#var:sumUNKNOWN}}}}}} }} {{End}}

NOTE: There is an issue in the Types Summary caused by conditional displaying of only the Types which appear in the ledger which results in unwanted paragraphs/lines being output in some of the cells.



It works ok if I display all Types but that seems rather OTT! I am looking into it. Nick

Examples

No Summary {{T/GoldTracker}} {{H/GoldTracker}} {{R/GoldTracker|Date=30-Dec-2017|Type=SB|Gold=1000}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ads|Gold=5}} {{R/GoldTracker|Date=31-Dec-2017|Type=CBuy|Text=McLaren MP4/4 using 40% Discount|Gold=-570}} {{T/GoldTracker}}

Summary {{T/GoldTracker|Summary=Y}} {{H/GoldTracker}} {{R/GoldTracker|Date=30-Dec-2017|Type=SB|Gold=1000}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ads|Gold=5}} {{R/GoldTracker|Date=31-Dec-2017|Type=CBuy|Text=McLaren MP4/4 using 40% Discount|Gold=-570}} {{T/GoldTracker}} {{User:QuickNick/GoldTrackerSummary|Summary=Y}}

Types Summary {{T/GoldTracker|SummaryTypes=Y}} {{H/GoldTracker}} {{R/GoldTracker|Date=30-Dec-2017|Type=SB|Gold=1000}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ads|Gold=5}} {{R/GoldTracker|Date=31-Dec-2017|Type=CBuy|Text=McLaren MP4/4 using 40% Discount|Gold=-570}} {{T/GoldTracker}} {{User:QuickNick/GoldTrackerSummary|SummaryTypes=Y}}

Summary and Types Summary {{T/GoldTracker|Summary=Y|SummaryTypes=Y}} {{H/GoldTracker}} {{R/GoldTracker|Date=30-Dec-2017|Type=SB|Gold=1000}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ach|Gold=10}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ads|Gold=5}} {{R/GoldTracker|Date=31-Dec-2017|Type=cbuy|Gold=-10}} {{R/GoldTracker|Date=31-Dec-2017|Type=crew|Gold=-10}} {{R/GoldTracker|Date=31-Dec-2017|Type=Wibble|Text=Wibbly wobbly!|Gold=25}} {{R/GoldTracker|Date=31-Dec-2017|Type=cser|Gold=10}} {{R/GoldTracker|Date=31-Dec-2017|Type=cupg|Gold=-10}} {{R/GoldTracker|Date=31-Dec-2017|Type=cus|Gold=-10}} {{R/GoldTracker|Date=31-Dec-2017|Type=Wobble|Text=Wobbly wibbly!|Gold=25}} {{R/GoldTracker|Date=31-Dec-2017|Type=Ads|Gold=5}}

{{T/GoldTracker}} {{User:QuickNick/GoldTrackerSummary|Summary=Y|SummaryTypes=Y}}

Types {{R/GoldTrackerTypes}}