04-04-2019 06:02 AM
Hi,
I am trying to filter a list by user in the Mobile app.
In my shell.xaml I have the following filter:
<Entity.Filters> <Filter Id="ASSIGNED_TO" Sql="ASSIGNED_TO = @{System.UserId}" IsDefault="True" /> </Entity.Filters>
How in my list.xaml can I implement the filter?
<List.ShellActions> </List.ShellActions> <ListCell Name="STREET_NAME" Title="Street" /> <ListCell Name="ASSIGNED_TO" Title="User"/>
Thank You
Ciaran
Solved! Go to Solution.
04-04-2019 07:52 AM
Hi Ciaran,
You can use a Search against the list as a Filter here.
Using your 'ASSIGNED_TO' Filter example it would look something like:
<List.ShellActions> <SearchShellAction Filter="ASSIGNED_TO" /> </List.ShellActions>
HTH
04-04-2019 08:00 AM
Hi Ciaran,
you can also have a look at Lab 5b (https://community.hexagongeospatial.com/t5/M-App-Enterprise-Tutorials/How-to-setup-a-Mobile-App-Part...) how to apply a filter to a specific list.
If you specify IsDefault="True" to your entity filter, it will be applied at synchronization level. If you set it to IsDefault="False", you can use it as default filter on a list or e.g.: to filter items of a picker.
Regards
Christian
04-05-2019 12:50 AM
Hi Christian,
That works perfect
Thank you
Ciaran