<?
$priceTotal = 0;
$bUseVat = false;
$arBasketOrder = array();
for ($i = 0, $countBasketIds = count($arBasketIDs); $i < $countBasketIds; $i++)
{
$arBasketTmp = CSaleBasket::GetByID($arBasketIDs[$i]);
if (floatval($arBasketTmp["VAT_RATE"]) > 0 )
$bUseVat = true;
$priceTotal += $arBasketTmp["PRICE"]*$arBasketTmp["QUANTITY"];
$arBasketTmp["PROPS"] = array();
if (isset($_GET["PROPS_ENABLE"]) && $_GET["PROPS_ENABLE"] == "Y")
{
$dbBasketProps = CSaleBasket::GetPropsList(
array("SORT" => "ASC", "NAME" => "ASC"),
array("BASKET_ID" => $arBasketTmp["ID"]),
false,
false,
array("ID", "BASKET_ID", "NAME", "VALUE", "CODE", "SORT")
);
while ($arBasketProps = $dbBasketProps->GetNext())
$arBasketTmp["PROPS"][$arBasketProps["ID"]] = $arBasketProps;
}
$arBasketOrder[] = $arBasketTmp;
}
$iBlockId = '28';
$file = CFile::MakeFileArray("/backs/doorman.jpg");
$result = CIblockElement::GetList([], ['IBLOCK_ID' => $iBlockId, 'INCLUDE_SUBSECTIONS' => 'Y'], false, false, ['ID']);
while ($element = $result->Fetch()) {
$values = ['n0' => ['VALUE' => $file, 'DESCRIPTION']];
CIBlockElement::SetPropertyValuesEx($element['ID'], $iBlockId, ['MORE_PHOTO' => $values]);
}