1<?
if (!defined(
"B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED !==
true)
die();?><?
3if (!is_array($arOrder))
6<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.0 Transitional//EN">
10<meta
http-equiv=
"Content-Type" content=
"text/html; charset=<?=LANG_CHARSET?>">
13 table.it td { border: 1pt solid #000000; padding: 0pt 3pt; }
14 table.inv td, table.sign td { padding: 0pt; }
15 table.sign td { vertical-
align:
top; }
16 table.header td { padding: 0pt; vertical-
align:
top; }
32 if (intval(
$path) > 0)
34 if ($arFile = CFile::GetFileArray(
$path))
35 $path = $arFile[
'SRC'];
39 if (!in_array($backgroundStyle,
array(
'none',
'tile',
'stretch')))
40 $backgroundStyle =
'none';
44 switch ($backgroundStyle)
54 "url('%s') 0 0 repeat-y; background-size: %.02fpt %.02fpt",
73<body
style=
"margin: 0pt; padding: 0pt;"<?
if (
$_REQUEST[
'PRINT'] ==
'Y') { ?> onload=
"setTimeout(window.print, 0);"<? } ?>>
75<div
style=
"margin: 0pt; padding: <?=join('pt ', $margin); ?>pt; width: <?=$width; ?>pt; background: <?=$background; ?>">
80 <td
style=
"padding-right: 5pt; ">
83 <img src=
"<?=$imgParams['SRC']; ?>" width=
"<?=$imgWidth; ?>" />
99<div
style=
"text-align: center; font-size: 2em"><b>Factura</b></div>
118 <td><b>Factura #&
nbsp;</b></td>
122 <td><b>Girada el:&
nbsp;</b></td>
127 <td><b>Para pagarse el:&
nbsp;</b></td>
146 array(
"DATE_INSERT" =>
"ASC",
"NAME" =>
"ASC"),
149 array(
"ID",
"PRICE",
"CURRENCY",
"QUANTITY",
"NAME",
"VAT_RATE",
"MEASURE_NAME")
163 $arProdProps =
array();
165 array(
"SORT" =>
"ASC",
"ID" =>
"DESC"),
167 "BASKET_ID" => $arBasket[
"ID"],
168 "!CODE" =>
array(
"CATALOG.XML_ID",
"PRODUCT.XML_ID")
172 array(
"ID",
"BASKET_ID",
"NAME",
"VALUE",
"CODE",
"SORT")
174 while ($arBasketProps = $dbBasketProps->GetNext())
176 if (!empty($arBasketProps) && $arBasketProps[
"VALUE"] !=
"")
177 $arProdProps[] = $arBasketProps;
179 $arBasket[
"PROPS"] = $arProdProps;
182 if (isset($arBasket[
'VAT_INCLUDED']) && $arBasket[
'VAT_INCLUDED'] ===
'Y')
185 $arBasket[
"VATLESS_PRICE"] = $arBasket[
"PRICE"];
187 $productName = $arBasket[
"NAME"];
188 if ($productName ==
"OrderDelivery")
189 $productName =
"Envo";
190 else if ($productName ==
"OrderDiscount")
191 $productName =
"Descuento";
201 $arBasket[
"VATLESS_PRICE"] * $arBasket[
"QUANTITY"],
202 $arBasket[
"CURRENCY"],
208 foreach ($arBasket[
"PROPS"] as $vv)
211 $sum += doubleval($arBasket[
"VATLESS_PRICE"] * $arBasket[
"QUANTITY"]);
212 $vat = max(
$vat, $arBasket[
"VAT_RATE"]);
213 if ($arBasket[
"VAT_RATE"] > 0)
215 if (!isset($vats[$arBasket[
"VAT_RATE"]]))
216 $vats[$arBasket[
"VAT_RATE"]] = 0;
217 $vats[$arBasket[
"VAT_RATE"]] += ($arBasket[
"PRICE"] - $arBasket[
"VATLESS_PRICE"]) * $arBasket[
"QUANTITY"];
222 if (DoubleVal(
$GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE_DELIVERY"]) > 0)
226 $sDeliveryItem =
"Envo";
227 if ($arDelivery_tmp[
"NAME"] <>
'')
228 $sDeliveryItem .= sprintf(
" (%s)", $arDelivery_tmp[
"NAME"]);
235 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE_DELIVERY"] / (1 +
$vat),
236 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
241 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE_DELIVERY"] / (1 +
$vat),
242 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
248 doubleval(
$GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE_DELIVERY"] / (1 +
$vat)),
254 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE_DELIVERY"] *
$vat / (1 +
$vat),
261 if (
$sum <
$GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE"])
278 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"PRICE"] -
$sum - array_sum($vats),
299 foreach ($vats as $vatRate => $vatSum)
313 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
322 array(
"APPLY_ORDER" =>
"ASC"),
336 (
$arTaxList[
"IS_IN_PRICE"] ==
"Y") ?
"Incluido " :
"",
342 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
349 if (DoubleVal(
$GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"SUM_PAID"]) > 0)
359 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"SUM_PAID"],
360 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
366 if (DoubleVal(
$GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"DISCOUNT_VALUE"]) > 0)
376 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"DISCOUNT_VALUE"],
377 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
391 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"SHOULD_PAY"],
392 $GLOBALS[
"SALE_INPUT_PARAMS"][
"ORDER"][
"CURRENCY"],
399<table
class=
"it" width=
"100%">
401 <td><nobr>#</nobr></td>
402 <td><nobr>Artculo / Descripcin</nobr></td>
403 <td><nobr>Cant</nobr></td>
404 <td><nobr>Unidades</nobr></td>
405 <td><nobr>Precio unitario</nobr></td>
406 <?
if (
$vat > 0) { ?>
407 <td><nobr>Tasa impositiva</nobr></td>
409 <td><nobr>Total</nobr></td>
427 style=
"word-break: break-word; word-wrap: break-word; <? if ($accumulated) {?>border-width: 0pt 1pt 0pt 0pt; <? } ?>"
428 <?
if ($accumulated) { ?>colspan=
"<?=($accumulated+1); ?>"<? $accumulated = 0; } ?>>
430 <?
if (isset($arProps[
$n]) && is_array($arProps[
$n])) { ?>
431 <?
foreach ($arProps[
$n] as $property) { ?>
433 <small><?=$property; ?></small>
440 <?
for (
$i = 3;
$i <= 7;
$i++) { ?>
444 <?
if ($accumulated) { ?>
445 style=
"border-width: 0pt 1pt 0pt 0pt"
446 colspan=
"<?=(($i == 6 && $vat <= 0) ? $accumulated : $accumulated+1); ?>"
447 <? $accumulated = 0; } ?>>
468<b>Trminos y Condiciones</b>
472 array(
'#</div>\s*<div[^>]*>#i',
'#</?div>#i'),
array(
'<br>',
'<br>'),
474 ),
'',
array(), 0)); ?>
480 array(
'#</div>\s*<div[^>]*>#i',
'#</?div>#i'),
array(
'<br>',
'<br>'),
482 ),
'',
array(), 0)); ?>
496<table
class=
"sign" style=
"width: 100%; ">
498 <td
style=
"width: 50%; ">
502 <b>Detalles bancarios</b>
510 # de la Cuenta: <?=$bankAccNo; ?>
517 <?
if (
$bank || $bankAddr || $bankPhone) { ?>
518 Nombre y direccin del banco: <?
if (
$bank) { ?><?=
$bank; ?><? } ?>
521 <?
if ($bankAddr) { ?>
526 <?
if ($bankPhone) { ?>
540 <td
style=
"width: 50%; ">
546 'style="position: absolute; left: 30pt; "'
550 <table
style=
"width: 100%; position: relative; ">
558 <tr><td>&
nbsp;</td></tr>
563 <tr><td>&
nbsp;</td></tr>
566 <td
style=
"border-bottom: 1pt solid #000000; text-align: center; ">
571 'style="position: absolute; margin-left: -75pt; bottom: 0pt; "'
581 <tr><td>&
nbsp;</td></tr>
586 <tr><td>&
nbsp;</td></tr>
589 <td
style=
"border-bottom: 1pt solid #000000; text-align: center; ">
594 'style="position: absolute; margin-left: -75pt; bottom: 0pt; "'
static GetParamValue($key, $defaultValue=null)
static ShowImage($strImage, $iMaxW=0, $iMaxH=0, $sParams=null, $strImageUrl="", $bPopup=false, $sPopupTitle=false, $iSizeWHTTP=0, $iSizeHHTTP=0, $strImageUrlTemplate="")
static _GetImgParams($strImage, $iSizeWHTTP=0, $iSizeHHTTP=0)
static GetList($arOrder=array(), $arFilter=array(), $arGroupBy=false, $arNavStartParams=false, $arSelectFields=array())
static GetPropsList($arOrder=array(), $arFilter=array(), $arGroupBy=false, $arNavStartParams=false, $arSelectFields=array())
static GetList($arOrder=array("TAX_NAME"=> "ASC"), $arFilter=array(), $arGroupBy=false, $arNavStartParams=false, $arSelectFields=array())
bx popup label bx width30 PAGE_NEW_MENU_NAME text width
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
bx_acc_lim_group_list limitGroupList[] multiple<?=$group[ 'ID']?> ID selected margin top
<? if( $useEditor3):?>< tr class="heading">< td colspan="2"><? echo GetMessage("FILEMAN_OPTION_SPELL_SET");?></td ></tr ><? if(function_exists( 'pspell_config_create')):$use_pspell_checked=(COption::GetOptionString( $module_id, "use_pspell", "Y")=="Y") ? "checked" :"";?>< tr >< td valign="top">< label for="use_pspell"><?echo GetMessage("FILEMAN_OPTION_USE_PSPELL");?></label >< br >< a title="<?echo GetMessage("FILEMAN_OPTION_ADDISH_DICS_TITLE");?> http
ConvertDateTime($datetime, $to_format=false, $from_site=false, $bSearchInSitesOnly=false)
htmlspecialcharsback($str)
HTMLToTxt($str, $strSiteUrl="", $aDelete=[], $maxlen=70)
htmlspecialcharsbx($string, $flags=ENT_COMPAT, $doubleEncode=true)
<? endif;?> window document title
for( $i=0, $max=count( $arBasketIDs);$i< $max;$i++) if($arOrder['DELIVERY_VAT_RATE'] > 0) if(is_array( $arBasketOrder) &&!empty( $arBasketOrder)) if(floatval($arOrder["DISCOUNT_VALUE"]) > 0) $arTaxList
</p ></td >< td valign=top style='border-top:none;border-left:none;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0cm 2.0pt 0cm 2.0pt;height:9.0pt'>< p class=Normal align=center style='margin:0cm;margin-bottom:.0001pt;text-align:center;line-height:normal'>< a name=ТекстовоеПоле54 ></a ><?=($taxRate > count( $arTaxList) > 0) ? $taxRate."%"
if( $arBasket=$dbBasket->Fetch()) if($vat > 0) $rowsCnt
if(CSalePaySystemAction::GetParamValue("DATE_PAY_BEFORE", false)) $dbBasket
if(!empty($sellerData)) $bankAccNo
if(CSalePaySystemAction::GetParamValue('BACKGROUND', false)) $margin
SaleFormatCurrency($fSum, $strCurrency, $OnlyValue=false, $withoutFormat=false)
const SALE_VALUE_PRECISION
$GLOBALS['_____370096793']