[MGNLUI-6515] Chooser injects observation of the underlying app Created: 19/Jan/21  Updated: 23/Feb/23  Resolved: 23/Feb/23

Status: Closed
Project: Magnolia UI
Component/s: None
Affects Version/s: 6.2.6
Fix Version/s: 6.3.0, 6.2.29

Type: Bug Priority: Neutral
Reporter: Roman Kovařík Assignee: Fernando Cherchi
Resolution: Fixed Votes: 0
Labels: None
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: 34m Time Spent: 34m
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Issue Links:
Relates
relates to MGNLDAM-926 Direct asset upload might be saved in... Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
MGNLUI-7854 Implementation Sub-task Completed Fernando Cherchi  
MGNLUI-7856 Review Sub-task Completed Roman Kovařík  
MGNLUI-7855 PiQA Sub-task Completed Roman Kovařík  
MGNLUI-7857 QA Sub-task Completed Adam Siska  
MGNLUI-7878 Port it to 6.2 Sub-task Completed Fernando Cherchi  
Template:
Acceptance criteria:
Empty
Task DoD:
[X]* Doc/release notes changes? Comment present?
[X]* Downstream builds green?
[X]* Solution information and context easily available?
[X]* Tests
[X]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
[X]* I can still upload new image in asset dialog and the view is refreshed
Bug DoR:
[X]* Steps to reproduce, expected, and actual results filled
[X]* Affected version filled
Epic Link: Datasource observation
Sprint: Nucleus 30
Story Points: 2
Team: Nucleus
Work Started:

 Description   

Steps to reproduce

  1. Edit a tour http://localhost:8080/magnoliaAuthor/.magnolia/admincentral#app:tours:detail;/magnolia-travels/Vietnam--Tradition-and-Today:edit
  2. In the Tour Types multifield, click Select new. The chooser is opened.
  3. Open Tour categories in another browser tab http://localhost:8080/magnoliaAuthor/.magnolia/admincentral#app:tourCategories:browser;/tour-types/cultural::
  4. Delete an item which is visible in the chooser is the other browser tab
  5. Go back to the first tab with the page chooser

Expected results

As author, I don't have to see the changes by other authors when chooser is opened. It's OK if I get new data as soon I open the  chooser again.

Moreover observation actions are unregistered after closing the chooser or even better choosers doesn't need an auto refresh mechanism to improve performance.

Actual results

The change is immediately visible in the chooser.

Moreover observation actions are not unregistered after closing the chooser but are accumulating.

This is not so harmful but also completely useless.

Workaround

Usually not needed but closing the app cleans up.

Development notes

We probably need to bind instance of the observation (preferable no-op = no auto refreshes of the chooser), same way as we bind a dedicated ValueContext for the chooser.



 Comments   
Comment by Roman Kovařík [ 09/Feb/23 ]

Discovery:

implement/bind no-op observation, same way as we bind filters context to choosers: https://git.magnolia-cms.com/plugins/servlet/search?q=bindContext(FilterContext.class)

Generated at Mon Feb 12 09:37:15 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.