#NEWLINE# def add_site( session ) : #NEWLINE# #INDENT# spatial_ref = add_spatial_reference ( session ) #NEWLINE# site = Site ( 'ABC123' , 'Test Site' ) #NEWLINE# site . latitude = 10.0 #NEWLINE# site . longitude = 10.0 #NEWLINE# site . lat_long_datum_id = spatial_ref . id #NEWLINE# site . local_projection_id = spatial_ref . id #NEWLINE# site . elevation_m = 1000 #NEWLINE# site . local_x = 10.0 #NEWLINE# site . local_y = 10.0 #NEWLINE# session . add ( site ) #NEWLINE# session . commit ( ) #NEWLINE# return site