Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Enable multiple filter_panel module calls #135

Closed
Tracked by #6
gogonzo opened this issue Nov 28, 2022 · 2 comments
Closed
Tracked by #6

Enable multiple filter_panel module calls #135

gogonzo opened this issue Nov 28, 2022 · 2 comments

Comments

@gogonzo
Copy link
Contributor

gogonzo commented Nov 28, 2022

Why?

We are moving towards module-specific-filter-panel which means that controlling module filters through single UI element is either impossible or too complicated to address.

First obstacle is that we have a single filter panel UI and we are inserting new filters (see observer in FilterStates$srv_active). If you look at this line in FilterStates$insert_filter_state_ui you will understand that location of the HTML element where we insert new card is fixed in the class (so we have a single filter ui module for all teal_modules)

  • It should be possible to call filter-panel module multiple times
  • FilteredData should be still a single-global object
  • private$cards_container_id should be removed
@donyunardi
Copy link
Contributor

donyunardi commented Dec 8, 2022

Acceptance Criteria:

  • When the module changes, the filter panel should show filters related to the module.
  • This will be in teal.slice for now and available for programmer to activate if they want.
  • Once the proposed design is implemented, this will be enable by default in teal.

@gogonzo gogonzo changed the title Enable multiple filter-panel module calls Enable multiple filter_panel module calls Dec 13, 2022
@gogonzo gogonzo removed their assignment Feb 17, 2023
gogonzo added a commit that referenced this issue Jun 16, 2023
Closes #135 and #137 

1. `FilterStates$srv_active` uses `renderUI` instead of `insertUI`. 
2. `teal_slice` has now obligatory `id` field.
3. `teal_slice` object is now a `reactiveValues` which is passed and
stored directly to `FilterState`. This `teal_slice` object can be
returned using `FilterState$get_state`. This gives possibility that one
`teal_slice` object can be present in the same time in multiple
`FilterState` object. This simplifies little constructor of
`FilterState` as we don't have to have check again assertions on
dataname, varname etc.
4. removed `disabled` functionality as it conflicts with module specific
feature. Discussed with @lcd2yyz and we decided to develop some
alternatives to quickly activate/deactivate filters. See (5)
5. added `set_available_teal_slice` (public) and
`ui/srv_available_filters` to link `srv/ui_active` with some reactive
list of "available" slices. This gives a possibility to
activate/deactivate particular state. This reactive list of states is
set in teal which gathers all modules filters and creates a one unique
list of available filters.


Co-authored-by: Aleksander Chlebowski <aleksander.chlebowski@contractors.roche.com>
@gogonzo
Copy link
Contributor Author

gogonzo commented Jul 14, 2023

closed by #300

@gogonzo gogonzo closed this as completed Jul 14, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants