Beispiel #1
0
def get_horse_schedule(id):
    """
    Retrieves a list of scheduled actions
    
    :param id: Identifier of the horse
    :type id: str

    :rtype: List[ScheduleSummary]
    """
    return [
        ScheduleSummary(s.id, get_schedule_summary_text(s))
        for s in Data.get_horse_schedules(id)
    ]
Beispiel #2
0
def delete_horse(id):
    """
    Removes a horse from the barn
    
    :param id: Identifier of the horse
    :type id: str

    :rtype: None
    """

    for s in Data.get_horse_schedules(id):
        Data.delete(s)
    for a in Data.get_horse_people(id):
        Data.delete(a)
    Data.delete(Horse(id=id))