Dynamically change the value of an Advanced Filter Query set for a Dropdown

Hello all,

I was validating ways to change/update the query connected to the dropdown in the Open Protocol Instance wizard.

We need this change in order to either catch the existing query results in runtime and tailor them to our needs (which I believe can’t be done since the query does not exist in the system) or set a new custom query to fulfill the same purpose. For the second option I was evaluating using the Query option in Advanced Filtering:

Manually I can set it with no issue but I couldn’t find a viable option to set this value dynamically (via metadata, for example).

Can anybody confirm if this is possible to define in the frontend?

Thanks.

Hi Ruben,

Looking at the implementation of the open protocol instance wizard, it is clear that despite the query being a possible input, in angular, of the find-entity component, it is not currently being used by that page. Therefore my suggestion would be to extend the wizard and make the query dynamic through configuration. Given that we also want to avoid customization where possible, make sure that you really need this.

Hi Johann,

Thanks for the reply.

Starting by the end: in truth, what we need is to be able change the results which are presented in the dropdown list. My idea to set the query in the Advanced Filter is a way for us to be able to capture the execution of a specific query in a DEE and filter the results as we wish before returning the final list.

This not being an option (even though I think should be configurable via metadata), the follow-up would be exactly to implement a custom version of the version of the wizard. Given the way that it is set up, with all its steps defined in a single instead of separately, would it still be possible to inject just the single step with a new definition of the dropdown component?

Cheers.

The wizard does not seem to be any different from any other wizard that we have. It should be possible to remove that step and inject a different one through metadata. That way you indeed would not have to extend the whole wizard.

Hello,

I was able to settle that it is indeed possile to perform an injection in this wizard even though it’s not structured in a “classic” way. As long the referenced elements are present, the flexComponents methodology of adding and removing subComponents works fine.

2 notes on this:

  • Since the Step I’m trying to substitute is the first one, I’m still not able to display the custom Step in the first position as I wished to

image

I am using “FlexComponentLocation.NextTo” and I tried pairing with various index values and anchors but none worked so far. The data is still passed correctly so it’s not a major issue but I’d rather not have this displayed differently than the OOB wizard.

  • I didn’t find the specific query object where I could inject a specific query to be used so I ended using the methodology already in place to add extra filters on top of the already-existing ones. For our specific purpose this should suffice but it’d still be nice to know if this can be changed more definitively.

Cheers.