Esempio n. 1
0
 /**
  * Here we obtain data that is dependent to data in the cache 
  * @return void
  */
 protected function obtainCacheDependentData()
 {
     $listParams = Helper::getParametersForList($this->getListParameters());
     $dbRecordsList = Helper::getList($listParams, false, 20);
     // there is no pagenav api in d7, so use wrapper of the old api
     $dbRecordsList->bShowAll = false;
     $this->dbResult['LOCS'] = array();
     while ($arLoc = $dbRecordsList->Fetch()) {
         $arLoc['PATH_TO_LOCATIONS_EDIT'] = CComponentEngine::MakePathFromTemplate($this->arParams['PATH_TO_LOCATIONS_EDIT'], array('loc_id' => $arLoc['ID']));
         $arLoc['PATH_TO_LOCATIONS_DELETE'] = CHTTP::urlAddParams(CComponentEngine::MakePathFromTemplate($this->arParams['PATH_TO_LOCATIONS_LIST'], array('loc_id' => $arLoc['ID'])), array('action_' . $this->dbResult['GRID_ID'] => 'delete', 'ID' => $arLoc['ID'], 'sessid' => bitrix_sessid()));
         $arLoc['TYPE_ID'] = $this->dbResult['TYPES'][$arLoc['TYPE_ID']];
         $this->dbResult['LOCS'][$arLoc['ID']] = $arLoc;
     }
     $navComponentObject = 1;
     // formal
     $this->dbResult['ROWS_COUNT'] = $dbRecordsList->NavRecordCount;
     $this->dbResult['NAV_STRING'] = $dbRecordsList->GetPageNavStringEx($navComponentObject, Loc::getMessage("CRM_CLL2_INTS_TASKS_NAV"), "", false);
     $this->dbResult['NAV_RESULT'] = $dbRecordsList;
 }