<includeonly><!--
Hidden Part
-->{{#ifexpr:{{{1}}}>0|<!--
=====================================================
= year specified as number > 0, with or without "BC"
=====================================================
--><span {{#ifeq:{{{debug|}}}|yes|style="border:1px solid"|style="display:none; speak:none;" class="noprint"}}><!-- ▼
-->{{#ifeq:{{lc:{{{4|}}}}}|bc|<!--
==========================================
= year specified as number > 0, with "BC"
==========================================
-->-{{#ifexpr: {{{1}}} > 9000|0}}<!-- ▼
-->{{#ifexpr: {{{1}}} > 9900|0}}<!-- ▼
-->{{#ifexpr: {{{1}}} > 9990|0}}<!--
-->{{#expr:10000-{{{1}}}}}|<!-- ▼
==========
= year AD
==========
-->0{{#ifexpr: {{{1}}} < 1000|0}}<!--
-->{{#ifexpr: {{{1}}}< 100|0}}<!--
-->{{#ifexpr: {{{1}}} < 10|0}}<!--
-->{{#expr:1*{{{1}}}}} }}<!-- ▼
=============================================================================
= rest of hidden part for the case that the year is specified as number > 0,
= with or without "BC"
=============================================================================
-->{{#if:{{{2|}}}|-{{0expr|{{MONTHNUMBER|{{{2}}}}}}}<!--
-->{{#if:{{{3|}}}|-{{0expr|{{{3}}}}} }} }}</span><!-- ▼
=============================================================================
= visible part for the case that the year is specified as number > 0,
= with or without "BC"
=============================================================================
-->{{#if:{{{2|}}}|{{#ifeq:{{{link|off}}}|off|{{#ifeq:{{#if:{{{format|}}}|{{{format|}}}|dmy}}|dmy|{{#if:{{{3|}}}|{{{3|}}} {{MONTHNAMEGEN|{{{2}}}}}|{{MONTHNAME|{{{2}}}}}}}|{{MONTHNAME|{{{2}}}}} {{#if:{{{3|}}}|{{{3|}}}{{#ifeq:{{{year|}}}|hide||,}}}}}}|[[{{MONTHNAME|{{{2}}}}} {{{3|}}}]]}}}} {{#ifeq:{{{year|}}}|hide||{{#ifeq:{{{link|off}}}|off|{{#ifeq:{{lc:{{{4|}}}}}|bc|{{#expr:1*{{{1}}}}} BC|{{#expr:1*{{{1}}}}}}}|[[{{#ifeq:{{lc:{{{4|}}}}}|bc|{{#expr:1*{{{1}}}}} BC|{{#expr:1*{{{1}}}}}}}]]}}}}}}<!--
================================
= year specified as number <= 0
================================
-->{{#ifexpr:{{{1}}}<=0|<!--
--><span {{#ifeq:{{{debug|}}}|yes|style="border:1px solid"|style="display:none; speak:none;" class="noprint"}}><!--
-->-{{#ifexpr: {{{1}}} < -8999|0}}<!--
-->{{#ifexpr: {{{1}}} < -9899|0}}<!--
-->{{#ifexpr: {{{1}}} < -9989|0}}<!--
-->{{#expr:9999+{{{1}}}}}<!-- ▼
=============================================================================
// rest of hidden part for the case that the year is specified as number <= 0
=============================================================================
-->{{#if:{{{2|}}}|-{{0expr|{{MONTHNUMBER|{{{2}}}}}}}{{#if:{{{3|}}}|-{{0expr|{{{3}}}}}}}}}</span><!--
======================================================================
// visible part for the case that the year is specified as number <= 0
======================================================================
-->{{#if:{{{2|}}}|{{#ifeq:{{{link|off}}}|off|{{#ifeq:{{#if:{{{format|}}}|{{{format|}}}|dmy}}|dmy|{{#if:{{{3|}}}|{{{3|}}} {{MONTHNAMEGEN|{{{2}}}}}|{{MONTHNAME|{{{2}}}}} }}|{{MONTHNAME|{{{2}}} }} {{#if:{{{3|}}}|{{{3|}}}{{#ifeq:{{{year|}}}|hide||,}}}}}}|[[{{MONTHNAME|{{{2}}}}} {{{3|}}}]]}}}} {{#ifeq:{{{year|}}}|hide||{{#ifeq:{{{link|off}}}|off|{{#expr:0-{{{1}}}}} BC|[[{{#expr:0-{{{1}}}}} BC]]}}}}}}<!--
▲ --><span {{#ifeq:{{{debug |}}}|yes|style="border:1px solid"|style="display:none; speak:none ;" class=" noprintsortkey"}}> <!--{{#if:{{{1|}}}
--></includeonly><noinclude>{{doc|Майык:dts/doc}} ▼
|{{#ifeq:{{#switch:{{uc:{{{4}}}}}|BC|BCE=1}}{{#expr:{{{1}}}<0}}|0
[[Аңгылал:Википедия:Майыктарның адакы арыннары]]
▲ -->- |{{ #ifexprpadleft: {{{1}}} > 9000| 05}} <!--
▲ --> |-{{padleft:{{#expr: 1*1E4-abs{{{1}}}}} |4}} <!--
}}
|0{{#time:Y}}
}}-{{#time:m|{{{2}}}}}-{{#if:{{{3|}}}
|{{padleft:{{{3}}}|2}}
|01
}}-{{{addkey|}}}</span><!--
Visible Part
--><span style="{{#ifeq:{{{nowrap}}}|off||white-space:nowrap;}}">{{#ifeq:{{{M}}}|M
▲--> |{{# exprtime: 9999+M|{{{ 12}}}}} <!--
|{{ucfirst:{{{2}}}}}
}} {{#expr:{{{3|}}}}}{{#if:{{{1|}}}
▲ -->|{{#if:{{{3|}}}| -,}} {{ 0expr|#ifexpr:{{{ 31}}} }} }} }}</span>< !--0
▲ --> |{{#expr: 10000-{{{1}}}}} |<!-- BC
▲ --> |{{# ifexprexpr: {{{1}}} > 9900|0}} <!--
}}{{#if:{{{4|}}}
| {{uc:{{{4}}}}}
}}
▲--}}</span></includeonly><noinclude> {{doc|Майык:dts/doc}}
{{doc|content=
This is a subtemplate of {{tl|dts}}.
}}
</noinclude>
|