Difference between revisions of "Template:Cleanup"

m (updating)
m (updating)
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{ {{{|safesubst:}}}#invoke:Unsubst| |$B=
+
{{ {{{|safesubst:}}}#invoke:Unsubst||date=__DATE__ |$B=
{{#ifexpr:{{#expr:{{#iferror:{{#time:U|{{{date}}}}}|2000000000}}>=1341100800}}*{{#if:{{{reason|<noinclude>x</noinclude>}}}|0|1}}
+
{{#ifexpr:{{#expr:{{#iferror:{{#time:U|{{{date}}}}}|2000000000}}>=1341100800}}*{{#if:{{{reason|<noinclude>x</noinclude>}}}|0|1}}*{{#ifeq:{{{nocat}}}|true|0|1}}
 
  |{{error|1=You must add a {{para|reason}} parameter to this Cleanup template – replace it with <code><nowiki>{{Cleanup|</nowiki>{{#if:{{{1|}}}|{{{1|}}}{{!}}|}}{{#if:{{{date|}}}|<nowiki>date=</nowiki>{{{date|}}}{{!}}}}<nowiki>reason=<Fill reason here>}}</nowiki></code>, or remove the Cleanup template.<br style="clear:both;">
 
  |{{error|1=You must add a {{para|reason}} parameter to this Cleanup template – replace it with <code><nowiki>{{Cleanup|</nowiki>{{#if:{{{1|}}}|{{{1|}}}{{!}}|}}{{#if:{{{date|}}}|<nowiki>date=</nowiki>{{{date|}}}{{!}}}}<nowiki>reason=<Fill reason here>}}</nowiki></code>, or remove the Cleanup template.<br style="clear:both;">
}}
+
}}{{Category handler
 +
  |nocat    = {{{nocat|}}}
 +
  |main    = Cleanup tagged articles without a reason field
 +
}}
 
  |{{main other
 
  |{{main other
 
   |{{ambox
 
   |{{ambox
Line 20: Line 23:
 
   | removalnotice = yes
 
   | removalnotice = yes
 
   | date  = {{{date|}}}
 
   | date  = {{{date|}}}
   | cat   = [[Category:Articles needing cleanup]]
+
   | all   = Articles needing cleanup
 
   }}
 
   }}
 
   |{{mbox
 
   |{{mbox
 
   | demospace = {{{demospace|}}}
 
   | demospace = {{{demospace|}}}
 
   | type      = style
 
   | type      = style
   | text      = This {{{1|{{SUBJECTSPACE formatted}}}}} '''may require [[BattleTechWiki:cleanup|cleanup]] to meet BattleTechWiki's [[BattleTechWiki:Manual of Style|quality standards]]'''.  {{#if:{{{reason|}}}
+
   | text      = This {{{1|{{SUBJECTSPACE formatted}}}}} '''may require [[BattleTechWiki:Cleanup|cleanup]] to meet BattleTechWiki's [[BattleTechWiki:Manual of Style|quality standards]]'''.  {{#if:{{{reason|}}}
 
     |The specific problem is: '''{{Terminate sentence|{{{reason}}}}}'''
 
     |The specific problem is: '''{{Terminate sentence|{{{reason}}}}}'''
 
     |No [[Template:Cleanup/doc|cleanup reason]] has been specified.
 
     |No [[Template:Cleanup/doc|cleanup reason]] has been specified.
Line 34: Line 37:
 
   }}
 
   }}
 
  | demospace = {{{demospace|<noinclude>main</noinclude>}}}
 
  | demospace = {{{demospace|<noinclude>main</noinclude>}}}
 +
}}{{Category handler
 +
  |page    = {{SUBJECTPAGENAME}}
 +
  |nocat    = {{{nocat|}}}
 +
  |category = [[Category:Categories needing cleanup]]
 +
  |template = {{#ifeq:{{#titleparts:{{FULLPAGENAME}}|1}}|Template:Cleanup||Templates needing cleanup}}
 +
  |other    = [[Category:Articles needing cleanup]]
 
  }}
 
  }}
 
}}
 
}}

Revision as of 19:06, 7 February 2024