Index: location.views.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/location/location.views.inc,v
retrieving revision 1.7
diff -u -p -r1.7 location.views.inc
--- location.views.inc	11 Sep 2008 18:25:04 -0000	1.7
+++ location.views.inc	18 Sep 2008 13:53:35 -0000
@@ -59,7 +59,7 @@ function location_views_data() {
   $data['location']['table']['base'] = array(
     'field' => 'lid',
     'title' => t('Location'),
-    'help' => t("Locations are addresses and map coordinates."),
+    'help' => t('Locations are addresses and map coordinates.'),
     'weight' => -10,
   );
 
@@ -117,82 +117,152 @@ function location_views_data() {
 
   $data['location']['name'] = array(
     'title' => t('Name'),
+    'help' => t('The name of the selected location.'),
     'field' => array(
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
   $data['location']['street'] = array(
     'title' => t('Street'),
+    'help' => t('The street address of the selected location.'),
     'field' => array(
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
   $data['location']['additional'] = array(
     'title' => t('Additional'),
+    'help' => t('The additional street address of the selected location.'),
     'field' => array(
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
   $data['location']['city'] = array(
     'title' => t('City'),
+    'help' => t('The city of the selected location.'),
     'field' => array(
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
 
 
   $data['location']['postal_code'] = array(
     'title' => t('Postal Code'),
+    'help' => t('The postal code of the selected location.'),
     'field' => array(
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
+  );
+  
+  $data['location']['province'] = array(
+    'title' => t('Province'),
+    'help' => t('The province of the selected location.'),
+    'field' => array(
+      'handler' => 'location_handler_field_location_province',
+      'click sortable' => TRUE,
+    ),
+    'filter' => array(
+      'handler' => 'location_views_province_handler',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
 
   // @@@ 1.x Conversion -- 'country' => 'country', style 'name'; 'country_code' => 'country', style 'code'.
   $data['location']['country'] = array(
     'title' => t('Country'),
+    'help' => t('The country of the selected location.'),
     'field' => array(
-      'handler' => 'location_handler_field_location_country',
+      'handler' => 'location_views_country_handler',
       'click sortable' => TRUE,
+      'list' => location_get_iso3166_list(),
+      'list-type' => 'select',
+    ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_string',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
     ),
   );
 
   $data['location']['latitude'] = array(
     'title' => t('Latitude'),
+    'help' => t('The latitude of the selected location.'),
     'field' => array(
       'handler' => 'location_views_handler_field_latitude',
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_numeric',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
   $data['location']['longitude'] = array(
     'title' => t('Longitude'),
+    'help' => t('The longitude of the selected location.'),
     'field' => array(
       'handler' => 'location_views_handler_field_longitude',
       'click sortable' => TRUE,
     ),
+    'filter' => array(
+      'handler' => 'views_handler_filter_numeric',
+    ),
+    'sort' => array(
+      'handler' => 'views_handler_sort',
+    ),
   );
   $data['location']['coordinates'] = array(
     'title' => t('Coordinates'),
+    'help' => t("The coordinates of the selected location in 'lat, long' format."),
     'field' => array(
       'field' => 'latitude', // The handler adds the longitude.
       'handler' => 'location_views_handler_field_coordinates',
       'click sortable' => FALSE,
     ),
     'filter' => array(
-      'handler' => 'location_views_handler_filter_proximity',
+      'handler' => 'location_views_handler_filter_coordinates',
     ),
   );
 
-/*
-      'latitude' => array(
-        'name' => t('Latitude'),
-        'sortable' => TRUE,
-      ),
-      'longitude' => array(
-        'name' => t('Longitude'),
-        'sortable' => TRUE,
-      ),
-*/
+  // TODO: add handlers from location_views where necessary
+  // TODO: add address field
+  // TODO: add 'has_coordinates' filter
+  // TODO: proximity
+  // TODO: user location fields and filters(?)
+  // TODO: arg support
 
 
 
