Difference between revisions of "Template:Chembox parametercheck/test"

From blackwiki
Jump to navigation Jump to search
imported>DePiep
imported>DePiep
Line 4: Line 4:
 
| framestyle = background:#baeefa; font-weight:normal; text-align:left; border:none; font-size:90%;<!--
 
| framestyle = background:#baeefa; font-weight:normal; text-align:left; border:none; font-size:90%;<!--
  
  Supercountings (over 7 countings)
+
  Supercountings (over 7 ID countings)
 
  -->|2={{#switch:{{#invoke:math|max|-1 |{{{_countCASNo|0}}} |{{{_countPubChemCID|0}}} |{{{_countChemSpiderID|0}}} |{{{_countChEBI|0}}} |{{{_countInChI|0}}} |{{{_countInChIKey|0}}} |{{{_countSMILES|0}}} }}
 
  -->|2={{#switch:{{#invoke:math|max|-1 |{{{_countCASNo|0}}} |{{{_countPubChemCID|0}}} |{{{_countChemSpiderID|0}}} |{{{_countChEBI|0}}} |{{{_countInChI|0}}} |{{{_countInChIKey|0}}} |{{{_countSMILES|0}}} }}
 
|0=<!-- ~no identifiers... -->
 
|0=<!-- ~no identifiers... -->
Line 18: Line 18:
 
  INDEX_LABEL needed?
 
  INDEX_LABEL needed?
 
-->{{#ifexpr:({{#invoke:math|max|-1 |{{{_countCASNo|0}}} |{{{_countPubChemCID|0}}} |{{{_countChemSpiderID|0}}} |{{{_countChEBI|0}}} |{{{_countInChI|0}}} |{{{_countInChIKey|0}}} |{{{_countSMILES|0}}} }}>1)
 
-->{{#ifexpr:({{#invoke:math|max|-1 |{{{_countCASNo|0}}} |{{{_countPubChemCID|0}}} |{{{_countChemSpiderID|0}}} |{{{_countChEBI|0}}} |{{{_countInChI|0}}} |{{{_countInChIKey|0}}} |{{{_countSMILES|0}}} }}>1)
|<!-- multiple IDs. Has indexes? -->{{#ifexpr:{{{_countIndex_label|-1}}}<=0
+
|<!-- multiple IDs. Check: has indexes? (index_comments are ignored): -->{{#ifexpr:{{{_countIndex_label|-1}}}<=0
 
|[[:Category:Multiple chemicals in an infobox that need indexing|needs label_indexes]]
 
|[[:Category:Multiple chemicals in an infobox that need indexing|needs label_indexes]]
|<!-- no need to cat [[:Category:Chemicals using indexlabels]] ? -->}}}}<!--
+
|[[:Category:Chemicals using indexlabels]]<!-- need to cat? -->}}}}<!--
  
 
  NONE: Options 'none'
 
  NONE: Options 'none'
Line 111: Line 111:
  
 
  check if any data to be shown (else: idle Identifiers header)
 
  check if any data to be shown (else: idle Identifiers header)
-->|28={{#if:{{{_hasOtherInput|unk}}} |<!--ok1 -->|{{#ifexpr:{{{_countCAS|0}}}+{{{_countPubChem|0}}}+{{{_countChEBI|0}}}>0|<!--ok2 -->|{{#if:{{{_hasChEBIChEMBL|}}}{{{_hasChemSpiderID|}}}{{{_hasKEGG|}}}{{{_hasInChI|}}}{{{_hasUNII|}}}{{{_hasInChIorKey|}}} |<!--ok3 -->|[[:Category:Chemical infoboxes with tracked parameters|I]]}}}}}}<!--
+
-->|28={{#if:{{{_hasOtherInput|unk}}} |<!--ok1 -->|{{#ifexpr:{{{_countCAS|0}}}+{{{_countPubChem|0}}}+{{{_countChEBI|0}}}>0|<!--ok2 -->|{{#if:{{{_hasChEBIChEMBL|}}}{{{_hasChemSpiderID|}}}{{{_hasKEGG|}}}{{{_hasInChI|}}}{{{_hasUNII|}}}{{{_hasInChIorKey|}}} |<!--ok3 -->|<!-- idle header, to track -->[[:Category:Chemical infoboxes with tracked parameters|I]]}}}}}}<!--
  
 
  QIDs:
 
  QIDs:

Revision as of 10:34, 18 March 2017

Template documentation[view] [edit] [history] [purge]

Use /test for development. To make sure all testsettings show in /testcases, and won't show in mainspace. When going live, copy to regular /sandbox, change settings fit for Mainspace, then copy /sandbox into live.

Difference with live, when developing:

  • In {{Chembox Identifers/sandbox}}, set
|addTESTdata=Chembox parametercheck/test
|addMAINdata=<blank>
This sets {{main other|1=|2=(all categories to test)}} for all returned input ({{Chembox headerbar}})
  • In /test:
Set [[COLON:Category:Category name]] (do show not categorise; required to not pollute the categories with testpages)
Format /test visuals, eg by making it a collapsible list.
Optionally, set [[COLON:Category:Category name|Label To Show]] (shows wl label).

Diff

See also