Beispiel #1
0
def current_date():
    entities = Datastore.get_one_property(KIND,
                                          'release_date',
                                          order=['-release_date'],
                                          limit=1)
    if len(entities) == 0:
        return ''
    return Datastore.entity_to_dict(entities[0]['release_date'])
Beispiel #2
0
def get_last_no():
    nos = Datastore.get_one_property(KIND, 'no', order=['-no'], limit=1)
    if len(nos) == 0:
        return 0

    return nos[0]['no']