diff options
| author | Étienne Loks <etienne.loks@proxience.com> | 2015-11-02 22:01:30 +0100 | 
|---|---|---|
| committer | Étienne Loks <etienne.loks@proxience.com> | 2015-11-02 22:01:30 +0100 | 
| commit | 764b034d9fc01df18adbd9bcd9e7b58d06197934 (patch) | |
| tree | e21fa02606556f8fbb8c414460974f1bfd1f1a38 | |
| parent | 74f4cd6c9381d0f55aabfc2cb771a5cc4751a96c (diff) | |
| download | Ishtar-764b034d9fc01df18adbd9bcd9e7b58d06197934.tar.bz2 Ishtar-764b034d9fc01df18adbd9bcd9e7b58d06197934.zip  | |
Fix town managemnt for parcels
| -rw-r--r-- | archaeological_operations/wizards.py | 8 | 
1 files changed, 7 insertions, 1 deletions
diff --git a/archaeological_operations/wizards.py b/archaeological_operations/wizards.py index cbc5a20c5..6f4a6583a 100644 --- a/archaeological_operations/wizards.py +++ b/archaeological_operations/wizards.py @@ -165,8 +165,14 @@ class OperationWizard(Wizard):                          multi=self.towns_formset,                          multi_value=self.multi_towns) or []                      if town_ids: +                        towns = []                          if type(town_ids) == unicode: -                            town_ids = town_ids.split(',') +                            town_ids = [town_ids] +                        for ids in town_ids: +                            for d in ids.split(','): +                                if d: +                                    towns.append(d) +                        town_ids = towns                          break                  if type(town_ids) not in (list, tuple):                      town_ids = [town_ids]  | 
