Example #1
0
def set_photographic_record(m, phototype):
    if phototype:
        p = PhotoRecord()
        p.museum_object = m
        p.phototype, c = PhotoType.objects.get_or_create(
                phototype=phototype.title())
        p.save()
Example #2
0
def process_photorecord(r):
    p = PhotoRecord()
    p.museum_object, created = MuseumObject.objects.get_or_create(
            registration_number=r['Artefact_Registration'])
    p.phototype, created = PhotoType.objects.get_or_create(
            phototype=r['PhotoType'])
    p.comments = r['Comments']
    p.save()