diff options
| author | Marc Florisson | 2013-07-01 14:44:25 +0200 |
|---|---|---|
| committer | Marc Florisson | 2013-07-01 14:44:25 +0200 |
| commit | a7977aee809c710736d94f3c615547eefffd01b3 (patch) | |
| tree | a0eb15785a08876f92c8c115ee0be8bbe4d63a84 | |
| parent | f66e6fbdbae9f98e2814b44bf50dbb02a17c9f2c (diff) | |
| parent | 6e4a709fd4ae7eb5aac1729b66da81a940caed46 (diff) | |
| download | chouette-core-a7977aee809c710736d94f3c615547eefffd01b3.tar.bz2 | |
Merge branch 'master' of github.com:dryade/chouette2
| -rw-r--r-- | CHANGELOG.md | 5 | ||||
| -rw-r--r-- | README.md | 14 | ||||
| -rw-r--r-- | app/assets/images/icons/kml.png | bin | 0 -> 1049 bytes | |||
| -rw-r--r-- | app/assets/stylesheets/layout.css.scss | 4 | ||||
| -rw-r--r-- | app/helpers/stop_areas_helper.rb | 2 | ||||
| -rw-r--r-- | app/views/access_points/show.html.erb | 4 | ||||
| -rw-r--r-- | app/views/lines/index.html.erb | 1 | ||||
| -rw-r--r-- | app/views/lines/show.html.erb | 2 | ||||
| -rw-r--r-- | app/views/routes/show.html.erb | 4 | ||||
| -rw-r--r-- | app/views/stop_areas/index.html.erb | 6 | ||||
| -rw-r--r-- | app/views/stop_areas/show.html.erb | 2 | ||||
| -rw-r--r-- | config/locales/imports.yml | 2 | ||||
| -rw-r--r-- | config/locales/lines.yml | 4 | ||||
| -rw-r--r-- | config/locales/organisations.yml | 2 | ||||
| -rw-r--r-- | config/locales/routes.yml | 4 | ||||
| -rw-r--r-- | config/locales/stop_areas.yml | 8 | ||||
| -rw-r--r-- | db/migrate/20130628130527_remove_projection_from_stop_areas.ninoxe_engine.rb | 12 | ||||
| -rw-r--r-- | db/migrate/20130628130528_remove_projection_from_access_points.ninoxe_engine.rb | 12 |
18 files changed, 68 insertions, 20 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index ca9fdcd68..fa901d2f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,10 @@ * suppression des coordonnées projetées en base ** les données sont produites à la volée pour l'export et l'affichage à partir de la projection fixée dans le référentiel * consolidation de l'import GTFS -* ajout d'un export KML +* ajout d'un export KML : +** lignes +** séquences d'arrêt +** arrêts # V2.0.3 (27/05/13) @@ -44,7 +44,7 @@ Install [JRuby] (https://github.com/dryade/chouette2/blob/master/doc/install/jru Get git code : ```sh cd workspace -git clone -b V2_0_3 git://github.com/dryade/chouette2 +git clone -b V2_1_0 git://github.com/dryade/chouette2 cd chouette2 ``` @@ -62,9 +62,9 @@ Install chouette-gui-command to import and export transport offer : ```sh sudo mkdir -p /usr/local/opt/chouette-command/ cd /usr/local/opt/chouette-command/ -wget http://chouette.dryade.net/chouette-cmd_2.0.3.zip -unzip chouette-cmd_2.0.3.zip -cd chouette-cmd_2.0.3 +wget http://chouette.dryade.net/chouette-cmd_2.1.0.zip +unzip chouette-cmd_2.1.0.zip +cd chouette-cmd_2.1.0 sudo chmod a+w . ``` @@ -91,9 +91,9 @@ Install chouette-gui-command to import and export transport offer : ```sh sudo mkdir -p tmp/chouette-command/ cd tmp/chouette-command/ -wget http://chouette.dryade.net/chouette-cmd_2.0.3.zip -unzip chouette-cmd_2.0.3.zip -cd chouette-cmd_2.0.3 +wget http://chouette.dryade.net/chouette-cmd_2.1.0.zip +unzip chouette-cmd_2.1.0.zip +cd chouette-cmd_2.1.0 sudo chmod a+w . ``` diff --git a/app/assets/images/icons/kml.png b/app/assets/images/icons/kml.png Binary files differnew file mode 100644 index 000000000..9e62a35a5 --- /dev/null +++ b/app/assets/images/icons/kml.png diff --git a/app/assets/stylesheets/layout.css.scss b/app/assets/stylesheets/layout.css.scss index 5800a767e..4a5237aa7 100644 --- a/app/assets/stylesheets/layout.css.scss +++ b/app/assets/stylesheets/layout.css.scss @@ -116,4 +116,8 @@ ul.user li.language.selected a.export { background: url(image-path('icons/export-small.png')) no-repeat; } + a.kml { + background: url(image-path('icons/kml.png')) no-repeat; + } + } diff --git a/app/helpers/stop_areas_helper.rb b/app/helpers/stop_areas_helper.rb index 4a2f3f9a4..da29b2ec6 100644 --- a/app/helpers/stop_areas_helper.rb +++ b/app/helpers/stop_areas_helper.rb @@ -5,7 +5,7 @@ module StopAreasHelper end def show_map? - manage_itl || @stop_area.projection_type != nil || @stop_area.long_lat_type != nil + manage_itl || @stop_area.long_lat_type != nil end def manage_access_points diff --git a/app/views/access_points/show.html.erb b/app/views/access_points/show.html.erb index 7f34ed0e0..b7c8ba391 100644 --- a/app/views/access_points/show.html.erb +++ b/app/views/access_points/show.html.erb @@ -1,6 +1,6 @@ <%= title_tag t('access_points.show.title', :access_point => @access_point.name) %> <div class="access_point_show"> - <% if @access_point.projection_type != nil || @access_point.long_lat_type != nil %> + <% if @access_point.long_lat_type != nil %> <%= @map.to_html %> <% end %> <div class="summary"> @@ -53,7 +53,7 @@ <%= t((@access_point.lift_availability == true).to_s) %> </p> <p> <label><%= t('access_points.show.geographic_data') %> </label></p> - <% if @access_point.projection_type == nil && @access_point.long_lat_type == nil %> + <% if @access_point.long_lat_type == nil %> <span class='geo_data'><%= t('access_points.show.no_geographic_data') %></span> <% else %> <% if !@access_point.projection.nil? %> diff --git a/app/views/lines/index.html.erb b/app/views/lines/index.html.erb index ff14e8749..59c341e79 100644 --- a/app/views/lines/index.html.erb +++ b/app/views/lines/index.html.erb @@ -47,6 +47,7 @@ <ul class="actions"> <li><%= link_to t('lines.actions.import'), new_referential_import_path(@referential), :class => "import" %></li> + <li><%= link_to t('lines.actions.export_kml_all'), api_kml_referential_lines_path(@referential, :format => :kml), :class => "kml" %></li> </ul> <h3><%= t(".selection") %></h3> diff --git a/app/views/lines/show.html.erb b/app/views/lines/show.html.erb index 1b30aff49..d5c89cc3b 100644 --- a/app/views/lines/show.html.erb +++ b/app/views/lines/show.html.erb @@ -72,6 +72,8 @@ <li><%= link_to t('lines.actions.destroy'), referential_line_path(@referential, @line), :method => :delete, :data => {:confirm => t('lines.actions.destroy_confirm')}, :class => "remove" %></li> <li><%= link_to t('routes.actions.new'), new_referential_line_route_path(@referential, @line), :class => "add" %></li> <br> + <li><%= link_to t('lines.actions.export_kml'), api_kml_referential_line_path(@referential, @line, :format => :kml), :class => "kml" %></li> + <li><%= link_to t('routes.actions.export_kml_all'), api_kml_referential_line_routes_path(@referential, @line, :format => :kml), :class => "kml" %></li> </ul> <%= creation_tag(@line) %> <% end %> diff --git a/app/views/routes/show.html.erb b/app/views/routes/show.html.erb index 654e3975a..2a73740d9 100644 --- a/app/views/routes/show.html.erb +++ b/app/views/routes/show.html.erb @@ -96,6 +96,10 @@ </li> <% end %> </ul> +<ul class="actions"> + <li><%= link_to t('routes.actions.export_kml'), api_kml_referential_line_route_path(@referential, @line, @route, :format => :kml), :class => "kml" %></li> +</ul> + <%= creation_tag(@route) %> <% end %> diff --git a/app/views/stop_areas/index.html.erb b/app/views/stop_areas/index.html.erb index 982895a29..3c06b67dd 100644 --- a/app/views/stop_areas/index.html.erb +++ b/app/views/stop_areas/index.html.erb @@ -25,6 +25,12 @@ <li><%= link_to t('stop_areas.actions.default_geometry'), default_geometry_referential_stop_areas_path(@referential), :method => :put, :class => "calculator_edit" %></li> </ul> +<ul class="actions"> + <li><%= link_to t('stop_areas.actions.export_kml_place'), api_kml_referential_stop_areas_path(@referential, :format => :kml, :category => "Place" ), :class => "kml" %></li> + <li><%= link_to t('stop_areas.actions.export_kml_commercial'), api_kml_referential_stop_areas_path(@referential, :format => :kml, :category => "CommercialStopPoint" ), :class => "kml" %></li> + <li><%= link_to t('stop_areas.actions.export_kml_physical'), api_kml_referential_stop_areas_path(@referential, :format => :kml, :category => "Physical" ), :class => "kml" %></li> +</ul> + <h3><%= t(".selection") %></h3> <h4><%= t(".area_type") %></h4> diff --git a/app/views/stop_areas/show.html.erb b/app/views/stop_areas/show.html.erb index b98378d71..632036959 100644 --- a/app/views/stop_areas/show.html.erb +++ b/app/views/stop_areas/show.html.erb @@ -39,7 +39,7 @@ </p> <% if !manage_itl %> <p> <label><%= t('stop_areas.show.geographic_data') %> </label></p> - <% if @stop_area.projection_type == nil && @stop_area.long_lat_type == nil %> + <% if @stop_area.long_lat_type == nil %> <span class='geo_data'><%= t('stop_areas.show.no_geographic_data') %></span> <% else %> <% if !@stop_area.projection.nil? %> diff --git a/config/locales/imports.yml b/config/locales/imports.yml index 28e65084c..cb794b2dc 100644 --- a/config/locales/imports.yml +++ b/config/locales/imports.yml @@ -39,6 +39,7 @@ en: CONNECTION_LINK_COUNT: "Connection link count : %{0}" ACCES_POINT_COUNT: "Access Point count : %{0}" MANDATORY_TAG: "Mandatory tag : %{0} " + IGNORED_DATA: "%{0} line %{1} : invalid field %{2} (%{3}) ignored" UNKNOWN_ENUM: "Unknown enum vaule for %{0} : %{1} " EMPTY_TAG: "Empty value : %{0}" BAD_REFERENCE: "Missing reference %{0} for %{1}" @@ -184,6 +185,7 @@ fr: CONNECTION_LINK_COUNT: "Nombre de correspondances extraites : %{0}" ACCES_POINT_COUNT: "Nombre de points d'accès extraits : %{0}" MANDATORY_TAG: "Valeur obligatoire absente ou vide : %{0} " + IGNORED_DATA: "%{0} ligne %{1} : champ %{2} invalide (%{3}) ignoré" UNKNOWN_ENUM: "Valeur de l'enum %{0} inconnue : %{1} " EMPTY_TAG: "Valeur vide : %{0}" BAD_REFERENCE: "Référence %{0} manquante pour %{1}" diff --git a/config/locales/lines.yml b/config/locales/lines.yml index 48e8bff68..d54367358 100644 --- a/config/locales/lines.yml +++ b/config/locales/lines.yml @@ -6,6 +6,8 @@ en: destroy: "Remove this line" destroy_confirm: "Are you sure you want destroy this line?" import: "Import lines" + export_kml: "Export KML line" + export__kml_all: "Export KML lines" new: title: "Add a new line" edit: @@ -66,6 +68,8 @@ fr: destroy: "Supprimer cette ligne" destroy_confirm: "Etes vous sûr de détruire cette ligne ?" import: "Importer des lignes" + export_kml: "Export KML de la ligne" + export_kml_all: "Export KML des lignes" new: title: "Ajouter une ligne" edit: diff --git a/config/locales/organisations.yml b/config/locales/organisations.yml index 011e87966..e6b86d29d 100644 --- a/config/locales/organisations.yml +++ b/config/locales/organisations.yml @@ -15,7 +15,7 @@ en: fr: organisations: actions: - edit: "Mofifier votre organisation" + edit: "Modifier votre organisation" edit: title: "Modifier votre organisation" key_registered: "Clé enregistrée" diff --git a/config/locales/routes.yml b/config/locales/routes.yml index bd6051d0e..f39331944 100644 --- a/config/locales/routes.yml +++ b/config/locales/routes.yml @@ -5,6 +5,8 @@ en: edit: "Edit this route" destroy: "Remove this route" destroy_confirm: "Are you sure you want destroy this route?" + export_kml: "Export KML route" + export_kml_all: "Export KML routes" new: title: "Add a new route" edit: @@ -64,6 +66,8 @@ fr: edit: "Modifier cette séquence d'arrêts" destroy: "Supprimer cette séquence d'arrêts" destroy_confirm: "Etes vous sûr de détruire cette séquence d'arrêts ?" + export_kml: "Export KML de la séquence d'arrêts" + export_kml_all: "Export KML des séquences d'arrêts" new: title: "Ajouter une séquence d'arrêts" edit: diff --git a/config/locales/stop_areas.yml b/config/locales/stop_areas.yml index 7baff0dba..dfc677a71 100644 --- a/config/locales/stop_areas.yml +++ b/config/locales/stop_areas.yml @@ -16,6 +16,9 @@ en: add_routing_lines: "Manage constraint's lines" add_routing_stops: "Manage constraint's stops" default_geometry: "Compute missing geometries" + export_kml_place: "Export KML places" + export_kml_commercial: "Export KML commercial stop points" + export_kml_physical: "Export KML physical" new: title: "Add a new stop" edit: @@ -76,7 +79,7 @@ en: objectid: "Neptune identifier" object_version: "Version" creation_time: "Created on" - creatorid: Created by + creatorid: "Created by" children_ids: "Children" routing_stop_ids: "Attached stops" routing_line_ids: "Attached lines" @@ -106,6 +109,9 @@ fr: manage_access_links: "Gérer les liens arrêt-accès" add_children: "Gérer les fils" default_geometry: "Calculer les géométries manquantes" + export_kml_place: "Export KML des pôles d'échange" + export_kml_commercial: "Export KML des arrêts commerciaux" + export_kml_physical: "Export KML des arrêts physiques" new: title: "Ajouter un arrêt" edit: diff --git a/db/migrate/20130628130527_remove_projection_from_stop_areas.ninoxe_engine.rb b/db/migrate/20130628130527_remove_projection_from_stop_areas.ninoxe_engine.rb index 3eb30a601..36b6a6dca 100644 --- a/db/migrate/20130628130527_remove_projection_from_stop_areas.ninoxe_engine.rb +++ b/db/migrate/20130628130527_remove_projection_from_stop_areas.ninoxe_engine.rb @@ -1,9 +1,15 @@ # This migration comes from ninoxe_engine (originally 20130628124932) class RemoveProjectionFromStopAreas < ActiveRecord::Migration def up - remove_column :stop_areas, :x - remove_column :stop_areas, :y - remove_column :stop_areas, :projection_type + if column_exists? :stop_areas, :x + remove_column :stop_areas, :x + end + if column_exists? :stop_areas, :y + remove_column :stop_areas, :y + end + if column_exists? :stop_areas, :projection_type + remove_column :stop_areas, :projection_type + end end def down diff --git a/db/migrate/20130628130528_remove_projection_from_access_points.ninoxe_engine.rb b/db/migrate/20130628130528_remove_projection_from_access_points.ninoxe_engine.rb index f0640a623..ed7ce1f69 100644 --- a/db/migrate/20130628130528_remove_projection_from_access_points.ninoxe_engine.rb +++ b/db/migrate/20130628130528_remove_projection_from_access_points.ninoxe_engine.rb @@ -1,9 +1,15 @@ # This migration comes from ninoxe_engine (originally 20130628124951) class RemoveProjectionFromAccessPoints < ActiveRecord::Migration def up - remove_column :access_points, :x - remove_column :access_points, :y - remove_column :access_points, :projection_type + if column_exists? :access_points, :x + remove_column :access_points, :x + end + if column_exists? :access_points, :y + remove_column :access_points, :y + end + if column_exists? :access_points, :projection_type + remove_column :access_points, :projection_type + end end def down |
