Template:Pledge: Difference between revisions

From London Hackspace Wiki
(revised version (doesn't need talk links))
(box the totals)
 
(One intermediate revision by the same user not shown)
Line 4: Line 4:
{{#if: {{{name1|}}}|
{{#if: {{{name1|}}}|
{{!}}-
{{!}}-
{{!}} [[User:{{{name1}}}|{{{name1}}}]] {{!}}{{!}} £{{{pledge1|}}}
{{!}} [[User:{{{name1}}}|{{{name1}}}]] {{!}}{{!}} £{{{pledge1|}}}|}}
{{#if: {{{name2|}}}|
{{#if: {{{name2|}}}|
{{!}}-
{{!}}-
Line 62: Line 62:
{{!}}-
{{!}}-
{{!}} [[User:{{{name20}}}|{{{name20}}}]] {{!}}{{!}} £{{{pledge20|}}}|}}
{{!}} [[User:{{{name20}}}|{{{name20}}}]] {{!}}{{!}} £{{{pledge20|}}}|}}
|}}
|}}
|}
|}
Target: '''£{{{target|0}}}'''
{| class="wikitable"
 
|-
Total: '''£{{#expr: {{{pledge1|0}}}+{{{pledge2|0}}}+{{{pledge3|0}}}+{{{pledge4|0}}}+{{{pledge5|0}}}+{{{pledge6|0}}}+{{{pledge7|0}}}+{{{pledge8|0}}}+{{{pledge9|0}}}+{{{pledge10|0}}}+{{{pledge11|0}}}+{{{pledge12|0}}}+{{{pledge13|0}}}+{{{pledge14|0}}}+{{{pledge15|0}}}+{{{pledge16|0}}}+{{{pledge17|0}}}+{{{pledge18|0}}}+{{{pledge19|0}}}+{{{pledge20|0}}} }}'''
||Target||'''£{{{target|0}}}'''
 
|-
Needed: '''£{{#expr: {{{target|0}}}-({{{pledge1|0}}}+{{{pledge2|0}}}+{{{pledge3|0}}}+{{{pledge4|0}}}+{{{pledge5|0}}}+{{{pledge6|0}}}+{{{pledge7|0}}}+{{{pledge8|0}}}+{{{pledge9|0}}}+{{{pledge10|0}}}+{{{pledge11|0}}}+{{{pledge12|0}}}+{{{pledge13|0}}}+{{{pledge14|0}}}+{{{pledge15|0}}}+{{{pledge16|0}}}+{{{pledge17|0}}}+{{{pledge18|0}}}+{{{pledge19|0}}}+{{{pledge20|0}}}) }}'''
||Pledged|| '''£{{#expr: {{{pledge1|0}}}+{{{pledge2|0}}}+{{{pledge3|0}}}+{{{pledge4|0}}}+{{{pledge5|0}}}+{{{pledge6|0}}}+{{{pledge7|0}}}+{{{pledge8|0}}}+{{{pledge9|0}}}+{{{pledge10|0}}}+{{{pledge11|0}}}+{{{pledge12|0}}}+{{{pledge13|0}}}+{{{pledge14|0}}}+{{{pledge15|0}}}+{{{pledge16|0}}}+{{{pledge17|0}}}+{{{pledge18|0}}}+{{{pledge19|0}}}+{{{pledge20|0}}} }}'''
|-
||Still required|| '''£{{#expr: {{{target|0}}}-({{{pledge1|0}}}+{{{pledge2|0}}}+{{{pledge3|0}}}+{{{pledge4|0}}}+{{{pledge5|0}}}+{{{pledge6|0}}}+{{{pledge7|0}}}+{{{pledge8|0}}}+{{{pledge9|0}}}+{{{pledge10|0}}}+{{{pledge11|0}}}+{{{pledge12|0}}}+{{{pledge13|0}}}+{{{pledge14|0}}}+{{{pledge15|0}}}+{{{pledge16|0}}}+{{{pledge17|0}}}+{{{pledge18|0}}}+{{{pledge19|0}}}+{{{pledge20|0}}}) }}'''
|}
<noinclude>{{Documentation}}</noinclude>
<noinclude>{{Documentation}}</noinclude>

Latest revision as of 17:39, 1 May 2013

Name Pledged






Target £0
Pledged £0
Still required £0
[view] [edit] [history] [purge] Documentation icon Template documentation

Usage

{{pledge| target=
|name1= | pledge1=
|name2= | pledge2=
|name3= | pledge3=
|name4= | pledge4=
|name5= | pledge5=
}}

This template can currently handle 20 pledges, though it can be extended for more.

Example

{{pledge| target=50
|name1=Joe | pledge1=10
|name2=Jane | pledge2=15
|name3=John | pledge3=5
|name4= | pledge4=
|name5= | pledge5=
}}

will result in this:

Name Pledged
Joe £10
Jane £15
John £5





Target £50
Pledged £30
Still required £20