views:

16

answers:

1

I am looking for some design patterns or best practices for configuring web page fields.

My web page has a table, which is dynamically created by my API (Wicket).

Currently all the column names are hard coded in the java but I want to make it externalizable that way I can add/remove/modify fields without modifying java code.

Also I want to define each field type, valid value ranges etc.. in this external file.

Are there any recommended approaches for this requirement?

A: 

I've switched all my tables over to JQuery-rendered Datatables I output either HTML tables or (better) JSON data and then let the script build the table. I have full control over columns, sorting, filtering, style, etc via the jQuery configuration script which is rather straightforward. I can even programmatically update via javascript calling JSON over AJAX, so the table can dynamically refresh via just about any means imaginable. From a UI standpoint the results look great and are quickly styled via Themeroller with a few clicks. You really can't go wrong.

bpeterson76