Pages filter
I need to add a filter to the pages sidebar that checks to see if the "Title" is missing some text
What's the filter expressionto use? Anything I try seems to return no results?
So like !Title.Contains("text") does nothing...
Hello Steve,
Can you provide more details how this filter is added to the sidebar and where you are trying to put the filter expression?
I'm looking forward to your answer.
Regards,
Yavor Slavchev
Telerik
Same place in the backend where all the other filters are, just trying to add a new one
ContentViewConfig.contentViewControls.FrontendPages.views.FrontendPagesListView.config
<?
xml
version
=
"1.0"
encoding
=
"utf-8"
?>
<
view
xmlns:config
=
"urn:telerik:sitefinity:configuration"
xmlns:type
=
"urn:telerik:sitefinity:configuration:type"
config:version
=
"6.2.4910.0"
viewName
=
"FrontendPagesListView"
>
<
sidebar
>
<
sections
>
<
section
name
=
"Filter"
>
<
items
>
<
item
commandName
=
"filter"
commandArgument
=
"filterExpression : "!Name.Contains(\"Home\")""
commandButtonType
=
"SimpleLinkButton"
isFilter
=
"False"
text
=
"Missing Site Name"
wrapperTagKey
=
"Unknown"
widgetType
=
"Telerik.Sitefinity.Web.UI.Backend.Elements.Widgets.CommandWidget, Telerik.Sitefinity"
isSeparator
=
"False"
name
=
"MissingSiteName"
type:this
=
"Telerik.Sitefinity.Web.UI.Backend.Elements.Config.CommandWidgetElement, Telerik.Sitefinity"
/>
</
items
>
</
section
>
</
sections
>
</
sidebar
>
</
view
>
Hello Steve,
Thank you for your quick response.
In the provided configuration you are trying to filter pages by Name, not by Title. I tried the same here and filtering by title with "!Title.Contains" is working properly. Filtering by Name does not, because Name is empty for all pages.
I hope this will solve the problem.
Regards,
Yavor Slavchev
Telerik
Sorry I should have mentioned that I had tried title already and "Name" was just me testing another property to see what happened
I changed it back to title, and it still doesn't do anything
This should return me one result:
filterExpression :
"Title.Contains(\"Home\")"
Hi Steve,
Thank you for your clarification.
Here is a short video of how I setup and use sidebar filter. Take a look at it and tell me what is different from your configuration.
I hope this video will help solve the problem.
Regards,
Yavor Slavchev
Telerik
You tell me :)
...seems identical
screencast.com/.../qqyN5JiIY1MX
Hello Steve,
Thank you for contacting us again.
Did you try to restart the application after you apply filter changes? After I created it, i have restarted the site to apply the filter. Try it at your side.
I hope this helps.
Regards,
Yavor Slavchev
Telerik
Yes, even if I didn't the app pool would have shut down a million times in the course of a week with updates
Hi Steve,
Another difference that I have noticed is the way the filter is set in the configuration file: Mine is:
commandArgument="filterExpression : "!Title.Contains(\"Test\")""