diff options
| author | Edouard Maffert | 2016-09-09 16:07:34 +0200 |
|---|---|---|
| committer | Edouard Maffert | 2016-09-09 16:07:34 +0200 |
| commit | 2d52366ebac8af84cfec37dab9df5b43261fffe4 (patch) | |
| tree | b820e064516f58b4f5fed6cddde99f7f5b9e042b /config | |
| parent | 4747990c6d3ceb5020d06099d086500b066db6e4 (diff) | |
| download | chouette-core-2d52366ebac8af84cfec37dab9df5b43261fffe4.tar.bz2 | |
associate networks to line referential
Diffstat (limited to 'config')
| -rw-r--r-- | config/initializers/apartment.rb | 3 | ||||
| -rw-r--r-- | config/locales/networks.en.yml | 8 | ||||
| -rw-r--r-- | config/locales/networks.fr.yml | 4 | ||||
| -rw-r--r-- | config/routes.rb | 3 |
4 files changed, 12 insertions, 6 deletions
diff --git a/config/initializers/apartment.rb b/config/initializers/apartment.rb index 59bbea437..93ce2d8c6 100644 --- a/config/initializers/apartment.rb +++ b/config/initializers/apartment.rb @@ -29,7 +29,8 @@ Apartment.configure do |config| "LineReferential", "Chouette::Line", "Chouette::GroupOfLine", - "Chouette::Company" + "Chouette::Company", + "Chouette::Network" ] # use postgres schemas? diff --git a/config/locales/networks.en.yml b/config/locales/networks.en.yml index 0a5555b43..69b45050e 100644 --- a/config/locales/networks.en.yml +++ b/config/locales/networks.en.yml @@ -1,5 +1,5 @@ en: - networks: + networks: &en_networks actions: new: "Add a new network" edit: "Edit this network" @@ -17,7 +17,7 @@ en: advanced_search: "Advanced search" activerecord: models: - network: + network: zero: "network" one: "network" other: "networks" @@ -59,5 +59,7 @@ en: hub: network: name: "maximum 75 characters" - registration_number: "Positif integer, unique key, of no more than 8 digits." + registration_number: "Positif integer, unique key, of no more than 8 digits." objectid: "[prefix]:PTNetwork:[unique_key] : prefix contains only alphanumerical or underscore characters, unique_key accepts also minus character. Maximum length of the unique key = 3." + referential_networks: + <<: *en_networks
\ No newline at end of file diff --git a/config/locales/networks.fr.yml b/config/locales/networks.fr.yml index 1abd6e1c0..c31982b43 100644 --- a/config/locales/networks.fr.yml +++ b/config/locales/networks.fr.yml @@ -1,5 +1,5 @@ fr: - networks: + networks: &fr_networks actions: new: "Ajouter un réseau" edit: "Modifier ce réseau" @@ -61,3 +61,5 @@ fr: name: "maximum 75 caractères" registration_number: "Entier positif, clé unique, d'un maximum de 8 chiffres." objectid: "[prefixe]:PTNetwork:[clé_unique] caractères autorisés : alphanumériques et 'souligné' pour le préfixe, la clé unique accepte en plus le 'moins'. Longueur maximale de la clé unique = 3." + referential_networks: + <<: *fr_networks
\ No newline at end of file diff --git a/config/routes.rb b/config/routes.rb index 1cd809c59..414bbde79 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -59,6 +59,7 @@ ChouetteIhm::Application.routes.draw do resources :lines resources :group_of_lines resources :companies + resources :networks end resources :referentials do @@ -79,7 +80,7 @@ ChouetteIhm::Application.routes.draw do put :unarchive end - resources :networks + resources :networks, controller: "referential_networks" match 'lines' => 'lines#destroy_all', :via => :delete resources :lines, controller: "referential_lines" do |
