Created
January 16, 2012 20:07
-
-
Save xen/1622718 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from .models import Model, ModelRegistry | |
class User(Model): | |
__yaml__ = 'user.yaml' | |
john = User(**kw) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
title: User | |
description: > | |
User profile with common fields used on various sites | |
fields: | |
- name: name | |
title: Name | |
type: string | |
length: 80 | |
required: 1 | |
- name: second | |
title: Second Name | |
type: string | |
length: 80 | |
- name: bday | |
title: Birthday | |
type: date | |
required: 1 | |
widget: date | |
- name: about | |
title: About | |
description: > | |
Some text about you here is welcome | |
db_name: about | |
widget: | |
name: wysiwyg | |
theme: simple | |
- name: friends | |
type: reference | |
reference_model: User | |
desription: > | |
List of your friends on site |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment