Difference between revisions of "Template:PrintTopicOpenQuestionsList"

From Encyclopedia of Scientonomy
Jump to navigation Jump to search
 
(3 intermediate revisions by the same user not shown)
Line 24: Line 24:
 
   -->}}<!-- print
 
   -->}}<!-- print
 
-->}}<!-- arraydefine
 
-->}}<!-- arraydefine
 +
--><!--
 +
--><!-- check if it's unique
 +
-->{{#arrayunique: varTopicsArray}}<!--
 +
--><!--
 
--><!--
 
--><!--
 
--><!-- only keep those that have their Has No Accepted Answer property set  
 
--><!-- only keep those that have their Has No Accepted Answer property set  
 
-->{{#arraydefine: varOpenQuestionsArray|<!--
 
-->{{#arraydefine: varOpenQuestionsArray|<!--
 
  -->{{#arrayprint: varTopicsArray<!--
 
  -->{{#arrayprint: varTopicsArray<!--
   -->|,&#32;<!--
+
   -->|,<!--
 
   -->|@@@@<!--
 
   -->|@@@@<!--
 
   -->|{{#if: {{#show: @@@@|?Has No Accepted Answer|headers=hide|format=list}}|@@@@|}}<!--
 
   -->|{{#if: {{#show: @@@@|?Has No Accepted Answer|headers=hide|format=list}}|@@@@|}}<!--
Line 43: Line 47:
 
   -->{{#arrayprint: varOpenQuestionsArray<!--
 
   -->{{#arrayprint: varOpenQuestionsArray<!--
 
   -->||@@@@<!--
 
   -->||@@@@<!--
   -->|{{#ifeq: {{{bullets|}}}|yes|<nowiki/>
+
   -->|{{#if: @@@@|<!--
* |}}{{#switch: {{{link|}}}|none=@@@@|[[@@@@]]}}<!-- add the value as a link if necessary
+
                --><nowiki/>
    -->{{#ifeq: {{{details|}}}|yes|<!-- add the details if necessary
+
{{#ifeq: {{{bullets|}}}|yes|* |}}{{#switch: {{{link|}}}|none=@@@@|[[@@@@]]}}<!-- add the value as a link if necessary        
    --><nowiki>: </nowiki>{{#show: @@@@|?Question|link={{{link|}}}}}<!-- add the question at issue
+
                -->{{#ifeq: {{{details|}}}|yes|<!-- add the details if necessary
    --><!-- TODO: add the list of authors of this question
+
                --><nowiki>: </nowiki>{{#show: @@@@|?Question|link={{{link|}}}}}<!-- add the question at issue
    -->{{GetPropertyValues|object=@@@@|property=Has No Accepted Answer|intro=&#32;The topic has no accepted answer in&#32;|outro=<nowiki>.</nowiki>|link={{{link|}}}|pretty=yes}}<!-- add the communities where the topic has no answer
+
                --><!-- TODO: add the list of authors of this question
     -->}}<!-- if details
+
                -->{{GetPropertyValues|object=@@@@|property=Has No Accepted Answer|intro=&#32;The topic has no accepted answer in&#32;|outro=<nowiki>.</nowiki>|link={{{link|}}}|pretty=yes}}<!-- add the communities where the topic has no answer
 +
                -->}}<!-- if details
 +
     -->}}<!-- if
 
   -->}}<!-- array print
 
   -->}}<!-- array print
 
   -->{{{outro|}}}<!--
 
   -->{{{outro|}}}<!--

Latest revision as of 23:50, 4 September 2016

Use this template to print a list of all the open questions related to the topic. At the moment, only the subquestions, and the questions direclty indicated on the topic's page as a Related Topic are included in the outcome.

NOTE: As any "printing" template, it doesn't store any values anywhere, but merely prints them on the page.

Parameters:

  • |topic= - the full page name of the topic.
  • |intro= - initial text that precedes the output, if at least some results exist.
  • |outro= - text that is appended to the output, if at least some results exist.
  • |default= - if, for any reason, the query returns no results, this will be printed instead.
  • |link= - determines whether the values are to be printed as links to the respective pages (where available); possible values are none, subject, all. If not given all is the default.
  • |bullets= - if yes, a bullet-list will be produced.
  • |details= - if yes, then details of the open question are added to each record. This includes the formulation of the question and the list of communities where the question has no currently accepted answer.