Skip to content
This repository has been archived by the owner on Sep 3, 2020. It is now read-only.

jgirardet/mapistar

Repository files navigation

mapistar

image

Documentation Status

image

Pypi package

Api pour ma gestion d'un dossier médical sous Apistar

Features

  • TODO

Usage

  • TODO
class Customer(db.Entity):
    id = PrimaryKey(int, auto=True)
    email = Required(str)

@db_session
def handler(email):
    c = Customer(email=email)
    # c.id is equal to None
    # because it is not assigned by the database yet
    c.flush()
    # c is saved as a table row to the database.
    # c.id has the value now
    print(c.id)

Note

When :pyflush is called, the object is saved only inside the current session.

It means it will be peristed to the database after calling :pycommit manually (not necessary in most cases) or automatically before leaving the current database session.

About

Web Doctor API using Apistar

Resources

License

Stars

Watchers

Forks

Packages

No packages published