Beispiel #1
0
 private function _searchCharRace($cndBase)
 {
     $result = [];
     $cnd = array_merge($cndBase, [$this->createLookup()]);
     $races = new CharRaceList($cnd);
     if ($data = $races->getListviewData()) {
         if ($this->searchMask & SEARCH_TYPE_OPEN) {
             foreach ($races->iterate() as $__) {
                 $data[$races->id]['param1'] = '"race_' . strToLower($races->getField('fileString')) . '_male"';
             }
         }
         $result = array('type' => TYPE_RACE, 'appendix' => ' (Race)', 'matches' => $races->getMatches(), 'file' => CharRaceList::$brickFile, 'data' => $data, 'params' => []);
         if ($races->getMatches() > $this->maxResults) {
             // $result['params']['note'] = sprintf(Util::$tryNarrowingString, 'LANG.lvnote_', $races->getMatches(), $this->maxResults);
             $result['params']['_truncated'] = 1;
         }
     }
     return $result;
 }
Beispiel #2
0
 private function _searchCharRace($cndBase)
 {
     $cnd = array_merge($cndBase, [$this->createLookup()]);
     $races = new CharRaceList($cnd);
     if ($data = $races->getListviewData()) {
         $result['data'] = array_values($data);
         $osInfo = [TYPE_RACE, ' (Race)', $races->getMatches(), []];
         if ($this->searchMask & SEARCH_TYPE_OPEN) {
             foreach ($races->iterate() as $id => $__) {
                 $osInfo[3][$id] = 'race_' . strToLower($races->getField('fileString')) . '_male';
             }
         }
         if ($races->getMatches() > $this->maxResults) {
             // $result['note'] = sprintf(Util::$tryNarrowingString, 'LANG.lvnote_', $races->getMatches(), $this->maxResults);
             $result['_truncated'] = 1;
         }
         return ['race', $result, null, $osInfo];
     }
     return false;
 }