-
Notifications
You must be signed in to change notification settings - Fork 0
/
catalog.section.default.template.php
84 lines (73 loc) · 2.39 KB
/
catalog.section.default.template.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<?if(!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)die();?>
<?echo ("<pre>");?>
<?//print_r($arResult);?>
<?echo ("</pre>");?>
<?function orderBy($data, $field)
{
$code = "return strnatcmp(\$a['$field'], \$b['$field']);";
usort($data, create_function('$a,$b', $code));
return $data;
}
?>
<?if ($arResult["ITEMS"])
{?>
<table cellpadding="1" cellspacing="1" class="prodtable" >
<tr style="background-color:#D7EBF4;">
<td align="center">Êîä òîâàðà</td>
<td align="center" width="392px">Íàèìåíîâàíèå, êðàòêîå îïèñàíèå</td>
<td>Ôîòî</td>
<td align="center">Íà ñêëàäå</td>
<td align="center">Òðàíçèò</td>
<td align="center">Öåíà</td>
<td></td>
</tr>
<?foreach($arResult["ITEMS"] as $cell=>$arElement)
{?>
<tr>
<td align="center"><?=$arElement["PROPERTIES"]["PRODUCT_ID"]["VALUE"]?></td>
<td><a href="<?=$arElement["DETAIL_PAGE_URL"]?>">
<?=$arElement["NAME"]?>
</a>
<!--<br />
<?=$arElement["PREVIEW_TEXT"]?>
-->
<!--<br />
<noindex>
<a href="<?echo $arElement["BUY_URL"]?>" rel="nofollow"><?echo GetMessage("CATALOG_BUY")?></a>
</noindex>
-->
</td>
<td>
<?if($arElement["PREVIEW_PICTURE"]){?>
<img border="0" src="<?=$arElement["PREVIEW_PICTURE"]["SRC"]?>" width="67" height="73" alt="<?=$arElement["NAME"]?>" title="<?=$arElement["NAME"]?>" align="left" />
<?}?>
</td>
<td align="right">
<?=$arElement["CATALOG_QUANTITY"]?>
</td>
<td align="right">
<?=$arElement["PROPERTIES"]["78"]["VALUE"]?>
</td>
<td align="right" style="padding:0 5px 0 5px;">
<?
$data = orderBy($arElement["PRICES"], 'VALUE');
?>
<?foreach($data as $code=>$arPrice):?>
<?if($arPrice["CAN_ACCESS"]):?>
<nobr><span class="ñ4"><?=$arPrice["PRINT_VALUE"]?></span></nobr>
<?break;?>
<?endif;?>
<?endforeach;?>
</td>
<td valign="bottom">
<form action="<?=$APPLICATION->GetCurPageParam();?>" method="post" enctype="multipart/form-data">
<input type="hidden" name="action" value="BUY">
<input type="hidden" name="id" value="<?=$arElement["ID"]?>">
<nobr><input type="text" name="quantity" value="1" size="3" style="vertical-align: bottom;" /> <input type="submit" name="actionADD2BASKET" value="" class="basket_img" /></nobr>
</form>
</td>
</tr>
<?}?>
</table>
<?}?>
<br /><?=$arResult["NAV_STRING"]?>