-
Type: Improvement
-
Status: Open
-
Priority: Minor
-
Resolution: Unresolved
-
Affects Version/s: 10.10
-
Fix Version/s: None
-
Component/s: Web UI
-
Tags:
Currently Nuxeo.DocumentContentBehavior uses a computed binding to set the value of `params`. This poses a couple of problems:
Problem 1: You cannot set the value of a property that has a computed binding directly. I.e. can't do something like:
observers: ['_setParams(currentUser)'], _setParams: function(currentUser) { if (currentUser && currentUser.id) { this.params = { "alert_user": currentUser.id } } },
Problem 2: the computing function only observes the `document` property. This is too restrictive as the page provider may have other parameter values that don't depend on the current document. So if you have:
_computeParams: function(document) { return document ? { 'ecm_parentId': document.uid, 'someParam': myCustomParam } : {}; }
There's no guarantee `myCustomParam` has a value since the function only runs when the `document` property changes.
- is related to
-
NXP-28733 Fix loss of applied listing sort(s) after exiting the spreadsheet editor in the Web UI
- Resolved