Archive for February, 2008

Dojo, Dojox, dojox.grid

February 16, 2008

Discovered some wonders of grids, charts, etc. using dojo and dojox.grid.  Looks to be cool.

On my Windows system, installed easy_install (you run one python program),
added python25/scripts onto my Windows path (control panel, system, advanced, environment variables),
installed pylons (paste one line into DOS command box). 
Installed helloworld example: paster create -t pylons helloworld
Started pylons server: paster serve –reload development.ini
and accessed a web page at http://localhost:5000/!

Continuing with the instructions in: http://wiki.pylonshq.com/display/pylonsdocs/Getting+Started
We start an application: paster controller hello
However, this gives an error: Command controller not known. Maybe I’m in the wrong subdirectory?
Ok, look at the web page from localhost:5000 above (index.html), which says to first
remove index.html, edit the routes in helloworld/config/routing.py to “point the root path to a hello controller we’ll create”
 map.connect(”, controller=’hello’, action=’index’)
and THEN do paster controller hello
This time, no error.  It created hello.py.

http://localhost:5000/hello now gives the output from this hello.py controller.

Django to Pylons?

February 15, 2008

We converted the existing database schema for Django, including adding numeric ID columns where we had multiple column keys.  Django is helpful in that you instantly get maintenance pages for the tables, for adding/changing/deleting records.  We’d also like to see joins and ‘maintain’ the data from that view, without having to go find the individual row in its own table. 

There were frustrations with Django, as I’m sure one would have with any new platform.  There is a “book” online, but several of the examples didn’t work and when looking online for help, it was hard to find the answers.  Django doesn’t seem to help much with reporting.  Our reports need multi table joins and summaries,

I was excited to read about SQLAlchemy and how it handles a lot of fancy database ideas we’d want.  Not available in Django, and only sort-of available in Turbogears.  Pylons does support it.  Pylons of course is less mature than the other two so no doubt we’ll run into issues, but now ready to try it out.