diff options
| author | Étienne Loks <etienne.loks@proxience.com> | 2015-10-22 20:23:08 +0200 | 
|---|---|---|
| committer | Étienne Loks <etienne.loks@proxience.com> | 2015-10-22 20:23:08 +0200 | 
| commit | a4238e517f88398f072e2afc99d4fa7f827d0173 (patch) | |
| tree | 44a137cacd36d69374defa5a7c6c426b3de8a1a6 /ishtar_common/models.py | |
| parent | c0b669e5a484482079fee49173535f4a4e1e4e16 (diff) | |
| download | Ishtar-a4238e517f88398f072e2afc99d4fa7f827d0173.tar.bz2 Ishtar-a4238e517f88398f072e2afc99d4fa7f827d0173.zip | |
Import: fix strtoboolean formater
Diffstat (limited to 'ishtar_common/models.py')
| -rw-r--r-- | ishtar_common/models.py | 6 | 
1 files changed, 3 insertions, 3 deletions
| diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 25da4b7d7..3b2fca3dd 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -1420,12 +1420,12 @@ class TargetKey(models.Model):          if not self.is_set:              return None          if self.target.formater_type.formater_type == 'StrToBoolean': -            if self.key in ('False', '0'): +            if self.value in ('False', '0'):                  return False -            elif self.key: +            elif self.value:                  return True              return -        return self.key +        return self.value      def save(self, *args, **kwargs):          obj = super(TargetKey, self).save(*args, **kwargs) | 
