Skip to content

Commit

Permalink
Merge branch 'master' of github.com:AgelxNash/DocLister
Browse files Browse the repository at this point in the history
  • Loading branch information
AgelxNash committed Nov 7, 2018
2 parents 5fb5347 + 3606d7a commit dddb87a
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
3 changes: 3 additions & 0 deletions assets/lib/MODxAPI/modResource.php
Expand Up @@ -633,6 +633,9 @@ public function save($fire_events = false, $clearCache = false)
'docObj' => $this
), $fire_events);


$this->modx->getAliasListing($this->id);

if ($clearCache) {
$this->clearCache($fire_events);
}
Expand Down
14 changes: 14 additions & 0 deletions assets/snippets/DocLister/core/filterDocLister.abstract.php
Expand Up @@ -207,6 +207,20 @@ protected function build_sql_where($table_alias, $field, $operator, $value)
$output = '';
}
break;
case 'containsAll':
$words = explode($this->DocLister->getCFGDef('filter_delimiter', ','), $value);
$word_arr = array();
foreach ($words as $word) {
if (($likeWord = $this->DocLister->LikeEscape($output, $word)) !== '') {
$word_arr[] = $likeWord;
}
}
if (!empty($word_arr)) {
$output = '(' . implode(' AND ', $word_arr) . ')';
} else {
$output = '';
}
break;
case 'in':
$output .= ' IN(' . $this->DocLister->sanitarIn($value, ',', true) . ')';
break;
Expand Down

0 comments on commit dddb87a

Please sign in to comment.