-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
365f82b
commit efbe320
Showing
1 changed file
with
7 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
efbe320
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Improvements in SearchControl and UserQueries
Here are some improvements in SearchControl that I've made in the last weeks:
Let's see the details:
Simplified Pinned Filters
Pinned Filters where presented more than two years ago.
While they are successful in making the simpler case simpler (by hiding the query tokens for the common use cases of a query):
They also made the complex case more complex (by adding a lot of PinnedFilter-related options to what before where just a table of Field, Operation and Value):
This experience is quite overwhelming for a newbie, so I tried a few ways to reduce the complexity, like collapsing the OR/AND groups by default, or changing the opacity to the filters that are inactive, but the UX wasn't quite right.
This changes adds a new
Show / hide pinned filter options
that by default:This way when the user switches to the complex filters has just sees a simple Filter, Operation, Value table with only the filters that are currently active.
The Pinned filter configuration can be shown if necessary but is mostly only interesting when configuring a user query anyway.
Summary headers
The SearchControl's column options got a new interesting feature: being able to add an aggregate for the whole table on the header itself.
The typical cases is to show the total sum of a particular value, but in can be any aggregate (Avg, Min, Max, Count, Count Null, Count not Null, Count a particular value).
This aggregate is affected by the filters in the query, but not by the pagination (implicit All).
It's also works, but is not affected by, queries with groupings:
Using Summary headers means doing an extra SQL to the database, so it could be slower for very big tables.
Operations on groups
This is an older feature but maybe not known because is not activated by default.
If you have a SearchControl with grouping activated and you open the contextual menu on one or more selected groups you typically only get a simple "Add Filter" option for the current cell.
This is because by default running operations on groups could be dangerous, but you can activate it by setting
showContextMenu
on theQuerySettings
:The effect on the server side is the same as if the user would have drill-down on the group and selected all the elements, that is, all the Lites in the selected group(s) are resolved in the client-side and sent to the server-side.
Open group with a User query
Finally, and this is a new feature, you can now drill-down in groups using another UserQuery as the template by selecting it in the ContextMenu. Let's see an example:
Imagine that you have a user query
Orders by customer
that shows the orders in a particular interesting format (in this case, grouped by customer).By selecting in
Append filters
we are saying that this user query, when selected, can concatenate his filters to the current SearchControl filters. Till now this was an exotic and not that useful feature, but now this makes the user query eligible when using the context menu on a group.In our example, if we have a SearchControl grouping Orders by State (maybe a UserQuery, but is not necessary) then when we right-click on one group we can see out user query as an option:
And when we click we can see the 21 Orders in state
Ordered
grouped by CustomerNote that the UserQuery now support Summary headers too.
Also, just as with group operations, being able select this option depends on overriding
showContextMenu
on theQuerySettings
.Conclusion
I hope all this changes give you some ideas of new possible UX patterns, so you can make your users happier and more productive using the SearchControl.
efbe320
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
efbe320
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect,
especially Summary Headers very useful for users,
efbe320
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.