Example #1
0
def fetch_activities_objects(appstruct):
    """
    Fetch company activities in order to be able to associate them to the
    company
    """
    activities = appstruct.pop("activities", None)
    if activities:
        return [CompanyActivity.get(activity_id) for activity_id in activities]
    return []
Example #2
0
def fetch_activities_objects(appstruct):
    """
    Fetch company activities in order to be able to associate them to the
    company
    """
    activities = appstruct.pop('activities', None)
    if activities:
        return [CompanyActivity.get(activity_id) for activity_id in activities]
    return []