forked from edward/owl-map
		
	Column property for EWKT
This commit is contained in:
		
							parent
							
								
									fe4564cc7c
								
							
						
					
					
						commit
						fa3a2880bf
					
				| 
						 | 
				
			
			@ -197,6 +197,10 @@ class MapMixin:
 | 
			
		|||
    def geojson_str(cls):
 | 
			
		||||
        return column_property(func.ST_AsGeoJSON(cls.way), deferred=True)
 | 
			
		||||
 | 
			
		||||
    @declared_attr
 | 
			
		||||
    def as_EWKT(cls):
 | 
			
		||||
        return column_property(func.ST_AsEWKT(cls.way), deferred=True)
 | 
			
		||||
 | 
			
		||||
    def geojson(self):
 | 
			
		||||
        return json.loads(self.geojson_str)
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in a new issue