Skip to content

Commit

Permalink
fixed: list menu item with prefilter applied: if list used related da…
Browse files Browse the repository at this point in the history
…ta, the "prefilter applied on an unpublished element" message should be repressed
  • Loading branch information
pollen8 committed Feb 17, 2014
1 parent 18cd162 commit 70bb3cd
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion components/com_fabrik/models/list.php
Original file line number Diff line number Diff line change
Expand Up @@ -1813,6 +1813,8 @@ public function getRecordCounts(&$element, $pks = array())
// Ensure that the faceted list's "require filters" option is set to false
$fparams->set('require-filter', false);

$fparams->set('ignore_prefilter_msg', true);

// Ignore faceted lists session filters
$origIncSesssionFilters = $input->get('fabrik_incsessionfilters', true);
$input->set('fabrik_incsessionfilters', false);
Expand Down Expand Up @@ -5361,7 +5363,10 @@ public function getPrefilterArray(&$filters)
$elementModel = JArrayHelper::getValue($elements, FabrikString::safeColName($tmpfilter), false);
}

if ($elementModel === false && $condition !== 'exists')
// List related data links - if prefilter set on main list menu item, we wont find the element in the related list, so don't raise error
$ignore = $params->get('ignore_prefilter_msg', false);

if ($elementModel === false && $condition !== 'exists' && $ignore === false)
{
// Include the JLog class.
jimport('joomla.log.log');
Expand Down

0 comments on commit 70bb3cd

Please sign in to comment.