Update: This may not be necessary for GIS[[BR]] [changeset:,52] has a rewritten approach to Layers where {{{'gis_layer_%s' % type}}} are SQLTables (inheriting from a base set) which we can use {{{t2.*()}}} on - this seems to give us most (all?) of the benefits below. However I think that PERSON won't be solvable in the same way :/ ---- The GIS module may benefit from writing a LAYER class.[[BR]] Layer Types would extend this base class. Each Layer Type would be a single Table & hence could use the standard RESTlike controller.[[BR]] This should ease maintenance compared to the [wiki:DeveloperGuidelinesGIS current process]. Have the Map Service Catalogue have a tab per Type(*).[[BR]] Each has its own self-processing SQLFORM (generated by T2)[[BR]] (This would make it like S2, which works well) It should make us friendlier to non-!JavaScript browsers (such as Mobile devices), since currently we rely on gis_layers.js to show us only relevant fields. (An alternative use for this script would be to pull in new SQLFORM object via ?format=plain instead of adjusting fields displayed/hidden). This gives us better control of the display order for Layers & better modularity of Layer-processing JS code (1 file per layer type). * Alternatives could be collapsible sections (like appadmin) or submenus on left-hand navigation. * [http://jqueryfordesigners.com/jquery-tabs/ JQuery-Tabs]: "if the markup is well designed, it will automatically degrade nicely without !JavaScript enabled" ---- Objects contain both data and functionality together.[[BR]] A Class in essence defines a new data type.[[BR]] => The Class is not the Controller alone, but the Resource (including Controller)[[BR]] => Each Resource type should extend a base Resource (which extends...?)[[BR]] Currently our resources are defined in the model & hence of type gluon.sql.SQLTable (inc SQLFields)[[BR]] LAYER extends RESOURCE extends SQLTable? or has an attribute SQLTable?[[BR]] Other attributes: * Controller * crud_strings * http://openbookproject.net/thinkcs/python/english2e/ch13.xhtml * http://diveintopython.org/object_oriented_framework/defining_classes.html * http://www.freenetpages.co.uk/hp/alan.gauld/tutclass.htm ---- NB A similar solution probably applies for 'PERSON' as well. ---- [wiki:BluePrintGeographicInformationSystems GIS BluePrints]