From 6982b2f0c2b79010ad3faf2e4126f30c9a3619d8 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Sun, 2 Jun 2019 12:47:40 +1000 Subject: [PATCH] Making PEP happy --- InvenTree/InvenTree/models.py | 2 +- InvenTree/stock/forms.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/InvenTree/InvenTree/models.py b/InvenTree/InvenTree/models.py index 948163555c..a7fc93bf3f 100644 --- a/InvenTree/InvenTree/models.py +++ b/InvenTree/InvenTree/models.py @@ -198,7 +198,7 @@ class InvenTreeTree(models.Model): def __str__(self): """ String representation of a category is the full path to that category """ - return "{path} - {desc}".format(path=self.pathstring, desc=self.description) + return self.pathstring @receiver(pre_delete, sender=InvenTreeTree, dispatch_uid='tree_pre_delete_log') diff --git a/InvenTree/stock/forms.py b/InvenTree/stock/forms.py index ef55356961..7187cada4e 100644 --- a/InvenTree/stock/forms.py +++ b/InvenTree/stock/forms.py @@ -69,9 +69,9 @@ class AdjustStockForm(forms.ModelForm): confirm = forms.BooleanField(required=False, initial=False, label='Confirm Stock Movement', help_text='Confirm movement of stock items') def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - - self.fields['destination'].choices = self.get_location_choices() + super().__init__(*args, **kwargs) + + self.fields['destination'].choices = self.get_location_choices() class Meta: model = StockItem