TypeScript array object Filter – dynamic filter conditions, Search Refiners Sharepoint

I am working on the below scenario in Typescript and SharePoint Search.

I have Collection of Array something like this:

let _SelectedBusinessUnits =[
{ "fileName": "XYX.doc", "Region": "APAC", "Country":"Australia;China", "LOB": "Auto;Business Auto", SubLOB" : "Standard Auto" },
{ "fileName": "XYX2.doc", "Region": "UKIG", "Country":"UK;Germany", "LOB": "Wordings;Business Wordings", SubLOB" : "Super Wordings;YYY" },
{ "fileName": "XYX3.doc", "Region": "LTAM", "Country":"Japan", "LOB": "Endorsments;Business Endorsments", SubLOB" : "Super Endorsement" },
{ "fileName": "XYX4.doc", "Region": "APAC", "Country":"Australia:China", "LOB": "Auto;Business Auto", SubLOB" : "Standard Auto;XYHC" },
{ "fileName": "XY.doc", "Region": "UKIG", "Country":"UK, Germany", "LOB": "Wordings;Business Wordings", SubLOB" : "Super Wordings" },
{ "fileName": "XYX.pdf", "Region": "LTAM", "Country":"Japan", "LOB": "Endorsments;Business Endorsments", SubLOB" : "Super Endorsement" },
{ "fileName": "XYX.docx", "Region": "APAC", "Country":"Australia;China", "LOB": "Auto;Business Auto", SubLOB" : "Standard Auto" },
{ "fileName": "XYX.html", "Region": "UKIG", "Country":"UK;Germany", "LOB": "Wordings;Business Wordings", SubLOB" : "Super Wordings" },
{ "fileName": "X.pdf", "Region": "LTAM", "Country":"Japan", "LOB": "Endorsments;Business Endorsments", SubLOB" : "Super Endorsement" },]

I have filter conditions in another array of objects.

let filercondition =[{
{"Region": "UKIG"},
{"Region": "APAC"}


Now, I have scenario to filter the items based on the value I have in filter condition. [i.e I will select Region, Sublob or Lob etc.. I have respective multiselect dropdowns like Regions, country and lob and sublobs]

Based on the selection I do in the multiselect dropdowns I need to fetch. It is like refiner filters in search.

82 thoughts on “TypeScript array object Filter – dynamic filter conditions, Search Refiners Sharepoint”

  1. 574338 246252I simply need to tell you that you have written an exceptional and special article that I actually enjoyed reading. Im fascinated by how effectively you laid out your material and presented your views. Thank you. 889772

  2. Hmm is anyone else encountering problems with the images on this blog loading?
    I’m trying to figure out if its a problem on my end or if it’s the blog.

    Any feedback would be greatly appreciated.

  3. Hey there just wanted to give you a quick heads up.

    The words in your article seem to be running off the screen in Firefox.
    I’m not sure if this is a format issue or something to do with web browser compatibility but
    I thought I’d post to let you know. The design and style look great though!

    Hope you get the problem resolved soon. Cheers

  4. I’d like to thank you for the efforts you have put in writing this site.
    I really hope to see the same high-grade blog posts from you later on as well.
    In fact, your creative writing abilities has inspired me to
    get my own site now 😉

  5. I like what you guys are usually up too. This sort of clever work and exposure!

    Keep up the awesome works guys I’ve added you guys to blogroll.

  6. whoah this blog is magnificent i love reading your
    articles. Stay up the good work! You already
    know, lots of people are looking round for this info, you could help them greatly.

  7. I am really impressed with your writing
    skills as well as with the layout on your blog. Is this a paid theme or
    did you modify it yourself? Either way keep up the excellent quality writing,
    it’s rare to see a great blog like this one today.

  8. Does your website have a contact page? I’m having trouble
    locating it but, I’d like to send you an email. I’ve
    got some recommendations for your blog you might be interested in hearing.
    Either way, great site and I look forward to seeing it grow over time.

  9. I’m not sure exactly why but this site is loading extremely slow for me.
    Is anyone else having this problem or is it a issue on my end?

    I’ll check back later and see if the problem still exists.

  10. I’m really inspired along with your writing talents and also with the structure to
    your weblog. Is this a paid topic or did you customize it
    yourself? Anyway keep up the excellent quality writing, it is uncommon to peer a nice blog like this one

  11. Thanks for any other informative website.
    Where else could I am getting that type of info written in such
    an ideal manner? I’ve a challenge that I am simply now running on, and I’ve
    been on the glance out for such information.

  12. I was recommended this website by my cousin. I’m not sure whether this post is written by him as nobody else know such detailed about my trouble.

    You are wonderful! Thanks!

  13. Greate pieces. Keep posting such kind of information on your site.
    Im really impressed by your blog.
    Hi there, You have done an excellent job. I will certainly digg
    it and in my view suggest to my friends. I am confident they
    will be benefited from this website.

  14. I do not know whether it’s just me or if everybody else encountering problems
    with your blog. It appears as though some of the text within your posts are
    running off the screen. Can somebody else please comment and let me know if this is happening to them as well?
    This may be a problem with my internet browser because I’ve had this happen before.

  15. Spot on with this write-up, I honestly believe that this site needs a lot more attention. I’ll probably be returning to read through more,
    thanks for the info!

  16. Hello this is kinda of off topic but I was wondering
    if blogs use WYSIWYG editors or if you have to manually code with HTML.

    I’m starting a blog soon but have no coding experience so I wanted to get advice
    from someone with experience. Any help would be greatly appreciated!

  17. Hey There. I found your blog using msn. This is a really well written article.
    I will make sure to bookmark it and come back to read more of
    your useful information. Thanks for the post.
    I’ll definitely comeback.

  18. I’m not certain the place you are getting your information, but
    great topic. I needs to spend a while finding out much more or understanding
    more. Thank you for excellent info I used to be looking for this information for
    my mission.

  19. I absolutely love your blog.. Very nice colors &
    theme. Did you build this web site yourself? Please reply back
    as I’m attempting to create my own personal blog and would like to find out where you got this from or what the theme is named.

  20. I’m not sure why but this website is loading very
    slow for me. Is anyone else having this issue or is it a problem on my
    end? I’ll check back later and see if the problem still

  21. An impressive share! I’ve just forwarded this onto a co-worker who has
    been doing a little homework on this. And he actually bought
    me breakfast simply because I stumbled upon it for him…
    lol. So let me reword this…. Thank YOU for the meal!! But
    yeah, thanx for spending some time to discuss this issue here on your site.

  22. Hey I know this is off topic but I was wondering if you
    knew of any widgets I could add to my blog that automatically tweet my newest twitter updates.
    I’ve been looking for a plug-in like this for quite some time and was hoping
    maybe you would have some experience with something like this.

    Please let me know if you run into anything.
    I truly enjoy reading your blog and I look forward to your new

  23. I just like the valuable information you provide
    on your articles. I will bookmark your weblog and test once more here frequently.
    I’m relatively certain I will learn lots of new stuff proper right here!
    Good luck for the next!

  24. Superb site you have here but I was curious if
    you knew of any discussion boards that cover the same topics discussed in this article?
    I’d really love to be a part of community where I can get
    responses from other knowledgeable people that share the same interest.
    If you have any recommendations, please let me know.
    Bless you!

  25. I must thank you for the efforts you have put in penning this blog.
    I am hoping to check out the same high-grade blog posts
    by you later on as well. In truth, your creative writing abilities has inspired me to get my own site now ;

  26. Wonderful goods from you, man. I have rememberr yoyr
    stuff previous to and you’re just too fantastic.

    I acyually like what you have bougtht here, really like what you are stating and the way in which you assert it.
    You’re making it entertaining and you still take care of to keep it smart.
    I can’t wait to learn far moree from you. That is relly a wonderful web site.

    My blog post best possible Chaturbate

  27. Thanks for your personal marvelous posting! I certainly
    enjoyed reading it, you may be a great author. I will remember to bookmark your blog and will eventually come back in the foreseeable future.
    I want to encourage yourself to continue your great work,
    have a nice weekend!

    My blog post – spam

  28. I enjoy what yyou guys are up too. This type of clever work and coverage!
    Keep up the wonderful works guys I’ve included you guys to my blogroll.

    Review my web blog; Chas

  29. Hello! Someone in my Facebook group shared this website with us so I
    came to look it over. I’m definitely enjoying the information. I’m bookmarking and will be tweeting this to
    my followers! Outstanding blog and outstanding design and style.


Leave a Comment