Leadformance/hstore_translate

Make translations column name configurable

Closed this issue · 1 comments

It would be nice to have an option to define the name of the column used to store the translations. E.g. I'd like to use a column without the _translations extension. Why not use something like title directly?

If the title was just a simple string then I'd definitely go with a title column. IMO xxx_translations is more descriptive in this instance because you can look at the DB schema and understand what's happening at a glance. It also suggests that you'll need to do a little extra work to construct a SQL query that selects a meaningful title. e.g. SELECT title_translations -> 'en' AS title FROM posts.