2009-06-25 15:34:54 UTC
List<Map> model = new ArrayList<Map>();
for (int i = 0; i < MAX_QTY; i++) {
model.add(new HashMap());
}
Date a = new Date(2009,01,01);
for (int i = 0; i < MAX_QTY; i++) {
model.get(i).put(a, 50);
}
Date a = new Date(2009,01,02);
for (int i = 0; i < MAX_QTY; i++) {
model.get(i).put(a, 40);
}
etc...
Which will create a List of Maps (each Map is a row in the table). The maps contain Date/Qty key/value pairs where the Date is a column. You then need to do as you were before; generate a <display:column> tag for each Date you've added to your maps. This should then produce the table you want. I think.
Ed!