src/pyams_gis/widget/point.py
changeset 12 77e093529691
parent 1 bf796b698a98
child 19 31ec78bbd5d6
--- a/src/pyams_gis/widget/point.py	Mon Dec 11 15:26:52 2017 +0100
+++ b/src/pyams_gis/widget/point.py	Wed Jan 10 12:44:32 2018 +0100
@@ -56,7 +56,7 @@
 
     def updateWidgets(self, setErrors=True):
         super(GeoPointWidget, self).updateWidgets(setErrors)
-        widgets = self.widgets
+        widgets = self.subform.widgets
         widgets['longitude'].input_css_class = 'col-md-2'
         widgets['latitude'].input_css_class = 'col-md-2'
         widgets['longitude'].object_data = {'ams-change-handler': 'PyAMS_GIS.position.changedCoordinate'}
@@ -106,7 +106,7 @@
 
     def updateWidgets(self, setErrors=True):
         super(GeoPointZWidget, self).updateWidgets(setErrors)
-        widgets = self.widgets
+        widgets = self.subform.widgets
         widgets['longitude'].input_css_class = 'col-md-2'
         widgets['latitude'].input_css_class = 'col-md-2'
         widgets['altitude'].input_css_class = 'col-md-2'