diff options
| author | Luc Donnet | 2012-03-01 09:33:45 +0100 |
|---|---|---|
| committer | Luc Donnet | 2012-03-01 09:33:45 +0100 |
| commit | a3c86f6713d87f9b8bb3e2164a9ae32ccd11b005 (patch) | |
| tree | 15e38365be8aa9c1a3ff64edb35445dbaa71672d /config | |
| parent | 1bf6eb00189e124674a70cb7216fb002f12b79ca (diff) | |
| download | chouette-core-a3c86f6713d87f9b8bb3e2164a9ae32ccd11b005.tar.bz2 | |
Refactor lines index view
Diffstat (limited to 'config')
| -rw-r--r-- | config/initializers/ninoxe.rb | 4 | ||||
| -rw-r--r-- | config/initializers/squeel.rb | 12 | ||||
| -rw-r--r-- | config/locales/lines.yml | 4 | ||||
| -rw-r--r-- | config/locales/networks.yml | 2 |
4 files changed, 19 insertions, 3 deletions
diff --git a/config/initializers/ninoxe.rb b/config/initializers/ninoxe.rb index 9a4c2d7ec..3c26e41f4 100644 --- a/config/initializers/ninoxe.rb +++ b/config/initializers/ninoxe.rb @@ -1,4 +1,8 @@ +Chouette::ActiveRecord.establish_chouette_connection = false + + class Chouette::Line + def self.model_name name = "Line" def name.name diff --git a/config/initializers/squeel.rb b/config/initializers/squeel.rb new file mode 100644 index 000000000..aa3f2ff02 --- /dev/null +++ b/config/initializers/squeel.rb @@ -0,0 +1,12 @@ +Squeel.configure do |config| + # To load hash extensions (to allow for AND (&), OR (|), and NOT (-) against + # hashes of conditions) + config.load_core_extensions :hash + + # To load symbol extensions (for a subset of the old MetaWhere functionality, + # via ARel predicate methods on Symbols: :name.matches, etc) + # config.load_core_extensions :symbol + + # To load both hash and symbol extensions + # config.load_core_extensions :hash, :symbol +end diff --git a/config/locales/lines.yml b/config/locales/lines.yml index f2099eccf..486c13b36 100644 --- a/config/locales/lines.yml +++ b/config/locales/lines.yml @@ -27,8 +27,8 @@ fr: title: Ligne %{line} index: title: Lignes - activerecord: - models: + activerecord: + models: line: Lignes attributes: line: diff --git a/config/locales/networks.yml b/config/locales/networks.yml index e03fdfe5b..efe748364 100644 --- a/config/locales/networks.yml +++ b/config/locales/networks.yml @@ -31,7 +31,7 @@ fr: title: "Réseaux" activerecord: models: - network: Réseaux + network: Réseau attributes: network: registrationnumber: "Identifiant" |
