Pass Static Value to Formatter Parameters in XML View

As of UI5 1.61 (commit), you can add static values to the binding info object. The syntax is value instead of path.

parts: [
  { path: '/modelPath' },
  { value: 123 }
],

Same as with path, you can enhance the value binding info with more settings as shown in this demo ==> https://jsbin.com/yeguhow/edit?js,output


⚡ Bug in UI5 1.79 and below

As reported on GitHub issue #2916, there is a bug which was fixed first in UI5 1.80.
Consider adding { value: 123, model: <modelName> } as a temporary solution, or removing the model name from the path (binding from a default model) to circumvent the issue.

Leave a Comment