diff options
| author | Luc Donnet | 2018-03-19 15:31:17 +0100 | 
|---|---|---|
| committer | Luc Donnet | 2018-03-23 17:21:56 +0100 | 
| commit | 7f6142c5786994a611bbf4ea654e4f1a992112ab (patch) | |
| tree | 37bb729647e75ad89267b4a0853b3df9f2b93932 | |
| parent | 4ab6471d5dfecb78ad114cf5f2dc5ec5baaa5d25 (diff) | |
| download | chouette-core-7f6142c5786994a611bbf4ea654e4f1a992112ab.tar.bz2 | |
Fix coordinates synchronization for reflex Refs #6245
| -rw-r--r-- | lib/stif/reflex_synchronization.rb | 7 | 
1 files changed, 5 insertions, 2 deletions
| diff --git a/lib/stif/reflex_synchronization.rb b/lib/stif/reflex_synchronization.rb index 202446da3..508d28b40 100644 --- a/lib/stif/reflex_synchronization.rb +++ b/lib/stif/reflex_synchronization.rb @@ -159,10 +159,13 @@ module Stif            zip_code:       'PostalRegion',            city_name:      'Town',            stif_type:      'OBJECT_STATUS', -          longitude: (entry['gml:pos'] && entry['gml:pos'][:lng]) ? entry['gml:pos'][:lng] : nil, -          latitude: (entry['gml:pos'] && entry['gml:pos'][:lat]) ? entry['gml:pos'][:lat] : nil          }.each do |k, v| stop[k] = entry[v] end +        if entry['gml:pos'] +          stop['longitude'] = entry['gml:pos'][:lng] +          stop['latitude']  = entry['gml:pos'][:lat] +        end +          stop.kind = :commercial          stop.deleted_at            = nil          stop.confirmed_at = Time.now if stop.new_record? | 
