本文整理汇总了PHP中CAdminResult::GetNavSize方法的典型用法代码示例。如果您正苦于以下问题:PHP CAdminResult::GetNavSize方法的具体用法?PHP CAdminResult::GetNavSize怎么用?PHP CAdminResult::GetNavSize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CAdminResult
的用法示例。
在下文中一共展示了CAdminResult::GetNavSize方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
$arHeaders[] = array("id" => "MARK_ID", "content" => GetMessage("SUP_MARK"), "default" => false, "sort" => "s_mark");
if ($bADS) {
$arHeaders[] = array("id" => "PROBLEM_TIME", "content" => GetMessage("SUP_PROBLEM_TIME"), "default" => false, "sort" => "s_problem_time");
}
if ($bADS) {
$arHeaders[] = array("id" => "COUPON", "content" => GetMessage("SUP_COUPON"), "default" => false, "sort" => "s_coupon");
}
if ($bADS) {
$arHeaders[] = array("id" => "SUPPORT_DEADLINE", "content" => GetMessage("SUP_DEADLINE"), "default" => true, "sort" => "s_deadline");
}
$USER_FIELD_MANAGER->AdminListAddHeaders($entity_id, $arHeaders);
// заголовок списка
$lAdmin->AddHeaders($arHeaders);
$get_user_name = "N";
//$rsData = CTicket::GetList($by, $order, $arFilter, $is_filtered, "Y", $get_user_name, $get_extra_names);
$rsData = CTicket::GetList($by, $order, $arFilter, $is_filtered, "Y", $get_user_name, $get_extra_names, false, array("SELECT" => $lAdmin->GetVisibleHeaderColumns(), 'NAV_PARAMS' => array('nPageSize' => CAdminResult::GetNavSize($sTableID), 'bShowAll' => false)));
$rsData = new CAdminResult($rsData, $sTableID);
// установка строки навигации
$lAdmin->NavText($rsData->GetNavPrint(GetMessage("SUP_PAGES")));
// построение списка
$arRows = array();
$aUserIDs = array();
$arGuestIDs = array();
$arUsersPref = array("RESPONSIBLE", "OWNER", "CREATED", "MODIFIED");
$arGuestsPref = array("OWNER", "CREATED", "MODIFIED");
while ($arRes = $rsData->NavNext(true, "f_")) {
$lamp = "/bitrix/images/support/{$f_LAMP}.gif";
$lamp_alt = GetMessage("SUP_" . strtoupper($f_LAMP) . "_ALT");
/*if ($get_user_name=="N")
{
Support_GetUserInfo($f_RESPONSIBLE_USER_ID, $f_RESPONSIBLE_LOGIN, $f_RESPONSIBLE_NAME);
示例2: array
}
$propertyOrder = array();
if ($by == 'PROPERTY_TYPE') {
$propertyOrder = array('PROPERTY_TYPE' => $order, 'USER_TYPE' => $order);
} else {
$propertyOrder = array(strtoupper($by) => strtoupper($order));
}
if (!isset($propertyOrder['ID'])) {
$propertyOrder['ID'] = 'ASC';
}
$usePageNavigation = true;
$navyParams = array();
if (isset($_REQUEST['mode']) && $_REQUEST['mode'] == 'excel') {
$usePageNavigation = false;
} else {
$navyParams = CDBResult::GetNavParams(CAdminResult::GetNavSize($sTableID));
if ($navyParams['SHOW_ALL']) {
$usePageNavigation = false;
} else {
$navyParams['PAGEN'] = (int) $navyParams['PAGEN'];
$navyParams['SIZEN'] = (int) $navyParams['SIZEN'];
}
}
if ($selectFields['PROPERTY_TYPE']) {
$selectFields['USER_TYPE'] = true;
}
$selectFields = array_keys($selectFields);
$getListParams = array('select' => $selectFields, 'filter' => $arFilter, 'order' => $propertyOrder);
if ($usePageNavigation) {
$getListParams['limit'] = $navyParams['SIZEN'];
$getListParams['offset'] = $navyParams['SIZEN'] * ($navyParams['PAGEN'] - 1);
示例3: NavStart
function NavStart($nPageSize=20, $bShowAll=true, $iNumPage=false)
{
$nSize = CAdminResult::GetNavSize($this->table_id, $nPageSize);
if(!is_array($nPageSize))
$nPageSize = array();
$nPageSize["nPageSize"] = $nSize;
if($_REQUEST["mode"] == "excel")
$nPageSize["NavShowAll"] = true;
$this->nInitialSize = $nPageSize["nPageSize"];
parent::NavStart($nPageSize, $bShowAll, $iNumPage);
}
示例4: array_fill_keys
$selectFieldsMap = array_fill_keys(array_keys($headerList), false);
$selectFieldsMap = array_merge($selectFieldsMap, $selectFields);
$userList = array();
$userIDs = array();
$nameFormat = CSite::GetNameFormat(true);
$rowList = array();
$couponTypeList = array();
if ($selectFieldsMap['TYPE']) {
$couponTypeList = Internals\DiscountCouponTable::getCouponTypes(true);
}
$usePageNavigation = true;
$navyParams = array();
if (isset($_REQUEST['mode']) && $_REQUEST['mode'] == 'excel') {
$usePageNavigation = false;
} else {
$navyParams = CDBResult::GetNavParams(CAdminResult::GetNavSize($adminListTableID, array('nPageSize' => 20, 'sNavID' => $adminList->GetListUrl(true))));
if ($navyParams['SHOW_ALL']) {
$usePageNavigation = false;
} else {
$navyParams['PAGEN'] = (int) $navyParams['PAGEN'];
$navyParams['SIZEN'] = (int) $navyParams['SIZEN'];
}
}
if ($selectFields['TYPE']) {
$selectFields['USE_COUNT'] = true;
}
$selectFields = array_keys($selectFields);
$getListParams = array('select' => $selectFields, 'filter' => $filter, 'order' => array($by => $order));
if ($usePageNavigation) {
$countQuery = new Main\Entity\Query(Internals\DiscountCouponTable::getEntity());
$countQuery->addSelect(new Main\Entity\ExpressionField('CNT', 'COUNT(1)'));
示例5: CSubscription
if (!$ob->Update($ID, $arFields)) {
$lAdmin->AddGroupError(GetMessage("subscr_save_error") . $ob->LAST_ERROR, $ID);
}
break;
case "confirm":
$ob = new CSubscription();
$arFields = array("CONFIRMED" => "Y");
if (!$ob->Update($ID, $arFields)) {
$lAdmin->AddGroupError(GetMessage("subscr_save_error") . $ob->LAST_ERROR, $ID);
}
break;
}
}
}
$cData = new CSubscription();
$rsData = $cData->GetList(array($by => $order), $arFilter, array("nPageSize" => CAdminResult::GetNavSize($sTableID)));
$rsData = new CAdminResult($rsData, $sTableID);
$rsData->NavStart();
$lAdmin->NavText($rsData->GetNavPrint(GetMessage("subscr_nav")));
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => "ID", "sort" => "id", "align" => "right", "default" => true), array("id" => "DATE_INSERT", "content" => GetMessage("POST_DATE_INSERT"), "sort" => "date_insert", "default" => true), array("id" => "EMAIL", "content" => GetMessage("subscr_addr"), "sort" => "email", "default" => true), array("id" => "USER_ID", "content" => GetMessage("subscr_user"), "sort" => "user", "default" => true), array("id" => "CONFIRMED", "content" => GetMessage("subscr_conf"), "sort" => "conf", "default" => true), array("id" => "ACTIVE", "content" => GetMessage("subscr_act"), "sort" => "act", "default" => true), array("id" => "FORMAT", "content" => GetMessage("subscr_fmt"), "sort" => "fmt", "default" => true), array("id" => "DATE_UPDATE", "content" => GetMessage("subscr_updated"), "sort" => "date_update", "default" => false), array("id" => "DATE_CONFIRM", "content" => GetMessage("subscr_conf_time"), "sort" => "date_confirm", "default" => false), array("id" => "CONFIRM_CODE", "content" => GetMessage("subscr_conf_code"), "sort" => "confirm_code", "default" => false)));
while ($arRes = $rsData->NavNext(true, "f_")) {
$row =& $lAdmin->AddRow($f_ID, $arRes);
if ($f_USER_ID > 0) {
$strUser = "[<a class='tablebodylink' href=\"/bitrix/admin/user_edit.php?ID=" . $f_USER_ID . "&lang=" . LANG . "\" title=\"" . GetMessage("subscr_user_edit_title") . "\">" . $f_USER_ID . "</a>] (" . $f_USER_LOGIN . ") " . $f_USER_NAME . " " . $f_USER_LAST_NAME;
} else {
$strUser = GetMessage("subscr_adm_anon");
}
$row->AddViewField("USER_ID", $strUser);
$row->AddCheckField("ACTIVE");
$row->AddInputField("EMAIL", array("size" => 20));
$row->AddViewField("EMAIL", '<a href="subscr_edit.php?ID=' . $f_ID . '&lang=' . LANG . '" title="' . GetMessage("subscr_upd") . '">' . $f_EMAIL . '</a>');
示例6: foreach
@unlink($_SERVER["DOCUMENT_ROOT"] . ($arSmile['TYPE'] == CSmile::TYPE_ICON ? CSmile::PATH_TO_ICON : CSmile::PATH_TO_SMILE) . $arSmile['SET_ID'] . '/' . $arSmile['IMAGE']);
}
}
}
}
}
if ($lAdmin->EditAction()) {
foreach ($FIELDS as $ID => $arFields) {
$ID = IntVal($ID);
if ($ID <= 0) {
continue;
}
CSmile::update($ID, array('LANG' => array(LANGUAGE_ID => $arFields['NAME']), 'SORT' => $arFields['SORT'], 'TYPING' => $arFields['TYPING']));
}
}
$dbResultList = CSmile::getList(array('SELECT' => array('ID', 'SET_ID', 'SET_NAME', 'TYPE', 'NAME', 'SORT', 'TYPING', 'IMAGE', 'IMAGE_WIDTH', 'IMAGE_HEIGHT'), 'FILTER' => $arFilter, 'ORDER' => array($by => $order), 'NAV_PARAMS' => array("nPageSize" => CAdminResult::GetNavSize($sTableID)), 'RETURN_RES' => 'Y'));
$dbResultList = new CAdminResult($dbResultList, $sTableID);
$dbResultList->NavStart();
$lAdmin->NavText($dbResultList->GetNavPrint(GetMessage("SMILE_NAV")));
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => GetMessage("SMILE_ID"), "sort" => "ID", "default" => true), array("id" => "SORT", "content" => GetMessage("SMILE_SORT"), "sort" => "SORT", "default" => true, "align" => "right"), array("id" => "NAME", "content" => GetMessage("SMILE_NAME"), "default" => true), array("id" => "TYPING", "content" => GetMessage("SMILE_TYPING"), "default" => true), array("id" => "ICON", "content" => GetMessage("SMILE_ICON"), "default" => true), array("id" => "SET_NAME", "content" => GetMessage("SMILE_SET_NAME"), "default" => true), array("id" => "TYPE", "content" => GetMessage('SMILE_TYPE'), "default" => true), array("id" => "IMAGE", "content" => GetMessage("SMILE_IMAGE_FILE"), "default" => false)));
$arVisibleColumns = $lAdmin->GetVisibleHeaderColumns();
while ($arForum = $dbResultList->NavNext(true, "f_")) {
$row =& $lAdmin->AddRow($f_ID, $arForum);
$row->AddField("ID", $f_ID);
$row->AddField("SORT", $f_SORT);
$row->AddField("TYPE", $f_TYPE == CSmile::TYPE_ICON ? GetMessage("SMILE_TYPE_ICON") : GetMessage("SMILE_TYPE_SMILE"));
$row->AddViewField("SET_NAME", '<a title="' . GetMessage("SMILE_EDIT_DESCR") . '" href="' . "smile_set_edit.php?ID=" . $f_SET_ID . "&lang=" . LANG . "&" . GetFilterParams("filter_") . '">' . (strlen($f_SET_NAME) > 0 ? $f_SET_NAME : GetMessage('SMILE_SET_NO_NAME', array('#ID#' => $f_SET_ID))) . '</a>');
$row->AddViewField("NAME", '<a title="' . GetMessage("SMILE_EDIT_DESCR") . '" href="' . "smile_edit.php?ID=" . $f_ID . "&lang=" . LANG . "&" . GetFilterParams("filter_") . '">' . (strlen($f_NAME) > 0 ? $f_NAME : GetMessage('SMILE_NO_NAME')) . '</a>');
$row->AddField("TYPING", $f_TYPING);
$row->AddField("ICON", "<img src=\"" . ($f_TYPE == CSmile::TYPE_ICON ? CSmile::PATH_TO_ICON : CSmile::PATH_TO_SMILE) . $f_SET_ID . "/" . $f_IMAGE . "\" border=\"0\" " . (IntVal($f_IMAGE_WIDTH) > 0 ? "width=\"" . $f_IMAGE_WIDTH . "\"" : "") . " " . (IntVal($f_IMAGE_HEIGHT) > 0 ? "height=\"" . $f_IMAGE_HEIGHT . "\"" : "") . ">");
$row->AddField("IMAGE", ($f_TYPE == CSmile::TYPE_ICON ? CSmile::PATH_TO_ICON : CSmile::PATH_TO_SMILE) . $f_SET_ID . "/" . $f_IMAGE);
示例7: IntVal
$arFilter["ORDER_ID"] = IntVal($filter_order_id);
}
if (strlen($filter_transact_date_to) > 0) {
if ($arDate = ParseDateTime($filter_transact_date_to, CSite::GetDateFormat("FULL", SITE_ID))) {
if (StrLen($filter_transact_date_to) < 11) {
$arDate["HH"] = 23;
$arDate["MI"] = 59;
$arDate["SS"] = 59;
}
$filter_transact_date_to = date($DB->DateFormatToPHP(CSite::GetDateFormat("FULL", SITE_ID)), mktime($arDate["HH"], $arDate["MI"], $arDate["SS"], $arDate["MM"], $arDate["DD"], $arDate["YYYY"]));
$arFilter["<=TRANSACT_DATE"] = $filter_transact_date_to;
} else {
$filter_transact_date_to = "";
}
}
$nPageSize = CAdminResult::GetNavSize($sTableID);
$dbTransactList = CSaleUserTransact::GetList(array($by => $order), $arFilter, false, array("nPageSize" => $nPageSize), array("*"));
$dbTransactList = new CAdminResult($dbTransactList, $sTableID);
$dbTransactList->NavStart();
$lAdmin->NavText($dbTransactList->GetNavPrint(GetMessage("STA_NAV")));
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => "ID", "sort" => "id", "default" => true), array("id" => "TRANSACT_DATE", "content" => GetMessage("STA_TRANS_DATE1"), "sort" => "transact_date", "default" => true), array("id" => "USER_ID", "content" => GetMessage('STA_USER1'), "sort" => "user_id", "default" => true), array("id" => "AMOUNT", "content" => GetMessage("STA_SUM"), "sort" => "amount", "default" => true), array("id" => "ORDER_ID", "content" => GetMessage("STA_ORDER"), "sort" => "order_id", "default" => true), array("id" => "TYPE", "content" => GetMessage("STA_TYPE"), "sort" => "description", "default" => true), array("id" => "DESCR", "content" => GetMessage("STA_DESCR"), "sort" => "", "default" => true)));
$arVisibleColumns = $lAdmin->GetVisibleHeaderColumns();
$LOCAL_TRANS_USER_CACHE = array();
if (in_array("DESCR", $arVisibleColumns)) {
$dbTransactList1 = CSaleUserTransact::GetList(array($by => $order), $arFilter, false, array("nPageSize" => $nPageSize), array("ID", "EMPLOYEE_ID"));
$arTrUsers = array();
while ($arTransact = $dbTransactList1->Fetch()) {
$tmpTrans[] = $arTransact;
if (IntVal($arTransact["EMPLOYEE_ID"]) > 0 && !in_array($arTransact["EMPLOYEE_ID"], $arTrUsers)) {
$arTrUsers[] = $arTransact["EMPLOYEE_ID"];
}
示例8: foreach
} else {
foreach ($arUniqueIndexes as $arIndexColumns) {
$arMissed = array_diff($arIndexColumns, $arSelectedFields);
if (count($arMissed) == 0) {
$bDelete = true;
$arPKColumns = $arIndexColumns;
break;
}
}
}
$bDelete = $bDelete && $RIGHT >= "W";
$obSchema = new CPerfomanceSchema();
$arChildren = $obSchema->GetChildren($table_name);
$arParents = $obSchema->GetParents($table_name);
CTimeZone::Disable();
$rsData = $obTable->GetList($arSelectedFields, $arFilter, array($by => $order), array("nPageSize" => CAdminResult::GetNavSize($sTableID)));
CTimeZone::Enable();
$rsData = new CAdminResult($rsData, $sTableID);
$rsData->NavStart();
$lAdmin->NavText($rsData->GetNavPrint(GetMessage("PERFMON_TABLE_PAGE")));
$max_display_url = COption::GetOptionInt("perfmon", "max_display_url");
while ($arRes = $rsData->Fetch()) {
$row =& $lAdmin->AddRow($arRes["ID"], $arRes);
$arRowPK = array();
foreach ($arFields as $FIELD_NAME => $FIELD_TYPE) {
if (strlen($arRes[$FIELD_NAME]) > 0) {
if ($FIELD_TYPE == "int") {
if ($_REQUEST["mode"] == "excel") {
$val = number_format($arRes[$FIELD_NAME], 0, "", "");
} else {
$val = str_replace(" ", " ", number_format($arRes[$FIELD_NAME], 0, "", " "));
示例9: GetNavSize
/**
* @param bool|string $table_id
* @param int|array $nPageSize
* @param string $list_url
* @return int
*/
function GetNavSize($table_id = false, $nPageSize = 20, $list_url = '')
{
$list_url = (string) $list_url;
if ($list_url != '') {
if (!is_array($nPageSize)) {
$nPageSize = array('nPageSize' => $nPageSize);
}
$nPageSize['sNavID'] = $list_url;
}
return parent::GetNavSize($table_id, $nPageSize);
}
示例10: array
if ($ar = $res->Fetch()) {
$DB->StartTransaction();
if (!CTestAttempt::Delete($ID)) {
$DB->Rollback();
$lAdmin->AddGroupError(GetMessage("LEARNING_DELETE_ERROR"), $ID);
} else {
CGradeBook::RecountAttempts($ar["STUDENT_ID"], $ar["TEST_ID"]);
}
$DB->Commit();
}
break;
}
}
}
// fetch data
$rsData = CTestAttempt::GetList(array($by => $order), $arFilter, array(), array('nPageSize' => CAdminResult::GetNavSize($sTableID)));
$rsData = new CAdminResult($rsData, $sTableID);
// navigation string setup
$lAdmin->NavText($rsData->GetNavPrint(GetMessage("LEARNING_ADMIN_RESULTS")));
// list header
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => "ID", "sort" => "id", "default" => true), array("id" => "USER_NAME", "content" => GetMessage('LEARNING_ADMIN_STUDENT'), "sort" => "student_id", "default" => true), array("id" => "TEST_NAME", "content" => GetMessage('LEARNING_ADMIN_TEST'), "sort" => "test_name", "default" => true), array("id" => "DATE_START", "content" => GetMessage('LEARNING_ADMIN_DATE_START'), "sort" => "date_start", "default" => true), array("id" => "DATE_END", "content" => GetMessage('LEARNING_ADMIN_DATE_END'), "sort" => "date_end", "default" => true), array("id" => "STATUS", "content" => GetMessage('LEARNING_ADMIN_STATUS'), "sort" => "status", "default" => true), array("id" => "QUESTIONS", "content" => Getmessage('LEARNING_ADMIN_QUESTIONS'), "sort" => "questions", "default" => true, "align" => "center"), array("id" => "COMPLETED", "content" => Getmessage('LEARNING_ADMIN_COMPLETED'), "sort" => "completed", "default" => true), array("id" => "SCORE", "content" => GetMessage('LEARNING_ADMIN_SCORE'), "sort" => "score", "default" => true), array("id" => "MAX_SCORE", "content" => GetMessage('LEARNING_ADMIN_MAX_SCORE'), "sort" => "max_score", "default" => true)));
// building list
while ($arRes = $rsData->NavNext(true, "f_")) {
$row =& $lAdmin->AddRow($f_ID, $arRes);
$row->AddCalendarField("DATE_START");
$row->AddCalendarField("DATE_END");
$row->AddSelectField("STATUS", $arStatus);
$row->AddCheckField("COMPLETED");
$row->AddInputField("SCORE", array("size" => "3"));
$row->AddInputField("MAX_SCORE", array("size" => "3"));
$row->AddViewField("ID", '<a href="learn_test_result_admin.php?lang=' . LANG . '&ATTEMPT_ID=' . $f_ID . '">' . $f_ID . '</a>');
示例11: IntVal
}
$ID = IntVal($ID);
switch ($_REQUEST['action']) {
case "delete":
@set_time_limit(0);
$DB->StartTransaction();
if (!CControllerLog::Delete($ID)) {
$DB->Rollback();
$lAdmin->AddGroupError(GetMessage("CTRL_LOG_ADMIN_ERR_DELETE"), $ID);
}
$DB->Commit();
break;
}
}
}
$rsData = CControllerLog::GetList(array($by => $order), $arFilter, array("nPageSize" => CAdminResult::GetNavSize($sTableID)));
$rsData = new CAdminResult($rsData, $sTableID);
$rsData->NavStart();
$lAdmin->NavText($rsData->GetNavPrint(GetMessage("CTRL_LOG_ADMIN_PAGETITLE")));
$arHeaders = array();
$arHeaders[] = array("id" => "TIMESTAMP_X", "content" => GetMessage("CTRL_LOG_ADMIN_COLUMN_CREATED"), "default" => true, "sort" => "timestamp_x");
$arHeaders[] = array("id" => "NAME", "content" => GetMessage("CTRL_LOG_ADMIN_COLUMN_NAME"), "default" => true, "sort" => "name");
$arHeaders[] = array("id" => "CONTROLLER_MEMBER_NAME", "content" => GetMessage("CTRL_LOG_ADMIN_FILTER_CLIENT"), "default" => true, "sort" => "controller_member_name");
$arHeaders[] = array("id" => "STATUS", "content" => GetMessage("CTRL_LOG_ADMIN_FILTER_STATUS"), "default" => true, "sort" => "status");
$arHeaders[] = array("id" => "TASK_NAME", "content" => GetMessage("CTRL_LOG_ADMIN_FILTER_TASK"), "default" => true, "sort" => "task_name");
$arHeaders[] = array("id" => "USER", "content" => GetMessage("CTRL_LOG_ADMIN_COLUMN_USER"), "default" => true);
$arHeaders[] = array("id" => "DESCRIPTION", "content" => GetMessage("CTRL_LOG_ADMIN_FILTER_DESC"));
$arHeaders[] = array("id" => "ID", "content" => "ID", "default" => true, "sort" => "id");
$lAdmin->AddHeaders($arHeaders);
while ($arRes = $rsData->NavNext(true, "f_")) {
$row =& $lAdmin->AddRow($f_ID, $arRes);
示例12: foreach
}
if ($lAdmin->EditAction()) {
foreach ($FIELDS as $ID => $arFields) {
$ID = IntVal($ID);
if ($ID <= 0) {
continue;
}
CSmileSet::update($ID, array('LANG' => array(LANGUAGE_ID => $arFields['NAME']), 'STRING_ID' => $arFields['STRING_ID'], 'SORT' => $arFields['SORT']));
}
}
if (isset($_REQUEST['GALLERY_ID'])) {
$arFilter['PARENT_ID'] = intval($_REQUEST['GALLERY_ID']);
} else {
LocalRedirect("smile_gallery.php?lang=" . LANG);
}
$dbResultList = CSmileSet::getList(array('SELECT' => array('ID', 'STRING_ID', 'NAME', 'SORT', 'SMILE_COUNT'), 'FILTER' => $arFilter, 'ORDER' => array($by => $order), 'NAV_PARAMS' => array("nPageSize" => CAdminResult::GetNavSize($sTableID)), 'RETURN_RES' => 'Y'));
$dbResultList = new CAdminResult($dbResultList, $sTableID);
$dbResultList->NavStart();
$lAdmin->NavText($dbResultList->GetNavPrint(GetMessage("SMILE_NAV")));
$lAdmin->AddHeaders(array(array("id" => "ID", "content" => GetMessage("SMILE_ID"), "sort" => "ID", "default" => false), array("id" => "NAME", "content" => GetMessage("SMILE_NAME"), "default" => true), array("id" => "STRING_ID", "content" => GetMessage("SMILE_STRING_ID"), "default" => false), array("id" => "SORT", "content" => GetMessage("SMILE_SORT"), "sort" => "SORT", "default" => true, "align" => "right"), array("id" => "SMILE_COUNT", "content" => GetMessage("SMILE_SMILE_COUNT"), "sort" => "SMILE_COUNT", "default" => true)));
$arVisibleColumns = $lAdmin->GetVisibleHeaderColumns();
while ($arForum = $dbResultList->NavNext(true, "f_")) {
$row =& $lAdmin->AddRow($f_ID, $arForum);
$row->AddField("ID", $f_ID);
$row->AddField("SORT", $f_SORT);
$row->AddViewField("NAME", '<a title="' . GetMessage("SMILE_EDIT_DESCR") . '" href="' . "smile.php?SET_ID=" . $f_ID . "&lang=" . LANG . "&" . GetFilterParams("filter_") . '">' . (strlen($f_NAME) > 0 ? $f_NAME : GetMessage('SMILE_SET_NAME', array('#ID#' => $f_ID))) . '</a>');
$row->AddViewField("SMILE_COUNT", $f_SMILE_COUNT);
$row->AddInputField("NAME", array("size" => 20));
$row->AddInputField("STRING_ID", array("size" => 20));
$row->AddInputField("SORT", array("size" => 5));
if (in_array($f_STRING_ID, array('bitrix_main'))) {
示例13: array
if ($result->isSuccess()) {
Application::getConnection()->commitTransaction();
} else {
$lAdmin->AddGroupError(implode('\\n', $result->getErrorMessages()));
}
}
break;
}
}
}
$headers = array(array("id" => "DATE_PAID", "content" => GetMessage("SALE_ORDER_DATE_PAID"), "sort" => "DATE_PAID", "default" => true), array("id" => "ID", "content" => "ID", "sort" => "ID", "default" => true), array("id" => "ORDER_ID", "content" => GetMessage("SALE_ORDER_ID"), "sort" => "ORDER_ID", "default" => true), array("id" => "ACCOUNT_NUMBER", "content" => GetMessage("SALE_ACCOUNT_NUMBER"), "sort" => "ORDER.ACCOUNT_NUMBER", "default" => false), array("id" => "ORDER_USER_NAME", "content" => GetMessage("SALE_ORDER_USER_NAME"), "sort" => "ORDER_USER_NAME", "default" => true), array("id" => "PAID", "content" => GetMessage("SALE_ORDER_PAID"), "sort" => "PAID", "default" => true), array("id" => "PAY_SYSTEM_NAME", "content" => GetMessage("SALE_ORDER_PAY_SYSTEM_NAME"), "sort" => "PAY_SYSTEM_NAME", "default" => true), array("id" => "SUM", "content" => GetMessage("SALE_ORDER_SUM"), "sort" => "SUM", "default" => true), array("id" => "COMPANY_BY", "content" => GetMessage("SALE_ORDER_COMPANY_BY"), "sort" => "COMPANY_BY.NAME", "default" => true), array("id" => "PAY_VOUCHER_NUM", "content" => GetMessage("SALE_ORDER_PAY_VOUCHER_NUM"), "sort" => "PAY_VOUCHER_NUM", "default" => true), array("id" => "RESPONSIBLE_BY", "content" => GetMessage("SALE_ORDER_RESPONSIBLE_BY"), "sort" => "", "default" => true), array("id" => "PS_STATUS", "content" => GetMessage("SALE_ORDER_PS_STATUS"), "sort" => "PS_STATUS", "default" => false), array("id" => "PS_STATUS_CODE", "content" => GetMessage("SALE_ORDER_PS_STATUS_CODE"), "sort" => "PS_STATUS_CODE", "default" => false), array("id" => "PS_STATUS_DESCRIPTION", "content" => GetMessage("SALE_ORDER_PS_STATUS_DESCRIPTION"), "sort" => "PS_STATUS_DESCRIPTION", "default" => false), array("id" => "PS_STATUS_MESSAGE", "content" => GetMessage("SALE_ORDER_PS_STATUS_MESSAGE"), "sort" => "PS_STATUS_MESSAGE", "default" => false), array("id" => "PS_SUM", "content" => GetMessage("SALE_ORDER_PS_SUM"), "sort" => "PS_SUM", "default" => false), array("id" => "PS_CURRENCY", "content" => GetMessage("SALE_ORDER_PS_CURRENCY"), "sort" => "PS_CURRENCY", "default" => false), array("id" => "PS_RESPONSE_DATE", "content" => GetMessage("SALE_ORDER_PS_RESPONSE_DATE"), "sort" => "PS_RESPONSE_DATE", "default" => false), array("id" => "PAY_VOUCHER_DATE", "content" => GetMessage("SALE_ORDER_PAY_VOUCHER_DATE"), "sort" => "PAY_VOUCHER_DATE", "default" => false), array("id" => "DATE_PAY_BEFORE", "content" => GetMessage("SALE_ORDER_DATE_PAY_BEFORE"), "sort" => "DATE_PAY_BEFORE", "default" => false), array("id" => "DATE_BILL", "content" => GetMessage("SALE_ORDER_DATE_BILL"), "sort" => "DATE_BILL", "default" => false), array("id" => "PAY_SYSTEM_NAME", "content" => GetMessage("SALE_ORDER_PAY_SYSTEM_NAME"), "sort" => "PAY_SYSTEM_NAME", "default" => false));
$select = array('*', 'COMPANY_BY_NAME' => 'COMPANY_BY.NAME', 'RESPONSIBLE_BY_NAME' => 'RESPONSIBLE_BY.NAME', 'RESPONSIBLE_BY_LAST_NAME' => 'RESPONSIBLE_BY.LAST_NAME', 'ORDER_ACCOUNT_NUMBER' => 'ORDER.ACCOUNT_NUMBER', 'ORDER_USER_NAME' => 'ORDER.USER.NAME', 'ORDER_USER_LAST_NAME' => 'ORDER.USER.LAST_NAME', 'ORDER_USER_ID' => 'ORDER.USER_ID');
$params = array('select' => $select, 'filter' => $arFilter, 'order' => array($by => $order));
$usePageNavigation = true;
$navyParams = array();
$navyParams = CDBResult::GetNavParams(CAdminResult::GetNavSize($tableId));
if ($navyParams['SHOW_ALL']) {
$usePageNavigation = false;
} else {
$navyParams['PAGEN'] = (int) $navyParams['PAGEN'];
$navyParams['SIZEN'] = (int) $navyParams['SIZEN'];
}
if ($usePageNavigation) {
$params['limit'] = $navyParams['SIZEN'];
$params['offset'] = $navyParams['SIZEN'] * ($navyParams['PAGEN'] - 1);
}
$totalPages = 0;
if ($usePageNavigation) {
$countQuery = new \Bitrix\Main\Entity\Query(PaymentTable::getEntity());
$countQuery->addSelect(new \Bitrix\Main\Entity\ExpressionField('CNT', 'COUNT(1)'));
$countQuery->setFilter($params['filter']);
示例14: array
if(in_array("PREVIEW_TEXT", $arSelectedFields))
$arSelectedFields[] = "PREVIEW_TEXT_TYPE";
if(in_array("DETAIL_TEXT", $arSelectedFields))
$arSelectedFields[] = "DETAIL_TEXT_TYPE";
$arSelectedFields[] = "LOCK_STATUS";
$arSelectedFields[] = "WF_NEW";
$arSelectedFields[] = "WF_STATUS_ID";
$arSelectedFields[] = "DETAIL_PAGE_URL";
$arSelectedFields[] = "SITE_ID";
$arSelectedFields[] = "CODE";
$arSelectedFields[] = "EXTERNAL_ID";
$arSelectedFields[] = "NAME";
$arSelectedFields[] = "XML_ID";
$rsData = CIBlockElement::GetList($arOrder, $arFilter, false, array("nPageSize"=>CAdminResult::GetNavSize($sTableID)), $arSelectedFields);
$rsData = new CAdminResult($rsData, $sTableID);
$rsData->NavStart();
$lAdmin->NavText($rsData->GetNavPrint($arIBlock["ELEMENTS_NAME"]));
function GetElementName($ID)
{
$ID = IntVal($ID);
static $cache = array();
if(!array_key_exists($ID, $cache) && $ID > 0)
{
$rsElement = CIBlockElement::GetList(array(), array("ID"=>$ID, "SHOW_HISTORY"=>"Y"), false, false, array("ID","IBLOCK_ID","NAME"));
$cache[$ID] = $rsElement->GetNext();
}
return $cache[$ID];
}
示例15: getDataSource
function getDataSource($arOrder, $arFilter, $arSelect)
{
return CPerfomanceHit::GetList($arOrder, $arFilter, false, array("nPageSize" => CAdminResult::GetNavSize($this->sTableID)), $arSelect);
}