Created
June 5, 2013 17:16
-
-
Save joac/5715573 to your computer and use it in GitHub Desktop.
example for my blog
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
# Imports, for base primitives | |
from tryton_builder import Module, Model, Field | |
# We create a new module | |
module = Module('HelloWorld') | |
# Two models | |
hello = Model('Hello', 'hello.hello') | |
# Add models to module | |
module.add_model(hello) | |
# Add Fields | |
hello.add_field(Field('Char', 'Name')) | |
hello.add_field(Field('Char', 'Greeting')) | |
# Build!! | |
module.build() | |
# Our module is placed on HelloWorld dir |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment