[Cosmo-dev] Web UI configuration system
Travis Vachon
travis at osafoundation.org
Wed Jun 27 21:05:53 PDT 2007
Hi folks
Our procedure for handling administrator configurable values in the
web ui has been a minor problem for a few months. Pre-custom dojo
build we simply stored these values in src/main/webapp/js/cosmo/ui/
conf.js, but the build process packs and compresses this file like
all the other javascript, making it useless to administrators.
To fix this I've added src/main/webapp/webui.conf. This file contains
a JSON mapping of configuration keys to values. When cosmo.ui.conf is
loaded we fetch this file and mix the values defined there into
cosmo.ui.conf.
cosmo/ui/conf.js still contains the old configuration system, which
is used in quite a bit of code. We might want to think about ways to
phase this out after preview, but they are peacefully coexisting for
now!
-Travis
More information about the cosmo-dev
mailing list