Difference between revisions of "Template:Theory"

From Encyclopedia of Scientonomy
Jump to navigation Jump to search
Line 27: Line 27:
 
</pre>
 
</pre>
 
Edit the page to see the template text.
 
Edit the page to see the template text.
</noinclude><includeonly>{{#set:Topic={{{Topic|}}}|Subject={{{Subject|}}}|Predicate={{{Predicate|}}}|Object={{{Object|}}}|Formulated Year={{{Formulated Year|}}}|Alternate Titles={{{Alternate Titles|}}}|Description={{{Description|}}}|Resource={{{Resource|}}}|Formulation File={{{Formulation File|}}}|Theory Type={{{Theory Type|}}}|Authors List={{{Authors List|}}}|Page Status={{{Page Status|Stub}}}|Editor Notes={{{Editor Notes|}}}|}}<!--
+
</noinclude><includeonly><!--
 +
--><!--
 +
--><!-- set the values
 +
-->{{#set:<!--
 +
-->Topic={{{Topic|}}}|<!--
 +
-->Object={{{Object|}}}|<!--
 +
-->Formulated Year={{{Formulated Year|}}}|<!--
 +
-->Alternate Titles={{{Alternate Titles|}}}|<!--
 +
-->Description={{{Description|}}}|<!--
 +
-->Resource={{{Resource|}}}|<!--
 +
-->Formulation File={{{Formulation File|}}}|<!--
 +
-->Theory Type={{{Theory Type|}}}|<!--
 +
-->Authors List={{{Authors List|}}}|<!--
 +
-->Page Status={{{Page Status|Stub}}}|<!--
 +
-->Editor Notes={{{Editor Notes|}}}|<!--
 +
-->}}<!-- set
 
--><!--
 
--><!--
 
--><!-- set the subfield
 
--><!-- set the subfield
Line 33: Line 48:
 
-->{{#set: Subfield={{#var: varSubfield}}|}}<!--
 
-->{{#set: Subfield={{#var: varSubfield}}|}}<!--
 
--><!--
 
--><!--
 +
--><!-- set the subject and predicate
 +
-->{{#vardefine: varSubject|{{#show: {{{Topic|}}}|?Subject|link=none}} }}<!--
 +
-->{{#vardefine: varPredicate|{{#show: {{{Topic|}}}|?Predicate|link=none}} }}<!--
 +
-->{{#set: Subject={{#var: varSubject}}|Predicate={{#var: varPredicate}}|}}<!--
 +
--><!--
 
--><!-- set the formulation text
 
--><!-- set the formulation text
 +
-->{{#if: {{{Text Formula|}}}<!--
 +
-->|{{#vardefine: varTextFormula|{{{Text Formula|}}} }}<!-- text formula is manually given
 +
-->|{{#vardefine: varTextFormula|{{#show: {{{Topic|}}}|?Single Answer Text Formula|link=none}} }}<!-- text formula is determined by the topic
 +
-->}}<!-- if
 +
--><!--
 
-->{{#if: {{{Formulation Text|}}}<!--
 
-->{{#if: {{{Formulation Text|}}}<!--
  -->|{{#set:Formulation Text={{{Formulation Text|}}}|}}<!--
+
  -->|{{#set:Formulation Text={{{Formulation Text|}}}|}}<!-- formulation text is manually given
  -->|{{#set:Formulation Text={{DecodeTextFormula|formula={{{Text Formula|}}}|subject={{{Subject|}}}|predicate={{{Predicate|}}}|object={{{Object|}}}|}}|}}<!--
+
  -->|{{#set:Formulation Text={{DecodeTextFormula|formula={{#var: varTextFormula}}|subject={{#var: varSubject}}|predicate={{#var: varPredicate}}|object={{{Object|}}}|}}|}}<!--
 
-->}}<!-- if
 
-->}}<!-- if
 +
--><!--
 
--><!--
 
--><!--
 
--><!-- set the first paragraph of the description so that it can be used on the topic page
 
--><!-- set the first paragraph of the description so that it can be used on the topic page

Revision as of 21:20, 19 January 2023

This is the "Theory" template. This template is to be used for all theories (descriptive, normative, and definitions). It is currently used by Form:Theory.

It should be called in the following format:

{{Theory
 |Topic= 
 |Theory Type= {Definition, Descriptive, Normative}
 |Subject= 
 |Predicate=
 |Title= //ignored for Definitions. Equals to Topic.
 |Alternative Titles=
 |Title Formula= //Taken from the Topic's Answer Title Formula. If need to be manually modified, it can be done here.
 |Text Formula= //Taken from the Topic's Single Answer Text Formula. If need to be manually modified, it can be done here.
 |Object= //Will be used to construct the formulate text.
 |Formulation Text= //This is left as a backdoor: use this if the formulation needs to be manually tweaked. 
 |Description=
 |Formulated Year=
 |Authors List=
 |Resource=
 |Formulation File=
 |Prehistory=
 |History=
 |Page Status=
 |Editor Notes=
}}

Edit the page to see the template text.