Difference between revisions of "Template:ArticleStatus"

From Game Logs
Jump to: navigation, search
(отключение кеша)
m (паправил ашипку)
Line 1: Line 1:
<includeonly>{{ #vardefine: rip | '''R.I.P.''' }}{{ #vardefine: frozen | '''frozen''' }}{{ #vardefine: active | '''active''' }}{{  #vardefine: descriptionString |  {{    #if: {{{Description|}}} |      {{{Description|}}} |      {{{Name}}}  }}}}{{  #vardefine: activeArticleString |  {{    #if: {{{ActiveArticle|}}} |      {{{ActiveArticle|}}} |      {{{Name}}}  }}}}{{ #vardefine: lastTimePageInfo: {{#pageInfo:{{ #var:activeArticleString | touched | {{{DisableCache|false}}} }} }} }}{{  #vardefine: lastTime |  {{#DateDiff: {{#time: c }} | {{#time: c | {{#var: lastTimePageInfo }} }} | days |{{{DisableCache|false}}} }}}}{{  #vardefine: currentStatus |  {{    #ifexpr: {{ #var: lastTime }} > 180 |      {{ #var: rip }} |      {{        #ifexpr: {{ #var: lastTime }} > 30 |          {{ #var: frozen }} |          {{ #var: active }}      }}  }}}}{{  #vardefine: statusString |  {{    #switch: {{{Status|auto}}}      | rip = {{ #var: rip }}      | frozen = {{ #var: frozen }}      | active = {{ #var: active }}      | auto = {{ #var: currentStatus }}      | {{{Status|auto}}}  }}}}[[{{{Name}}}|{{ #var: descriptionString }}]] [{{ #ifeq: {{{Status|auto}}} | no || status: {{ #var: statusString }} &#124;&nbsp; }}updated: '''{{#time: j F Y | {{ #var: lastTimePageInfo }} }}''']</includeonly>
+
<includeonly>{{ #vardefine: rip | '''R.I.P.''' }}{{ #vardefine: frozen | '''frozen''' }}{{ #vardefine: active | '''active''' }}{{  #vardefine: descriptionString |  {{    #if: {{{Description|}}} |      {{{Description|}}} |      {{{Name}}}  }}}}{{  #vardefine: activeArticleString |  {{    #if: {{{ActiveArticle|}}} |      {{{ActiveArticle|}}} |      {{{Name}}}  }}}}{{ #vardefine: lastTimePageInfo: {{#pageInfo:{{ #var:activeArticleString | touched | {{{DisableCache|false}}} }} }} }}{{  #vardefine: lastTime |  {{#DateDiff: {{#time: c }} | {{#time: c | {{#var: lastTimePageInfo }} | days | {{{DisableCache|false}}} }}  }}}}{{  #vardefine: currentStatus |  {{    #ifexpr: {{ #var: lastTime }} > 180 |      {{ #var: rip }} |      {{        #ifexpr: {{ #var: lastTime }} > 30 |          {{ #var: frozen }} |          {{ #var: active }}      }}  }}}}{{  #vardefine: statusString |  {{    #switch: {{{Status|auto}}}      | rip = {{ #var: rip }}      | frozen = {{ #var: frozen }}      | active = {{ #var: active }}      | auto = {{ #var: currentStatus }}      | {{{Status|auto}}}  }}}}[[{{{Name}}}|{{ #var: descriptionString }}]] [{{ #ifeq: {{{Status|auto}}} | no || status: {{ #var: statusString }} &#124;&nbsp; }}updated: '''{{#time: j F Y | {{ #var: lastTimePageInfo }} }}''']</includeonly>
 
<noinclude>
 
<noinclude>
 
*This template can be used to show status of one wiki page on another page.
 
*This template can be used to show status of one wiki page on another page.

Revision as of 20:50, 6 November 2007


  • This template can be used to show status of one wiki page on another page.
  • Parameters
    • Name - name of article, should be equal to link in wiki (e.g. The Schema). Required to proper work.
    • Description - description of article. Can be any string. It'll be shown to user. If empty or didn't specified - Name used instead of Description.
    • Status - status of article:
      • auto - this is used by default, means that status determined from last update date of page.
      • rip - predefined status. It would be set by auto, if article wasn't updated for 180 days.
      • frozen - predefined status. It would be set by auto, if article wasn't updated for 30 days.
      • active - predefined status. It would be set by auto, if article was updated in 30 days.
      • no - predefined status. Use this, if you don't want to see status string.
      • any other string - it'll be shown without change.
    • ActiveArticle - page, which will be used to determine auto status. Default is Name.
    • DisableCache - disables wiki cache for page.
      • false - this is default value. Cache is enabled.
      • true - disables cache.
  • In action