当前位置: 首页>>代码示例>>PHP>>正文


PHP CSalePersonType::GetList方法代码示例

本文整理汇总了PHP中CSalePersonType::GetList方法的典型用法代码示例。如果您正苦于以下问题:PHP CSalePersonType::GetList方法的具体用法?PHP CSalePersonType::GetList怎么用?PHP CSalePersonType::GetList使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CSalePersonType的用法示例。


在下文中一共展示了CSalePersonType::GetList方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getPersonTypesList

 /**
  * @param string $siteId Site id.
  * @return array List of person types for given site.
  */
 public static function getPersonTypesList($siteId)
 {
     $dbResultList = \CSalePersonType::GetList("NAME", "ASC", array("LID" => $siteId, "ACTIVE" => "Y"));
     $arPersonTypes = array();
     while ($arPT = $dbResultList->Fetch()) {
         $arPersonTypes[$arPT['ID']] = $arPT['NAME'];
     }
     return $arPersonTypes;
 }
开发者ID:andy-profi,项目名称:bxApiDocs,代码行数:13,代码来源:helper.php

示例2: addPaysysHandler

 protected function addPaysysHandler($psid)
 {
     $a_ps_act = array();
     $fields = array("PAY_SYSTEM_ID" => $psid, "NAME" => Loc::getMessage("DEVTM_ERIP_PS_ACTION_NAME"), "ACTION_FILE" => "/bitrix/php_interface/include/sale_payment/" . $this->MODULE_ID, "NEW_WINDOW" => "N", "HAVE_PREPAY" => "N", "HAVE_RESULT" => "N", "HAVE_ACTION" => "N", "HAVE_PAYMENT" => "Y", "HAVE_RESULT_RECEIVE" => "Y", "ENCODING" => "utf-8");
     $db_pt = CSalePersonType::GetList(array("SORT" => "ASC", "NAME" => "ASC"), array());
     while ($pt = $db_pt->Fetch()) {
         $fields["PERSON_TYPE_ID"] = $pt["ID"];
         $id = CSalePaySystemAction::Add($fields);
         if ($id != false) {
             $a_ps_act[] = $id;
         }
     }
     return $a_ps_act;
 }
开发者ID:dimabresky,项目名称:bitrix-Erip-module,代码行数:14,代码来源:index.php

示例3: GetSettingsArray

 public static function GetSettingsArray()
 {
     $arSaleProps = array();
     if (CModule::IncludeModule('sale')) {
         $rsPersonType = CSalePersonType::GetList(array('SORT' => 'ASC', 'NAME' => 'ASC'), array('ACTIVE' => 'Y'));
         while ($rsPersonRow = $rsPersonType->GetNext()) {
             $arSaleProps[] = $rsPersonRow;
         }
         foreach ($arSaleProps as $arSalePropKey => $arSalePropVal) {
             $rsOrderProps = CSaleOrderProps::GetList(array('SORT' => 'ASC'), array('PERSON_TYPE_ID' => $arSalePropVal['ID'], 'UTIL' => 'N'));
             while ($rsOrderPropRow = $rsOrderProps->GetNext()) {
                 $arSaleProps[$arSalePropKey]['PROPERTIES'][] = $rsOrderPropRow;
             }
         }
     }
     return $arSaleProps;
 }
开发者ID:ASDAFF,项目名称:suggestions-bitrix,代码行数:17,代码来源:settingsclass.php

示例4: __IncludeLang

if (strlen($arParams["site_id"]) <= 0) {
    $siteID = "s1";
}
$dbSite = CSite::GetByID($siteID);
if ($arSite = $dbSite->Fetch()) {
    $lang = $arSite["LANGUAGE_ID"];
}
if (strlen($lang) <= 0) {
    $lang = "ru";
}
$bRus = false;
if ($lang == "ru") {
    $bRus = true;
}
__IncludeLang(GetLangFileName(dirname(__FILE__) . "/lang/", "/" . basename(__FILE__), $lang));
$dbPerson = CSalePersonType::GetList(array());
if (!$dbPerson->Fetch()) {
    //Person Types
    $arGeneralInfo["personType"]["fiz"] = CSalePersonType::Add(array("LID" => $siteID, "NAME" => GetMessage("SALE_WIZARD_PERSON_1"), "SORT" => "100"));
    $arGeneralInfo["personType"]["ur"] = CSalePersonType::Add(array("LID" => $siteID, "NAME" => GetMessage("SALE_WIZARD_PERSON_2"), "SORT" => "150"));
    //currecny to site
    $dbUserAccount = CSaleUserAccount::GetList(array(), array("USER_ID" => 1));
    if (!$dbUserAccount->Fetch()) {
        if ($bRus) {
            CSaleLang::Add(array("LID" => $siteID, "CURRENCY" => "RUB"));
            CSaleUserAccount::Add(array("USER_ID" => 1, "CURRENT_BUDGET" => 1000, "CURRENCY" => "RUB"));
        } else {
            CSaleLang::Add(array("LID" => $siteID, "CURRENCY" => "USD"));
            CSaleUserAccount::Add(array("USER_ID" => 1, "CURRENT_BUDGET" => 100, "CURRENCY" => "USD"));
        }
    }
开发者ID:webgksupport,项目名称:alpina,代码行数:31,代码来源:step1.php

示例5: GetControls

	/**
	 * @param bool|string $strControlID
	 * @return array|bool
	 */
	public static function GetControls($strControlID = false)
	{
		$arSalePersonTypes = array();
		$arFilter = array();
		if (static::$boolInit)
		{
			if (isset(static::$arInitParams['SITE_ID']))
				$arFilter['LID'] = static::$arInitParams['SITE_ID'];
		}
		$rsPersonTypes = CSalePersonType::GetList(array(), $arFilter, false, false, array('ID', 'NAME', 'LIDS'));
		while ($arPersonType = $rsPersonTypes->Fetch())
		{
			$arPersonType['ID'] = intval($arPersonType['ID']);
			$arSalePersonTypes[$arPersonType['ID']] = $arPersonType['NAME'].'('.implode(' ', $arPersonType['LIDS']).')';
		}

		$arSalePaySystemList = array();
		$arFilter = array();
		$rsPaySystems = CSalePaySystem::GetList(array(), $arFilter, false, false, array('ID', 'NAME'));
		while ($arPaySystem = $rsPaySystems->Fetch())
		{
			$arSalePaySystemList[$arPaySystem['ID']] = $arPaySystem['NAME'];
		}

		$arSaleDeliveryList = array();
		$arFilter = array();
		if (static::$boolInit)
		{
			if (isset(static::$arInitParams['SITE_ID']))
				$arFilter['LID'] = static::$arInitParams['SITE_ID'];
		}

		$rsDeliverySystems = CSaleDelivery::GetList(array(), $arFilter, false, false, array('ID', 'LID', 'NAME'));
		while ($arDelivery = $rsDeliverySystems->Fetch())
		{
			$arSaleDeliveryList[$arDelivery['ID']] = $arDelivery['NAME'].' ('.$arDelivery['LID'].')';
		}

		$arFilter = array();
		if (static::$boolInit)
		{
			if (isset(static::$arInitParams['SITE_ID']))
				$arFilter['SITE'] = static::$arInitParams['SITE_ID'];
		}

		$rsDeliveryHandlers = CSaleDeliveryHandler::GetList(array(),$arFilter);
		while ($arDeliveryHandler = $rsDeliveryHandlers->Fetch())
		{
			$boolSep = true;
			if (!empty($arDeliveryHandler['PROFILES']) && is_array($arDeliveryHandler['PROFILES']))
			{
				foreach ($arDeliveryHandler['PROFILES'] as $key => $arProfile)
				{
					$arSaleDeliveryList[$arDeliveryHandler['SID'].':'.$key] = $arDeliveryHandler['NAME'];
				}
			}
		}

		$arLabels = array(
			BT_COND_LOGIC_EQ => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_EQ_LABEL'),
			BT_COND_LOGIC_NOT_EQ => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_NOT_EQ_LABEL'),
			BT_COND_LOGIC_GR => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_GR_LABEL'),
			BT_COND_LOGIC_LS => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_LS_LABEL'),
			BT_COND_LOGIC_EGR => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_EGR_LABEL'),
			BT_COND_LOGIC_ELS => Loc::getMessage('BT_SALE_AMOUNT_LOGIC_ELS_LABEL')
		);
		$arLabelsWeight = array(
			BT_COND_LOGIC_EQ => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_EQ_LABEL'),
			BT_COND_LOGIC_NOT_EQ => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_NOT_EQ_LABEL'),
			BT_COND_LOGIC_GR => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_GR_LABEL'),
			BT_COND_LOGIC_LS => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_LS_LABEL'),
			BT_COND_LOGIC_EGR => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_EGR_LABEL'),
			BT_COND_LOGIC_ELS => Loc::getMessage('BT_SALE_WEIGHT_LOGIC_ELS_LABEL')
		);

		$arControlList = array(
			'CondSaleOrderSumm' => array(
				'ID' => 'CondSaleOrderSumm',
				'FIELD' => 'ORDER_PRICE',
				'FIELD_TYPE' => 'double',
				'LABEL' => Loc::getMessage('BT_MOD_SALE_COND_CMP_SALE_ORDER_SUMM_LABEL_EXT'),
				'PREFIX' => Loc::getMessage('BT_MOD_SALE_COND_CMP_SALE_ORDER_SUMM_PREFIX_EXT'),
				'LOGIC' => static::GetLogicEx(array_keys($arLabels), $arLabels),
				'JS_VALUE' => array(
					'type' => 'input'
				)
			),
			'CondSalePersonType' => array(
				'ID' => 'CondSalePersonType',
				'FIELD' => 'PERSON_TYPE_ID',
				'FIELD_TYPE' => 'int',
				'LABEL' => Loc::getMessage('BT_MOD_SALE_COND_CMP_SALE_PERSON_TYPE_LABEL'),
				'PREFIX' => Loc::getMessage('BT_MOD_SALE_COND_CMP_SALE_PERSON_TYPE_PREFIX'),
				'LOGIC' => static::GetLogic(array(BT_COND_LOGIC_EQ, BT_COND_LOGIC_NOT_EQ)),
				'JS_VALUE' => array(
					'type' => 'select',
//.........这里部分代码省略.........
开发者ID:akniyev,项目名称:arteva.ru,代码行数:101,代码来源:sale_cond.php

示例6: obtainDataReferences

 /**
  * Function returns reference data as shared cache between this component and sale.personal.order.list.
  *
  * @throws Exception
  * @return void
  */
 protected function obtainDataReferences()
 {
     if ($this->startCache(array('spo-shared'))) {
         try {
             $cachedData = array();
             /////////////////////
             /////////////////////
             // Person type
             $dbPType = CSalePersonType::GetList(array("SORT" => "ASC"));
             while ($arPType = $dbPType->Fetch()) {
                 $cachedData['PERSON_TYPE'][$arPType["ID"]] = $arPType;
             }
             // Save statuses for Filter form
             $dbStatus = CSaleStatus::GetList(array("SORT" => "ASC"), array("LID" => LANGUAGE_ID));
             while ($arStatus = $dbStatus->Fetch()) {
                 $cachedData['STATUS'][$arStatus["ID"]] = $arStatus;
             }
             $dbPaySystem = CSalePaySystem::GetList(array("SORT" => "ASC"));
             while ($arPaySystem = $dbPaySystem->Fetch()) {
                 $cachedData['PAYSYS'][$arPaySystem["ID"]] = $arPaySystem;
             }
             $dbDelivery = CSaleDelivery::GetList(array("SORT" => "ASC"));
             while ($arDelivery = $dbDelivery->Fetch()) {
                 $cachedData['DELIVERY'][$arDelivery["ID"]] = $arDelivery;
             }
             $dbDelivery = CSaleDeliveryHandler::GetList(array(), array(array("SITE_ID" => SITE_ID)));
             while ($arDeliveryHandler = $dbDelivery->Fetch()) {
                 $cachedData['DELIVERY_HANDLERS'][$arDeliveryHandler["SID"]] = $arDeliveryHandler;
             }
             /////////////////////
             /////////////////////
         } catch (Exception $e) {
             $this->abortCache();
             throw $e;
         }
         $this->endCache($cachedData);
     } else {
         $cachedData = $this->getCacheData();
     }
     $this->dbResult = array_merge($this->dbResult, $this->adaptCachedReferences($cachedData));
 }
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:47,代码来源:class.php

示例7: strlen

	$LID = $str_LID;
	$str_DELIVERY_ID = (isset($_POST["DELIVERY_ID"]) && strlen($_POST["DELIVERY_ID"]) > 0) ? $_POST["DELIVERY_ID"] : $str_DELIVERY_ID;
	$str_PAY_SYSTEM_ID = (isset($_POST["PAY_SYSTEM_ID"]) && intval($_POST["PAY_SYSTEM_ID"]) > 0) ? intval($_POST["PAY_SYSTEM_ID"]) : $str_PAY_SYSTEM_ID;
}

if (!isset($str_TAX_VALUE) OR $str_TAX_VALUE == "")
	$str_TAX_VALUE = 0;

if (intval($str_PERSON_TYPE_ID) <= 0)
{
	$str_PERSON_TYPE_ID = 0;
	$arFilter = array();
	$arFilter["ACTIVE"] = "Y";
	if(strlen($LID) > 0)
		$arFilter["LID"] = $LID;
	$dbPersonType = CSalePersonType::GetList(array("SORT" => "ASC", "NAME" => "ASC"), $arFilter, false, array('nTopCount' => 1), array('ID'));
	if($arPersonType = $dbPersonType->Fetch())
		$str_PERSON_TYPE_ID = $arPersonType["ID"];
}

$arFuserItems = CSaleUser::GetList(array("USER_ID" => intval($str_USER_ID)));
$FUSER_ID = $arFuserItems["ID"];

/*
 * form select site
 */
if ((!isset($LID) OR $LID == "") AND (defined('BX_PUBLIC_MODE') OR BX_PUBLIC_MODE == 1) )
{
	$arSitesShop = array();
	$arSitesTmp = array();
	$rsSites = CSite::GetList($by="id", $order="asc", array("ACTIVE" => "Y"));
开发者ID:ASDAFF,项目名称:entask.ru,代码行数:31,代码来源:order_new.php

示例8: fGetBuyerType

function fGetBuyerType($PERSON_TYPE_ID, $LID, $USER_ID = '', $ORDER_ID = 0, $formVarsSubmit = false)
{
	global $locationZipID, $locationID, $DELIVERY_LOCATION, $DELIVERY_LOCATION_ZIP;
	$resultHtml = "<script>locationZipID = 0;locationID = 0;</script><table width=\"100%\" id=\"order_type_props\" class=\"edit-table\">";

	//select person type
	$arPersonTypeList = array();
	$personTypeSelect = "<select name='buyer_type_id' id='buyer_type_id' OnChange='fBuyerChangeType(this);' >";
	$dbPersonType = CSalePersonType::GetList(array("SORT" => "ASC", "NAME" => "ASC"), array("ACTIVE" => "Y"));
	while ($arPersonType = $dbPersonType->GetNext())
	{
		if (!in_array($LID, $arPersonType["LIDS"]))
			continue;

		if (!isset($PERSON_TYPE_ID) OR $PERSON_TYPE_ID == "")
			$PERSON_TYPE_ID = $arPersonType["ID"];

		$class = "";
		if (intval($arPersonType["ID"]) == intval($PERSON_TYPE_ID))
			$class = " selected";

		$personTypeSelect .= "<option value=\"".$arPersonType["ID"]."\" ".$class.">".$arPersonType["NAME"]." [".$arPersonType["ID"]."]</option>";
	}
	$personTypeSelect .= "</select>";

	$userComment = "";
	$userDisplay = "none";
	if (intval($ORDER_ID) > 0)
	{
		$dbOrder = CSaleOrder::GetList(
			array(),
			array("ID" => $ORDER_ID, "ACTIVE" => "Y"),
			false,
			false,
			array()
		);
		$arOrder = $dbOrder->Fetch();
		$userComment = $arOrder["USER_DESCRIPTION"];
		$userDisplay = "table-row";
	}

	if ($formVarsSubmit && $_REQUEST["btnTypeBuyer"] == "btnBuyerNew")
		$userDisplay = "none";
	elseif ($formVarsSubmit && $_REQUEST["btnTypeBuyer"] == "btnBuyerExist")
		$userDisplay = "table-row";

	$resultHtml .= "<tr id=\"btnBuyerExistField\" style=\"display:".$userDisplay."\">
			<td class=\"adm-detail-content-cell-l\" width=\"40%\">".GetMessage("NEWO_BUYER").":</td>
			<td class=\"adm-detail-content-cell-r\" width=\"60%\"><div id=\"user_name\">".fGetUserName($USER_ID)."</div></td></tr>";

	$resultHtml .= "<tr class=\"adm-detail-required-field\">
		<td class=\"adm-detail-content-cell-l\" width=\"40%\">".GetMessage("SOE_PERSON_TYPE").":</td>
		<td class=\"adm-detail-content-cell-r\" width=\"60%\">".$personTypeSelect."</td>
	</tr>";

	$bShowTrProfile = "none";
	if ($formVarsSubmit && $_POST["btnTypeBuyer"] == "btnBuyerExist")
		$bShowTrProfile = "table-row";

	$resultHtml .= "<tr id=\"buyer_profile_display\" style=\"display:".$bShowTrProfile."\" class=\"adm-detail-required-field\">
		<td class=\"adm-detail-content-cell-l\">".GetMessage("NEWO_BUYER_PROFILE").":</td>
		<td class=\"adm-detail-content-cell-r\">
			<div id=\"buyer_profile_select\">";

			if ($formVarsSubmit && $_POST["btnTypeBuyer"] == "btnBuyerExist")
			{
				$resultHtml .= fUserProfile(intval($_POST["user_id"]), intval($_POST["buyer_type_id"]), $default = '');
			}

	$resultHtml .= "</div></td>
	</tr>";

	if ($ORDER_ID <= 0)
	{
		$arCountProps = fGetCountProfileProps($PERSON_TYPE_ID);
		$resultHtml .= "<tr id=\"btnBuyerNewField\">";
		if (count($arCountProps) < 3)
		{
			$resultHtml .= "<td colspan=2>
					<table width=\"100%\" class=\"edit-table\" >";
					if (intval($arCountProps["IS_EMAIL"]) <= 0)
						$resultHtml .= "<tr class=\"adm-detail-required-field\">
							<td class=\"adm-detail-content-cell-l\" width=\"40%\">".GetMessage("NEWO_BUYER_REG_MAIL")."</td>
							<td class=\"adm-detail-content-cell-r\"><input type=\"text\" name=\"NEW_BUYER_EMAIL\" size=\"30\" value=\"".htmlspecialcharsbx(trim($_REQUEST["NEW_BUYER_EMAIL"]))."\" tabindex=\"1\" /></td>
						</tr>";
					if (intval($arCountProps["IS_PAYER"]) <= 0)
						$resultHtml .= "<tr class=\"adm-detail-required-field\">
							<td class=\"adm-detail-content-cell-l\">".GetMessage("NEWO_BUYER_REG_LASTNAME")."</td>
							<td class=\"adm-detail-content-cell-r\"><input type=\"text\" name=\"NEW_BUYER_LAST_NAME\" size=\"30\" value=\"".htmlspecialcharsbx(trim($_REQUEST["NEW_BUYER_LAST_NAME"]))."\" tabindex=\"3\" /></td>
						</tr>
						<tr class=\"adm-detail-required-field\">
							<td class=\"adm-detail-content-cell-l\">".GetMessage("NEWO_BUYER_REG_NAME")."</td>
							<td class=\"adm-detail-content-cell-r\"><input type=\"text\" name=\"NEW_BUYER_NAME\" size=\"30\" value=\"".htmlspecialcharsbx(trim($_REQUEST["NEW_BUYER_NAME"]))."\" tabindex=\"2\" /></td>
						</tr>";
					$resultHtml .= "</table>
				</td>";
		}
		$resultHtml .= "</tr>";
	}

//.........这里部分代码省略.........
开发者ID:akniyev,项目名称:arteva.ru,代码行数:101,代码来源:admin_tool.php

示例9: obtainDataReferences

 /**
  * Function returns reference data as shared cache between this component and sale.personal.order.list.
  *
  * @throws Exception
  * @return void
  */
 protected function obtainDataReferences()
 {
     if ($this->startCache(array('spo-shared'))) {
         try {
             $cachedData = array();
             /////////////////////
             /////////////////////
             // Person type
             $dbPType = CSalePersonType::GetList(array("SORT" => "ASC"));
             while ($arPType = $dbPType->Fetch()) {
                 $cachedData['PERSON_TYPE'][$arPType["ID"]] = $arPType;
             }
             // Save statuses for Filter form
             $dbStatus = CSaleStatus::GetList(array("SORT" => "ASC"), array("LID" => LANGUAGE_ID));
             while ($arStatus = $dbStatus->Fetch()) {
                 $cachedData['STATUS'][$arStatus["ID"]] = $arStatus;
             }
             $dbPaySystem = CSalePaySystem::GetList(array("SORT" => "ASC"));
             while ($arPaySystem = $dbPaySystem->Fetch()) {
                 $arPaySystem['NAME'] = htmlspecialcharsbx($arPaySystem['NAME']);
                 $cachedData['PAYSYS'][$arPaySystem["ID"]] = $arPaySystem;
             }
             $cachedData['DELIVERY'] = array();
             $shipmentIds = array();
             foreach ($this->dbResult['SHIPMENT'] as $shipment) {
                 $shipmentIds[] = $shipment['DELIVERY_ID'];
             }
             $dbDelivery = \Bitrix\Sale\Delivery\Services\Table::getList(array('select' => array('ID', 'NAME', 'PARENT_NAME' => 'PARENT.NAME', 'PARENT_CLASS_NAME' => 'PARENT.CLASS_NAME'), 'filter' => array('ID' => $shipmentIds)));
             $deliveryService = array();
             while ($delivery = $dbDelivery->fetch()) {
                 $deliveryService[$delivery['ID']] = $delivery;
             }
             foreach ($deliveryService as $delivery) {
                 $cachedData['DELIVERY'][$delivery["ID"]] = array();
                 if ($delivery['PARENT_NAME']) {
                     $cachedData['DELIVERY'][$delivery["ID"]]['NAME'] = htmlspecialcharsbx($delivery['PARENT_NAME'] . ':' . $delivery['NAME']);
                 } else {
                     $cachedData['DELIVERY'][$delivery["ID"]]['NAME'] = htmlspecialcharsbx($delivery['NAME']);
                 }
             }
             /////////////////////
             /////////////////////
         } catch (Exception $e) {
             $this->abortCache();
             throw $e;
         }
         $this->endCache($cachedData);
     } else {
         $cachedData = $this->getCacheData();
     }
     $this->dbResult = array_merge($this->dbResult, $this->adaptCachedReferences($cachedData));
 }
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:58,代码来源:class.php

示例10: array

         }
     }
     $arResultItem["DETAIL_PICTURE_SRC"] = "";
     if (isset($arResultItem["DETAIL_PICTURE"]) && intval($arResultItem["DETAIL_PICTURE"]) > 0) {
         $arImage = CFile::GetFileArray($arResultItem["DETAIL_PICTURE"]);
         if ($arImage) {
             $arFileTmp = CFile::ResizeImageGet($arImage, array("width" => "110", "height" => "110"), BX_RESIZE_IMAGE_PROPORTIONAL, true);
             $arResultItem["DETAIL_PICTURE_SRC"] = $arFileTmp["src"];
         }
     }
 }
 if (isset($arResultItem)) {
     unset($arResultItem);
 }
 /* Person Type Begin */
 $dbPersonType = CSalePersonType::GetList(array("SORT" => "ASC", "NAME" => "ASC"), array("LID" => SITE_ID, "ACTIVE" => "Y"));
 while ($arPersonType = $dbPersonType->GetNext()) {
     if ($arUserResult["PERSON_TYPE_ID"] == $arPersonType["ID"] || IntVal($arUserResult["PERSON_TYPE_ID"]) <= 0) {
         $arUserResult["PERSON_TYPE_ID"] = $arPersonType["ID"];
         $arPersonType["CHECKED"] = "Y";
     }
     $arResult["PERSON_TYPE"][$arPersonType["ID"]] = $arPersonType;
 }
 foreach (GetModuleEvents("sale", "OnSaleComponentOrderOneStepPersonType", true) as $arEvent) {
     ExecuteModuleEventEx($arEvent, array(&$arResult, &$arUserResult, &$arParams));
 }
 /* Person Type End */
 /* User Profiles Begin */
 $bFirst = false;
 $dbUserProfiles = CSaleOrderUserProps::GetList(array("DATE_UPDATE" => "DESC"), array("PERSON_TYPE_ID" => $arUserResult["PERSON_TYPE_ID"], "USER_ID" => IntVal($USER->GetID())));
 while ($arUserProfiles = $dbUserProfiles->GetNext()) {
开发者ID:sharapudinov,项目名称:lovestore.top,代码行数:31,代码来源:component.php

示例11: array

<?php

if (!defined('B_PROLOG_INCLUDED') || B_PROLOG_INCLUDED !== true) {
    die;
}
$arCurrencyTypes = array("" => GetMessage("SPT_ALLOWED_CURRENCY_ALL"));
if (CModule::IncludeModule("currency")) {
    $rsCurrency = CCurrency::GetList($by = "name", $order = "desc", LANGUAGE_ID);
    while ($arCurrency = $rsCurrency->Fetch()) {
        $arCurrencyTypes[$arCurrency["CURRENCY"]] = $arCurrency["FULL_NAME"];
    }
}
$arPersonTypes = array();
if (CModule::IncludeModule('sale')) {
    $dbPerson = CSalePersonType::GetList(array('SORT' => 'ASC', 'NAME' => 'ASC'), array('ACTIVE' => 'Y'));
    while ($arPerson = $dbPerson->fetch()) {
        $arPersonTypes[$arPerson['ID']] = $arPerson['NAME'];
    }
}
$arComponentParameters = array("PARAMETERS" => array("ALLOWED_CURRENCY" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_ALLOWED_CURRENCY"), "TYPE" => "LIST", "MULTIPLE" => "Y", "VALUES" => $arCurrencyTypes), "DEFAULT_CURRENCY" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_DEFAULT_CURRENCY"), "TYPE" => "LIST", "VALUES" => $arCurrencyTypes), "COMISSION" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_COMISSION"), "TYPE" => "STRING", "DEFAULT" => "0", "COLS" => "5"), "CART_PAGE" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_CART_PAGE"), "TYPE" => "STRING"), "PAY_IMMED" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_PAY_IMMED"), "TYPE" => "CHECKBOX", "REFRESH" => "Y"), "PERSON_TYPE" => array("PARENT" => "BASE", "NAME" => GetMessage("SPT_PERSON_TYPE"), "TYPE" => "LIST", "VALUES" => $arPersonTypes), "SET_TITLE" => array()));
if ($arCurrentValues['PAY_IMMED'] == 'Y') {
    unset($arComponentParameters['PARAMETERS']['CART_PAGE']);
} else {
    unset($arComponentParameters['PARAMETERS']['PERSON_TYPE']);
}
开发者ID:Hawkart,项目名称:megatv,代码行数:25,代码来源:.parameters.php

示例12: LocalRedirect

    if (!($arOrderOldTmp = $dbOrder->ExtractFields("str_"))) {
        LocalRedirect("sale_order.php?lang=" . LANG . GetFilterParams("filter_", false));
    }
    $LID = $str_LID;
}
if (!isset($str_TAX_VALUE) or $str_TAX_VALUE == "") {
    $str_TAX_VALUE = 0;
}
if (IntVal($str_PERSON_TYPE_ID) <= 0) {
    $str_PERSON_TYPE_ID = 0;
    $arFilter = array();
    $arFilter["ACTIVE"] = "Y";
    if (strlen($LID) > 0) {
        $arFilter["LID"] = $LID;
    }
    $dbPersonType = CSalePersonType::GetList(array("ID" => "ASC"), $arFilter);
    if ($arPersonType = $dbPersonType->Fetch()) {
        $str_PERSON_TYPE_ID = $arPersonType["ID"];
    }
}
$arFuserItems = CSaleUser::GetList(array("USER_ID" => intval($str_USER_ID)));
$FUSER_ID = $arFuserItems["ID"];
/*
 * form select site
 */
if ((!isset($LID) or $LID == "") and (defined('BX_PUBLIC_MODE') or BX_PUBLIC_MODE == 1)) {
    $arSitesShop = array();
    $arSitesTmp = array();
    $rsSites = CSite::GetList($by = "id", $order = "asc", array("ACTIVE" => "Y"));
    while ($arSite = $rsSites->Fetch()) {
        $site = COption::GetOptionString("sale", "SHOP_SITE_" . $arSite["ID"], "");
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:order_new.php

示例13: CAdminResult

                @set_time_limit(0);
                $DB->StartTransaction();
                if (!CSalePersonType::Delete($ID)) {
                    $DB->Rollback();
                    if ($ex = $APPLICATION->GetException()) {
                        $lAdmin->AddGroupError($ex->GetString(), $ID);
                    } else {
                        $lAdmin->AddGroupError(GetMessage("SPTAN_ERROR_DELETE"), $ID);
                    }
                }
                $DB->Commit();
                break;
        }
    }
}
$dbResultList = CSalePersonType::GetList($by, $order, $arFilter);
$dbResultList = new CAdminResult($dbResultList, $sTableID);
$dbResultList->NavStart();
$lAdmin->NavText($dbResultList->GetNavPrint(GetMessage("PERS_TYPE_NAV")));
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => GetMessage("PERS_TYPE_ID"), "sort" => "id", "default" => true), array("id" => "NAME", "content" => GetMessage("PERS_TYPE_NAME"), "sort" => "name", "default" => true), array("id" => "ACTIVE", "content" => GetMessage("PERS_ACTIVE"), "sort" => "ACTIVE", "default" => true), array("id" => "LID", "content" => GetMessage('PERS_TYPE_LID'), "sort" => false, "default" => true), array("id" => "SORT", "content" => GetMessage("PERS_TYPE_SORT"), "sort" => "sort", "default" => true), array("id" => "PROPS", "content" => GetMessage("PERS_PROPS"), "sort" => "", "default" => true)));
$arVisibleColumns = $lAdmin->GetVisibleHeaderColumns();
$arLangs = array();
$dbLangsList = CLang::GetList($b = "sort", $o = "asc");
while ($arLang = $dbLangsList->Fetch()) {
    $arLangs[$arLang["LID"]] = "[" . htmlspecialcharsbx($arLang["LID"]) . "]&nbsp;" . htmlspecialcharsbx($arLang["NAME"]);
}
while ($arPersonType = $dbResultList->NavNext(true, "f_")) {
    $row =& $lAdmin->AddRow($f_ID, $arPersonType, "sale_person_type_edit.php?ID=" . $f_ID . "&lang=" . LANG . GetFilterParams("filter_"), GetMessage("SPTAN_UPDATE_ALT"));
    $row->AddField("ID", "<a href=\"" . "sale_person_type_edit.php?ID=" . $f_ID . "&lang=" . LANG . GetFilterParams("filter_") . "\">" . $f_ID . "</a>");
    $row->AddInputField("NAME", array("size" => "30"));
    $LIDS = "";
开发者ID:Satariall,项目名称:izurit,代码行数:31,代码来源:person_type.php

示例14: ClearVars

require_once $_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/sale/include.php';
ClearVars();
ClearVars('f_');
ClearVars('l_');
use Bitrix\Sale\Internals\Input, Bitrix\Sale\Internals\OrderPropsTable, Bitrix\Sale\Internals\PersonTypeTable, Bitrix\Main\Localization\Loc;
Loc::loadMessages(__FILE__);
$propertyId = $ID;
$personTypeId = $PERSON_TYPE_ID;
unset($ID, $PERSON_TYPE_ID);
// load person types
$personTypes = array();
//$result = PersonTypeTable::getList(array( // TODO LIDS
//	'select'  => array('ID', 'NAME', 'LID', 'DOMAIN' => 'SALE.DOMAIN'),
//	'order'   => array('LID', 'SORT', 'NAME'),
//));
$result = CSalePersonType::GetList(array('SORT' => 'ASC', 'NAME' => 'ASC'), array());
while ($row = $result->Fetch()) {
    $personTypes[$row['ID']] = array('ID' => $row['ID'], 'NAME' => htmlspecialcharsex($row['NAME']), 'LID' => htmlspecialcharsex(implode(", ", $row['LIDS'])));
}
$errors = array();
$reload = 'reloadForm()';
$variants = array();
// PREPARE PROPERTY, RELATIONS /////////////////////////////////////////////////////////////////////////////////////////
// 1. load property from database if exists
$existentProperty = $propertyId ? OrderPropsTable::getById($propertyId)->fetch() : null;
// 1. get property from post
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
    $_POST = Input\File::getPostWithFiles($_POST, $_FILES);
    //	// MULTIPLE_DEBUG
    //	if ($_POST['TYPE'] != 'ENUM' && $_POST['TYPE'] != 'FILE')
    //		$_POST['MULTIPLE'] = 'N';
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:31,代码来源:order_props_edit.php

示例15: GetMessage

		<td>
			<select name="filter_ps_status">
				<option value=""><?echo GetMessage("SALE_F_ALL")?></option>
				<option value="Y"<?if ($filter_ps_status=="Y") echo " selected"?>><?echo GetMessage("SALE_YES")?></option>
				<option value="N"<?if ($filter_ps_status=="N") echo " selected"?>><?echo GetMessage("SALE_NO")?></option>
				<option value="X"<?if ($filter_ps_status=="X") echo " selected"?>><?echo GetMessage("SALE_YES_NO")?></option>
			</select>
		</td>
	</tr>
	<tr>
		<td><?echo GetMessage("SALE_F_PERSON_TYPE");?>:</td>
		<td>
			<select name="filter_person_type[]" multiple size="3">
				<option value=""><?echo GetMessage("SALE_F_ALL")?></option>
				<?
				$l = CSalePersonType::GetList(Array("SORT"=>"ASC", "NAME"=>"ASC"), Array());
				while ($personType = $l->Fetch()):
					?><option value="<?echo htmlspecialcharsbx($personType["ID"])?>"<?if (is_array($filter_person_type) && in_array($personType["ID"], $filter_person_type)) echo " selected"?>>[<?echo htmlspecialcharsbx($personType["ID"]) ?>] <?echo htmlspecialcharsbx($personType["NAME"])?> <?echo "(".htmlspecialcharsbx(implode(", ", $personType["LIDS"])).")";?></option><?
				endwhile;
				?>
			</select>
		</td>
	</tr>
	<tr>
		<td><?echo GetMessage("SALE_F_PAY_SYSTEM");?>:</td>
		<td>
			<select name="filter_pay_system[]" multiple size="3">
				<option value=""><?echo GetMessage("SALE_F_ALL")?></option>
				<?
				$l = CSalePaySystem::GetList(Array("SORT"=>"ASC", "NAME"=>"ASC"), Array());
				while ($paySystem = $l->Fetch()):
开发者ID:akniyev,项目名称:arteva.ru,代码行数:31,代码来源:order.php


注:本文中的CSalePersonType::GetList方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。