Created
November 14, 2018 14:40
-
-
Save anoriar/4e1e2d8074faa2af7f5477568fae72ef to your computer and use it in GitHub Desktop.
saleOrders + saleOrders props
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$arOrders = []; | |
//Берем все заказы | |
$arFilter = Array("PROPERTY_VAL_BY_CODE_UPLOAD_SUZ" => "N", "ID" => 86589); | |
$rsSales = CSaleOrder::GetList(array("DATE_INSERT" => "DESC"), $arFilter, false, false, array("*")); | |
while ($arSales = $rsSales->Fetch()) { | |
$arOrders[$arSales["ID"]] = $arSales; | |
} | |
//берем все свойства заказов по их кодам | |
$orderProps = []; | |
$db_props = CSaleOrderPropsValue::GetList( | |
array("DATE_INSERT" => "DESC"), ["ORDER_ID" => array_keys($arOrders)], false, false, array("*") | |
); | |
while ($arProps = $db_props->Fetch()) { | |
$orderProps[$arProps["ID"]] = $arProps; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment