Skip to content

Commit

Permalink
Updates README with fallbacks information
Browse files Browse the repository at this point in the history
  • Loading branch information
jeroenj committed Sep 21, 2011
1 parent 41613ed commit 8c5fa4e
Showing 1 changed file with 18 additions and 10 deletions.
28 changes: 18 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Makes product details, properties, prototypes, taxonomies and option types translatable by bridging the [Globalize3](https://github.com/svenfuchs/globalize3) gem.

## Installation and configuration: ##
## Installation and configuration ##

In your Gemfile, add:

Expand All @@ -26,44 +26,52 @@ If you have pre-existing data, you'll need to run this rake task:

it will copy the original data over to the new translation tables. Globalize3 doesn't default to the original model table for the default locale like v1 used to.

## How to use it: ##
## How to use it ##

To edit the content in a specific language, simply change the locale on the language nav, and edit on the admin as usual.

## Translated fields: ##
## Translated fields ##

Product:
### Product ###

* name
* description
* meta_description
* meta_keywords

Property:
### Property ###

* presentation

Prototype:
### Prototype ###

* name

Taxonomy:
### Taxonomy ###

* name

Taxon:
### Taxon ###

* name
* description

OptionType:
### OptionType ###

* presentation

OptionValue:
### OptionValue ###

* presentation

## Fallbacks for empty translations ##

If you have translations in your database (by using the [spree-simple_product_translations](https://github.com/jeroenj/spree-simple_product_translations) extension for example) with empty translations (being a blank string instead of `nil`) you might want to add this configuration option to an initializer in your app:

Spree::Config.set :fallbacks_for_empty_translations => true

It will then use fallbacks for empty strings too.

## Running tests ##

The tests are not updated since the original fork of the spree 0.11 compatible version. They will pretty sure fail. Feel free to fork the project and create a pull request with tests.
Expand Down

0 comments on commit 8c5fa4e

Please sign in to comment.