Quantcast
Channel: SCN: Message List - SAPUI5 Developer Center
Viewing all articles
Browse latest Browse all 8124

Re: How to create columns of table dynamically depends on selected dates

$
0
0

First of all, note that the columns are just a regular aggregation like any other (e.g. the rows or items aggregation).

There are two options I can think of:

a) Programmatically: Destroy the columns aggregation (see destroyColumns in the API doc) and then manually adding columns via addColumn based on the date range that you have.

b) Model-driven: as the columns a regular aggregation, you can bind them to a model. You would then need to populate the model based on the date range and then, the columns update accordingly.See the documentation on aggregations for details: SAPUI5 SDK - Demo Kit

Personally, I would prefer option b. You can play around with those approaches. Make sure to include a code sample (e.g. JSBin) if you get stuck anywhere along the way.

- Max


Viewing all articles
Browse latest Browse all 8124

Trending Articles