2008/09/24

Scaffold in 0.2

Source code is available here.

Scaffold helps you to quickly create pages that play with entities.
Here's an example:

gaeogen.py scaffold GuestBook new edit index show destroy name:StringProperty email:EmailProperty text:TextProperty

It creates a simple guestbook on http://your-host/guestbook/ which can list, add, modify, and delete posts.

The prototype of scaffold is:

gaeogen.py scaffold <scaffold_name> <actions> <data_name:data_types> ...

where actions include index/new/create/edit/update/show/destroy, and data types must be one of the defined types in GAE.

If you want to set some properties to the type, "name:StringProperty(required=True)" works.

I'm still working on it, and any suggestion is welcome.

0 Comments: