deschler/django-modeltranslation — pull request #161 by bradenmacdonald (2013-03-08 18:36:35+00:00)
Title: Translated ForeignKey support

This pull request adds support for translated `ForeignKey` relations to django-modeltranslation. As far as I can tell, it works perfectly. The only restriction is that reverse relations are not supported (`related_name` must be set to `'+'` to disable the reverse relation). Unit tests are included.

### Rationale
We use the excellent [django-filer](https://github.com/stefanfoulis/django-filer) to manage media content on our site. We also have a database table containing companies, with a model like this:

```python
from filer.fields.image import FilerImageField

class Company(models.Model):
name = models.CharField(max_length=128)
link = models.CharField(max_length=255, blank=True, null=True, validators=[URLValidator(verify_exists=True), ])
logo = FilerImageField(null=True, blank=True, related_name="+")
```
We want this model to be multilingual. Since some companies have different logos for different languages, we needed the `logo` field to be translatable, but [`FilerImageField`](https://github.com/stefanfoulis/django-filer) is a foreign key, so this required support for `ForeignKey`.