Difference between revisions of "Template:User"

From cm2.liecourt.com
Line 264: Line 264:
 
<div class="info-row"><b>Reason</b>{{#explode:@@@|<PROP>|12}}</div>}}
 
<div class="info-row"><b>Reason</b>{{#explode:@@@|<PROP>|12}}</div>}}
 
{{#tag:wsform|<h2>Reason for decline</h2>  
 
{{#tag:wsform|<h2>Reason for decline</h2>  
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Random judge|value={{#ask:[[User group::icol-user]][[Class::Member]]{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}[[!{{#explode:@@@|<PROP>|2}}]][[!{{FULLPAGENAME}}]][[Role::Judge]]|Limit=1|searchlabel=-|format=array|order=random}}}}
+
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Random judge|value={{#ask:[[User group::icol-user]][[Class::Member]]{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}[[!{{#explode:@@@|<PROP>|2}}]][[!{{FULLPAGENAME}}]][[Role::Judge]]|Limit=1|searchlabel=|format=array|order=random}}}}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Declined judge|value={{#if:{{#explode:@@@|<PROP>|1}}|{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|@@@|,}}, {{FULLPAGENAME}}| {{FULLPAGENAME}} }} }}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Declined judge|value={{#if:{{#explode:@@@|<PROP>|1}}|{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|@@@|,}}, {{FULLPAGENAME}}| {{FULLPAGENAME}} }} }}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Reason for judge decline}}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}} }}|template=Workflow|formfield=Reason for judge decline}}
Line 298: Line 298:
 
<div class="d-flex justify-content-center pb-4">
 
<div class="d-flex justify-content-center pb-4">
 
{{#tag:wsform| {{#arraydefine:@random juror|{{#explode:@@@|<PROP>|13}}|<MANY>}}{{#arraydefine:@user|{{FULLPAGENAME}} }}{{#arraydiff:new_key|@random juror|@user}}
 
{{#tag:wsform| {{#arraydefine:@random juror|{{#explode:@@@|<PROP>|13}}|<MANY>}}{{#arraydefine:@user|{{FULLPAGENAME}} }}{{#arraydiff:new_key|@random juror|@user}}
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value={{#if:{{#arrayprint:new_key}}| {{#arrayprint:new_key}}, }}{{#ask:[[User group::icol-user]][[Class::Member]][[!{{FULLPAGENAME}}]][[Role::Juror]][[!{{#explode:@@@|<PROP>|12}}]]{{#arraymap:{{#explode:@@@|<PROP>|13}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|11}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}|searchlabel=-|Limit={{#expr:{{#explode:@@@|<PROP>|10}} {{#if:{{#arrayprint:new_key}}|- {{#arraysize:new_key}}| - 0 }} }}|format=array|order=random}} }}
+
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value={{#if:{{#arrayprint:new_key}}| {{#arrayprint:new_key}}, }}{{#ask:[[User group::icol-user]][[Class::Member]][[!{{FULLPAGENAME}}]][[Role::Juror]][[!{{#explode:@@@|<PROP>|12}}]]{{#arraymap:{{#explode:@@@|<PROP>|13}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|11}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}|searchlabel=|Limit={{#expr:{{#explode:@@@|<PROP>|10}} {{#if:{{#arrayprint:new_key}}|- {{#arraysize:new_key}}| - 0 }} }}|format=array|order=random}} }}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Declined juror|value={{#if:{{#explode:@@@|<PROP>|1}}|{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|@@@|,}}, {{FULLPAGENAME}}| {{FULLPAGENAME}} }} }}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Declined juror|value={{#if:{{#explode:@@@|<PROP>|1}}|{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|@@@|,}}, {{FULLPAGENAME}}| {{FULLPAGENAME}} }} }}
 
{{#ifexpr:{{#arraysize:@jurrors}} < {{#explode:@@@|<PROP>|10}}|
 
{{#ifexpr:{{#arraysize:@jurrors}} < {{#explode:@@@|<PROP>|10}}|
Line 316: Line 316:
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value=done}}
 
{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value=done}}
 
  {{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Stage|value=In progress}}|<!--  
 
  {{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Stage|value=In progress}}|<!--  
  -->{{#arraydefine:@random juror|{{#explode:@@@|<PROP>|13}}|<MANY>}}{{#arraydefine:@user|{{FULLPAGENAME}} }}{{#arraydiff:new_key|@random juror|@user}}{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value={{#if:{{#arrayprint:new_key}}| {{#arrayprint:new_key}}, }}{{#vardefine:@limit|{{#expr:{{#explode:@@@|<PROP>|10}} {{#if:{{#arrayprint:new_key}}|- {{#arraysize:new_key}}| - 0 }}{{#if:{{#arraysize:@countjurors}}|- {{#arraysize:@countjurors}}|- 0}} }} }}{{#ifexpr:{{#var:@limit}} > 0|{{#ask:[[User group::icol-user]][[Class::Member]][[!{{FULLPAGENAME}}]][[!{{{Filed by|}}}]][[Role::Juror]][[!{{#explode:@@@|<PROP>|12}}]][[!{{#explode:@@@|<PROP>|13}}]]{{#arraymap:{{#explode:@@@|<PROP>|11}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}|Limit={{#var:@limit}}|searchlabel=-|format=array|order=random}} }}
+
  -->{{#arraydefine:@random juror|{{#explode:@@@|<PROP>|13}}|<MANY>}}{{#arraydefine:@user|{{FULLPAGENAME}} }}{{#arraydiff:new_key|@random juror|@user}}{{#tag:wsedit||target={{PAGEID:{{#explode:@@@|<PROP>|0}}}}|template=Workflow|formfield=Random juror|value={{#if:{{#arrayprint:new_key}}| {{#arrayprint:new_key}}, }}{{#vardefine:@limit|{{#expr:{{#explode:@@@|<PROP>|10}} {{#if:{{#arrayprint:new_key}}|- {{#arraysize:new_key}}| - 0 }}{{#if:{{#arraysize:@countjurors}}|- {{#arraysize:@countjurors}}|- 0}} }} }}{{#ifexpr:{{#var:@limit}} > 0|{{#ask:[[User group::icol-user]][[Class::Member]][[!{{FULLPAGENAME}}]][[!{{{Filed by|}}}]][[Role::Juror]][[!{{#explode:@@@|<PROP>|12}}]][[!{{#explode:@@@|<PROP>|13}}]]{{#arraymap:{{#explode:@@@|<PROP>|11}}|<MANY>|@@@|[[!@@@]]|}}{{#arraymap:{{#explode:@@@|<PROP>|1}}|<MANY>|@@@|[[!@@@]]|}}|Limit={{#var:@limit}}|searchlabel=|format=array|order=random}} }}
 
}} }}
 
}} }}
 
{{#ifexpr:{{#arraysize:@jurrors}} < {{#explode:@@@|<PROP>|10}}|
 
{{#ifexpr:{{#arraysize:@jurrors}} < {{#explode:@@@|<PROP>|10}}|

Revision as of 15:06, 5 July 2021


This is the User template. It should be called in the following format:

{{User
|User=
|Roles=
|Name=
|Filed by=
|be candidate=
}}