FlatZ-Frontpage icon indicating copy to clipboard operation
FlatZ-Frontpage copied to clipboard

Use json objects instead of objects in settings.js

Open MichaelBitard opened this issue 8 years ago • 0 comments

I think that it would be much easier to configure/use if you used json objects instead of array in your settings.js

For exemple this:

['163', 'Data', 'cell1', 'Lampen Uit', 'onbutton']

would become

{"idx": 163, "jsonField": "Data", "cell": 1, "label": "Lampen Uit", "onbutton": true}

I think it will allow your code to be more readable, because some things like :

var vattr = $.PageDashboardArray[ii][4]; // extra css attributes var vchart = $.PageDashboardArray[ii][4]; // extra css attributes

is quite confusing, the same field is used for 2 different things.

If you agree with it I can start a merge request and begin to work with.

Thanks for this anyway, it's a great job!

MichaelBitard avatar Mar 27 '16 17:03 MichaelBitard