Template:Infobox Recipe: Difference between revisions

no edit summary
No edit summary
Tag: Manual revert
No edit summary
Line 21:
{{!}} [[{{{mat1}}}]]
{{!}} style="text-align: right;" {{!}} {{{mat1qty|1}}}
{{!}} style="text-align: right;" {{!}} {{formatnum:Currency|{{#vardefineecho:mat1total|{{#expr:{{{mat1qty|1}}} * {{#if:{{#var:mat1cost}}|{{#var:mat1cost}}|0}}}}}}}}
{{!}}-
}}
Line 28:
{{!}} [[{{{mat2}}}]]
{{!}} style="text-align: right;" {{!}} {{{mat2qty|1}}}
{{!}} style="text-align: right;" {{!}} {{formatnum:Currency|{{#vardefineecho:mat2total|{{#expr:{{{mat2qty|1}}} * {{#if:{{#var:mat2cost}}|{{#var:mat2cost}}|0}}}}}}}}
{{!}}-
}}
! colspan="3" | Total cost
| style="text-align: right;" {{!}} {{formatnum:Currency|{{#vardefineecho:totalcost|{{#expr:{{#varexists:mat1total|{{#var:mat1total}}|0}} + {{#varexists:mat2total|{{#var:mat2total}}|0}}}}}}}}
|-
! colspan="2" | Ouput
Line 41:
{{!}} [[{{{output1}}}]]
| style="text-align: right;" {{!}} {{{output1qty|1}}}
| style="text-align: right;" {{!}} {{formatnum:Currency|{{#vardefineecho:output1costtotal|{{#expr:{{{output1qty|1}}} * {{#if:{{#var:output1cost}}|{{#var:output1cost}}|0}}}}}}}}
|-
! colspan="3" | Profit
| style="text-align: right;" {{!}} {{formatnum:Currency|{{#expr:{{#var:output1costtotal}} - {{#var:totalcost}}}}}}
|}