Guidelines for Providing Custom Data to an Asset Selector

Hello,

how to provide custom data to an asset selector component(codex) ?
Use Case: To show the group structure of subtenants in enterprise tenants.

Thanks,
Divya K

Hi @Divya.Krishnamurthy ,

The AssetSelectorComponent is one of the “smarter” components that is not just displaying data that your provide via inputs to it, but actually requests it on its own.
In order for that component to request data from a subtenant you would need to replace the services that are dependency injected into that component with instances that would request the data from a subtenant. This should be possible by writing a wrapper component that would instantiate the “AssetSelectorComponent” with subtenant specific instances of the services it depends on, which you could provide with an own injector instance.
The same would also need to be done for services that are dependency injected by the components that are used within the “AssetSelectorComponent”.

This is nothing we support and you are on your own with implementing this. This functionality might also break with any upgrade of the Web SDK in case e.g. another set of services is dependency injected.

Regards,
Tristan

1 Like

@Tristan_Bastian Thanks for the detailed explanation