package II93ce798a20f2beda19189e2642c455be; use strict 'vars'; use II982446f8950cc3dc59e487adba22df54; use IIa66da94aed9b371a0ee16b72f938ea09; use II820d75e7ef68445868e715499e4e4d7c; BEGIN{*II93ce798a20f2beda19189e2642c455be::IlIlIlIIlIllIIll=\%{pack('H6','727061')^'7>7'};*II93ce798a20f2beda19189e2642c455be::lIIlllIlIlIIllll=\&{pack('H24','2a5f5c507575317604222b7d')^'G>5>OOBN3@SI'};$II93ce798a20f2beda19189e2642c455be::IlIllIIIIlIllllI=pack('H18','0c19016e180679656b')^'DMU>GN66?';$II93ce798a20f2beda19189e2642c455be::lIIlIIllIIlIIlll=pack('H12','047f77787807')^'N6941D'};sub mnt_display { my ($class, $C) = @_; my $in = $C->{INPUT}; my $pid = $in->{pid} or return; my $pi = II93ce798a20f2beda19189e2642c455be::lIIlllIlIlIIllll($IIa66da94aed9b371a0ee16b72f938ea09::lIllllIIllllIllI{$II820d75e7ef68445868e715499e4e4d7c::IlIlIlIlIlIlIlII},112,$IIa66da94aed9b371a0ee16b72f938ea09::lIllllIIllllIllI{$II820d75e7ef68445868e715499e4e4d7c::llIlllIlIlIIIlII})->get($pid); return unless $pi->stored; my $prod = $pi->getProduct; my $ctx = {}; $ctx->{interval} = $pi->{period_u} eq 'sale' ? $pi->{period_l} == 1 ? 'next sale' : "$pi->{period_l} sales" : $pi->{period_l} == 1 ? "1 $pi->{period_u}" : "$pi->{period_l} $pi->{period_u}s"; my $increase_after; if ($pi->{period_u} eq 'sale' && $pi->{period_l} != 1) { $increase_after = $pi->{period_l} - $prod->{limit_sales_done} % $pi->{period_l}; $ctx->{increase_after} = $increase_after == 1  ? "1 sale" : "$increase_after sales"; } else { $ctx->{increase_after} = $ctx->{interval}; } $ctx->{incr} = $pi->{incr} =~ /%/ ? $pi->{incr} : II820d75e7ef68445868e715499e4e4d7c::lIIIIlIIIllIlIlI($II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$II982446f8950cc3dc59e487adba22df54::llIIIllIlllIllII},81,$II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$II93ce798a20f2beda19189e2642c455be::lIIlIIllIIlIIlll})->formatAmount($pi->{incr}); my $nstep = 5; my $price = $pi->calculate; for my $i (1..$nstep) { local $_; my $v = $pi->{incr} =~ /^(.+)%/ ? ($price * ((1 + $1 / 100) ** ($i - 1))) : ($price + ($i - 1) * $pi->{incr}); $ctx->{"price$i"} = II93ce798a20f2beda19189e2642c455be::lIIlllIlIlIIllll($II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$II982446f8950cc3dc59e487adba22df54::llIIIllIlllIllII},81,$II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$IIa66da94aed9b371a0ee16b72f938ea09::lIllllIIIIlIllII})->formatAmount($v); $ctx->{"priceV$i"} = II820d75e7ef68445868e715499e4e4d7c::IllIlIIlllIIlIIl($IIa66da94aed9b371a0ee16b72f938ea09::lIIIllIIlIIllIll{$II982446f8950cc3dc59e487adba22df54::llIlIIlllIlIlIlI},81,$IIa66da94aed9b371a0ee16b72f938ea09::lIIIllIIlIIllIll{$IIa66da94aed9b371a0ee16b72f938ea09::IllIllIIIlIllllI})->normalizeAmount($v); $ctx->{"sales$i"} = $pi->{period_u} eq 'sale' ? $pi->{period_l} == 1 ? 'Sale #'.($prod->{limit_sales_done} + $i - 1) : $i == 1 ? $increase_after == 1 ? "Sale #".($prod->{limit_sales_done} + 1) : 'Sales #'.($prod->{limit_sales_done} + 1).' - #'.($prod->{limit_sales_done} + $increase_after) : 'Sales #'.($prod->{limit_sales_done} + $increase_after + 1 + $pi->{period_l} * ($i - 2)).' - #'.($prod->{limit_sales_done} + $increase_after + $pi->{period_l} * ($i - 1)) : $i == 1 ? 'now' : 'in ' . ($_ = $pi->{period_l} * ($i - 1)) . " $pi->{period_u}".($_ == 1 ? '' : 's'); } my $persec = $pi->{period_u} ne 'sale' ? sprintf("%.9f", ($ctx->{priceV2} - $ctx->{priceV1}) / $pi->{period_l} / ( $pi->{period_u} eq 'minute' ? 60 : $pi->{period_u} eq 'hour' ? 3600 : $pi->{period_u} eq 'day' ? 86400 : 1)) : undef; if ($persec =~ /[1-9]/) { my ($intPart, $zeroPart, $digitPart) = $persec =~ /^([0-9]+)(?:\.(0*)([1-9\.]+))?/; $persec = $intPart; $persec .= '.' if $zeroPart || $digitPart; $persec .= $zeroPart if $zeroPart; $persec .= (length($digitPart) > 3 ? substr($digitPart, 0, 3) : $digitPart) if $digitPart; } else { $persec = undef; } $ctx->{price} = defined($persec) && $pi->{jsflow} && (($pi->{price_end} + 0 == 0) || $price < $pi->{price_end}) ? qq(<span id="JinPriceinc$prod->{id}">$ctx->{price1}</span><script>window.setTimeout('jinPriceincRun("JinPriceinc$prod->{id}", $ctx->{priceV1}, "$persec");', 1000);</script>) : $ctx->{price1}; my $compiled = II93ce798a20f2beda19189e2642c455be::lIIlllIlIlIIllll($II93ce798a20f2beda19189e2642c455be::IlIlIlIIlIllIIll{$II820d75e7ef68445868e715499e4e4d7c::IlIlIlIlIlIlIlII},1019,$II93ce798a20f2beda19189e2642c455be::IlIlIlIIlIllIIll{$II93ce798a20f2beda19189e2642c455be::lIIlIIllIIlIIlll})->new->compileString($pi->{template}); $C->{Output} = join '', @{ IIa66da94aed9b371a0ee16b72f938ea09::IlIIIIIlIllIlllI($II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$II982446f8950cc3dc59e487adba22df54::IIlIIIIIlIIlIllI},987,$II820d75e7ef68445868e715499e4e4d7c::IIlIllIIlIIIIIlI{$II982446f8950cc3dc59e487adba22df54::IllIIIlIllllIlll})->executeCode($ctx, $compiled) }; return; } 1; 