Oct 29 2020 05:01 AM
I know that you can filter news items you want to display in a web part, but is there a way to set a filter so that it doesn't display a news item?
I am creating two news Web parts on the same comms site. I want one to focus on a very specific topic - every title will contain the same words so it's easy to filter the news using those words. However, I want the second web part to display all other news minus the topic I just described. I realise I could re-order the news, but it would be much simpler just to set a rule.
I hope that makes sense.
Oct 29 2020 08:06 AM - edited Oct 29 2020 08:09 AM
Hi @AmyNAT there may be other ways to do this but what we do is to make use of the term store and a managed metadata column in our Site Pages library.
On our intranet we have a news web part for general news which displays those news items where the Page tag metadata column has been set to doesn't' contain Senior Leadership Team.
On the same page we have another news website which just shows the most recent news item where the page tag metadata column contains Senior Leadership Team.
Note that it must be contains/doesn't contain, it won't work with is equal to etc.
You need to set up the term you are filtering by in Site Settings - Term Store Management:
You create your term set (Page Tags) and the terms (in this case just Senior Leadership Team):
Next add a column in your Site Pages library which is a managed metadata column:
Then when you are creating your news item the Page Details panel will show the PageTags column - we also use it to select other properties like the region of the country, the specialism, offices involved etc. Either leave it blank so that it is not a Senior Leadership Team news item and will therefore go into the general news, or start typing Senior and it will pick up the correct term from the term store. Click out of the field to save the selection.
Next we add the web part. Filter by Managed property
Start typing in the Term Set you want which in this case is Page Tags. I just typed Page and it found it. Don't worry that it prefixes it with owstaxID, that must be something to do with internal SharePoint naming and it's fine.
Select Doesn't contain and add the search value which in this case will be Senior Leadership Team as shown in the first image.
I think the most difficult part of this is getting used to the Term Store. But you can read more about all this at https://sharepointmaven.com/?s=term+store&post_type=post
The result works consistently and very well and we use it every day with our news stories. Come back if you have any follow-on questions.
Rob
Los Gallardos
Microsoft Power Automate Community Super User
Oct 29 2020 10:13 AM
Jan 14 2021 01:28 PM
Hello @RobElliott ,
If I want to move particular news from one news web part(named, Recent News)to another news web part (named, Old news) after 7/10 days automatically, can I do that? If yes, please mention the steps to do so.