cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
IulianBurlacu
Frequent Visitor

How to get td value from lookup modal ?

I have the following case: 

In my form , after I pres the first search button I get a list of items.

In the list of items ,there is a type column.

I need to filter the results of the next lookup field based on the type value.

Is the any way to get the type value of the selected row in the list with javascript and filter with that ?

Screenshot 1.png

Screenshot 2.png

1 ACCEPTED SOLUTION

Accepted Solutions
OliverRodrigues
Super User
Super User

@IulianBurlacu were you able to follow this article: http://oliverrodrigues365.com/2021/01/24/power-apps-portals-custom-lookup-filter/ ?




If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

Power Apps Portals Super User


Oliver Rodrigues


 

View solution in original post

4 REPLIES 4
ragavanrajan
Super User
Super User

Hi @IulianBurlacu 

I think for your use case. You can implement a metadata filter. Adding reference below 

 

official URL: https://docs.microsoft.com/en-us/powerapps/maker/portals/configure/entity-lists 

 

ragavanrajan_0-1638838431912.png

Additional info: 

 

https://softchief.com/2021/08/23/step-by-step-enable-configure-metadata-filters-for-entity-list-in-p... 

 

so you can have a metadata filter for any columns you like. 

 

Hope it helps. 
------------

If you like this post, give it a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users to find it.

IulianBurlacu
Frequent Visitor

thank you for your answer, but I want the filtering to happen behind the scenes. In other words ... I want to implement something like this code: 

$(document).ready(function (){
  $(".entitylist.entity-grid").on("loaded", function () {
    $(this).children(".view-grid").find("tr").each(function (){
      // do something with each row
      $(this).css("background-color", "yellow");
    });
  });
}); 

 to my first lookup modal / view !

Where can I find that view ? Should I just write the javascript in the basic form?

I have seen some elegant solution that @OliverRodrigues was suggesting but I dont know how to get the elements of that lookup modal.

OliverRodrigues
Super User
Super User

@IulianBurlacu were you able to follow this article: http://oliverrodrigues365.com/2021/01/24/power-apps-portals-custom-lookup-filter/ ?




If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

Power Apps Portals Super User


Oliver Rodrigues


 

I converted the lookup to a  dropdown and filtered the results with the help of webapi. So I solved one problem but I'm still having problems finding the right selectors for different modals on the page when inspecting it. Its a lot of detective work involved which takes a lot of time.

I'd love some tips and tricks on that one or maybe some real consulting time.

Helpful resources

Announcements
Welcome Super Users.png

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (2,471)