diff -r 000000000000 -r b97547f5f1fa goa/skel/schema.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/goa/skel/schema.py Wed Nov 05 15:52:50 2008 +0100 @@ -0,0 +1,14 @@ +from cubicweb.schema import format_constraint + +class Blog(EntityType): + title = String(maxsize=50, required=True) + description = String() + +class BlogEntry(EntityType): + title = String(maxsize=100, required=True) + publish_date = Date(default='TODAY') + text_format = String(meta=True, internationalizable=True, maxsize=50, + default='text/rest', constraints=[format_constraint]) + text = String(fulltextindexed=True) + category = String(vocabulary=('important','business')) + entry_of = SubjectRelation('Blog', cardinality='?*')