Difference between revisions of "Template:Suit"
From cm2.liecourt.com
(Fill database) |
(Fill database) |
||
Line 211: | Line 211: | ||
{{#vardefine:@type|{{#show:{{{Workflow|}}}|?Type|link=none}} }} | {{#vardefine:@type|{{#show:{{{Workflow|}}}|?Type|link=none}} }} | ||
− | <div class="row"><div class="col-12 col-lg-8">{{#tag:html|<h1><span>{{{Title|}}}</span><!--<span>{{#widget:link|text=Suit history|href=#|type=a|class=btn-green}}</span>--></h1>}} | + | <div class="row"><div class="col-12 col-lg-8 box">{{#tag:html|<h1><span>{{{Title|}}}</span><!--<span>{{#widget:link|text=Suit history|href=#|type=a|class=btn-green}}</span>--></h1>}} |
<div class="suit-info">{{Item responsive |Cols={{#var:@cols|4-8}} | <div class="suit-info">{{Item responsive |Cols={{#var:@cols|4-8}} | ||
|1=<b>Case ID</b> | |1=<b>Case ID</b> | ||
Line 227: | Line 227: | ||
{{Item responsive |Cols={{#var:@cols|4-8}} | {{Item responsive |Cols={{#var:@cols|4-8}} | ||
|1=<b>Number of Jurors</b> | |1=<b>Number of Jurors</b> | ||
− | |2={{#arraydefine:@jurors|{{#explode:{{#var:@workflow}}|<PROP>|5}} }}{{#arraysize:@jurors}} / {{#explode:{{#var:@workflow}}|<PROP>|6}} accepted | + | |2={{#arraydefine:@jurors|{{#explode:{{#var:@workflow}}|<PROP>|5}}|<MANY>}}{{#arraysize:@jurors}} / {{#explode:{{#var:@workflow}}|<PROP>|6}} accepted |
}} | }} | ||
− | <br></div></div><div class="col-12 col-lg-4">{{#if:{{CURRENTLOGGEDUSER}}|{{#if:{{#vardefineecho:@participantpage|{{#ask:[[Class::Participant]][[Workflow::{{{Workflow|}}}]][[User::User:{{CURRENTLOGGEDUSER}}]]|link=none}} }}|<!-- | + | <br></div></div><div class="col-12 col-lg-4 ">{{#if:{{CURRENTLOGGEDUSER}}|{{#if:{{#vardefineecho:@participantpage|{{#ask:[[Class::Participant]][[Workflow::{{{Workflow|}}}]][[User::User:{{CURRENTLOGGEDUSER}}]]|link=none}} }}|<!-- |
-->{{#vardefine:@participantrole|{{#show:{{#var:@participantpage}}|?Role|link=none}} }}<div class="info-box "> | -->{{#vardefine:@participantrole|{{#show:{{#var:@participantpage}}|?Role|link=none}} }}<div class="info-box "> | ||
<h2>{{#switch:{{#var:@participantrole}}|Juror={{Fa|balance-scale}}|Judge={{Fa|gavel}}|Plaintiff={{fa|book}} }}</h2> | <h2>{{#switch:{{#var:@participantrole}}|Juror={{Fa|balance-scale}}|Judge={{Fa|gavel}}|Plaintiff={{fa|book}} }}</h2> | ||
Line 251: | Line 251: | ||
{{#ifeq:{{#var:@type}}|Class| | {{#ifeq:{{#var:@type}}|Class| | ||
{{#arraydefine:@cases|{{#show:{{{Workflow|}}}|?Class case IDs|link=none}} }}<!-- | {{#arraydefine:@cases|{{#show:{{{Workflow|}}}|?Class case IDs|link=none}} }}<!-- | ||
− | --><h1>Class information</h1>{{#if:{{#ask:[[Class::Verdict]][[Workflow::{{{Workflow|}}}]][[Role::Judge]]}}| | + | --><h1>Class information</h1>{{#if:{{#ask:[[Class::Verdict]][[Workflow::{{{Workflow|}}}]][[Role::Judge]]}}|<br><!-- |
− | |||
− | |||
--><ul class="nav nav-tabs"><!-- | --><ul class="nav nav-tabs"><!-- | ||
--><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | --><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | ||
Line 266: | Line 264: | ||
-->{{verdict results|id={{{Case ID|}}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | -->{{verdict results|id={{{Case ID|}}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | ||
--></div>|}}<!-- | --></div>|}}<!-- | ||
− | --></div> | + | --></div> }} |
<h1>Cases</h1> | <h1>Cases</h1> | ||
<h2>This Class suit contains {{#arraysize:@cases}} cases</h2> | <h2>This Class suit contains {{#arraysize:@cases}} cases</h2> | ||
Line 285: | Line 283: | ||
}}<!-- | }}<!-- | ||
--><div class="row"> | --><div class="row"> | ||
− | <div class="col-lg-8 col-12"> | + | <div class="col-lg-8 col-12 box mt-0"> |
<h2>The Case</h2> | <h2>The Case</h2> | ||
{{Item responsive |Cols=4-8 | {{Item responsive |Cols=4-8 | ||
Line 305: | Line 303: | ||
{{Item responsive |Cols=4-8 | {{Item responsive |Cols=4-8 | ||
|1=<b>Evidence of lie appearance:</b>{{#vardefine:@uuid|{{#show:{{{Workflow|}}}|?uuid|link=none}} }} | |1=<b>Evidence of lie appearance:</b>{{#vardefine:@uuid|{{#show:{{{Workflow|}}}|?uuid|link=none}} }} | ||
− | |2={{#vardefine:@counter|0}}{{#arraymap:{{#ask:[[Class::Case file]][[Case file::{{#var:@uuid}}]]|?=|?Modification date|?Type|Format=array|link=none}}|,|@@@|{{#widget:link |type=a|href=#image-modal-{{#var:@counter}} |datatoggle=modal |class=attachment |text={{#ifeq:{{#explode:@@@|<PROP>|2}}|pdf|{{fa|file-pdf}}|{{fa|image}} }} }}<!-- | + | |2={{#vardefine:@counter|0}}{{#if:{{#var:@uuid}}|{{#arraymap:{{#ask:[[Class::Case file]][[Case file::{{#var:@uuid}}]]|?=|?Modification date|?Type|Format=array|link=none}}|,|@@@|{{#widget:link |type=a|href=#image-modal-{{#var:@counter}} |datatoggle=modal |class=attachment |text={{#ifeq:{{#explode:@@@|<PROP>|2}}|pdf|{{fa|file-pdf}}|{{fa|image}} }} }}<!-- |
-->{{Modal | -->{{Modal | ||
Line 316: | Line 314: | ||
}}<!-- | }}<!-- | ||
− | -->{{#vardefine:@counter|{{#expr:{{#var:@counter}} + 1}} }} |}} | + | -->{{#vardefine:@counter|{{#expr:{{#var:@counter}} + 1}} }} }}|}} |
}} | }} | ||
</div> | </div> | ||
− | <div class="col- | + | <div class="col-12 col-lg-4 mt-0"> |
− | + | <div class="box"> | |
− | <div class=" | ||
<h2>Lie locations</h2> | <h2>Lie locations</h2> | ||
{{#arraymap:{{#explode:{{#var:@workflow}}|<PROP>|9}}|,|@@@| | {{#arraymap:{{#explode:{{#var:@workflow}}|<PROP>|9}}|,|@@@| | ||
Line 329: | Line 326: | ||
}} | }} | ||
|}} | |}} | ||
+ | </div> | ||
</div> | </div> | ||
</div> | </div> | ||
<!-- | <!-- | ||
− | --><br> | + | --><br>{{#if:{{#ask:[[Class::Verdict]][[Workflow::{{#explode:{{#var:@workflow}}|<PROP>|0}}]][[Role::Judge]]}}|<br><!-- |
− | |||
− | |||
--><ul class="nav nav-tabs"><!-- | --><ul class="nav nav-tabs"><!-- | ||
--><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | --><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | ||
Line 347: | Line 343: | ||
-->{{verdict results|id={{#explode:{{#var:@workflow}}|<PROP>|2}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | -->{{verdict results|id={{#explode:{{#var:@workflow}}|<PROP>|2}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | ||
--></div>|}}<!-- | --></div>|}}<!-- | ||
− | --></div> | + | --></div> }}<!-- |
--></div><!-- | --></div><!-- | ||
Line 354: | Line 350: | ||
| | | | ||
<div class="row"> | <div class="row"> | ||
− | <div class="col-12 col-lg-8"> | + | <div class="col-12 col-lg-8 box mt-0"> |
<h2>The Case</h2> | <h2>The Case</h2> | ||
{{Item responsive |Cols=4-8 | {{Item responsive |Cols=4-8 | ||
Line 374: | Line 370: | ||
{{Item responsive |Cols=4-8 | {{Item responsive |Cols=4-8 | ||
|1=<b>Evidence of lie appearance</b>{{#vardefine:@uuid|{{#show:{{{Workflow|}}}|?uuid|link=none}} }} | |1=<b>Evidence of lie appearance</b>{{#vardefine:@uuid|{{#show:{{{Workflow|}}}|?uuid|link=none}} }} | ||
− | |2={{#vardefine:@counter|0}}{{#arraymap:{{#ask:[[Class::Case file]][[Case file::{{#var:@uuid}}]]|?=|?Modification date|?Type|Format=array|link=none}}|,|@@@|{{#widget:link |type=a|href=#image-modal-{{#var:@counter}} |datatoggle=modal |class=attachment |text={{#ifeq:{{#explode:@@@|<PROP>|2}}|pdf|{{fa|file-pdf}}|{{fa|image}} }} }}<!-- | + | |2={{#vardefine:@counter|0}}{{#if:{{#var:@uuid}}|{{#arraymap:{{#ask:[[Class::Case file]][[Case file::{{#var:@uuid}}]]|?=|?Modification date|?Type|Format=array|link=none}}|,|@@@|{{#widget:link |type=a|href=#image-modal-{{#var:@counter}} |datatoggle=modal |class=attachment |text={{#ifeq:{{#explode:@@@|<PROP>|2}}|pdf|{{fa|file-pdf}}|{{fa|image}} }} }}<!-- |
-->{{Modal | -->{{Modal | ||
Line 385: | Line 381: | ||
}}<!-- | }}<!-- | ||
− | -->{{#vardefine:@counter|{{#expr:{{#var:@counter}} + 1}} }} |}} | + | -->{{#vardefine:@counter|{{#expr:{{#var:@counter}} + 1}} }} |}} }} |
}} | }} | ||
</div> | </div> | ||
− | <div class="col- | + | <div class="col-12 col-lg-4"> |
− | + | <div class="box mt-0"> | |
− | <div class=" | ||
<h2>Lie locations</h2> | <h2>Lie locations</h2> | ||
{{#arraymap:{{#explode:{{#var:@workflow}}|<PROP>|2}}|,|@@@| | {{#arraymap:{{#explode:{{#var:@workflow}}|<PROP>|2}}|,|@@@| | ||
Line 401: | Line 396: | ||
</div> | </div> | ||
</div> | </div> | ||
− | < | + | </div><!-- |
− | < | + | -->{{#if:{{#ask:[[Class::Verdict]][[Workflow::{{{Workflow|}}}]][[Role::Judge]]}}|<div class="row"><div class="col-12 box"><h2>Settlement records</h2><br><!-- |
− | |||
--><ul class="nav nav-tabs"><!-- | --><ul class="nav nav-tabs"><!-- | ||
--><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | --><li class="active nav-item">{{#widget:link|datatoggle=pill|href=#mainid|text=Verdicts|type=a|class=nav-link active}}</li> | ||
Line 416: | Line 410: | ||
-->{{verdict results|id={{{Case ID|}}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | -->{{verdict results|id={{{Case ID|}}}|Context={{#explode:@@@|<PROP>|1}}}}<!-- | ||
--></div>|}}<!-- | --></div>|}}<!-- | ||
− | --></div> | + | --></div></div></div> }}<!-- |
-->}}<!-- end if class | -->}}<!-- end if class | ||
Revision as of 09:42, 14 August 2020
This is the Suit template. It should be called in the following format:
{{Suit |Case ID= |Title= |Workflow= }}