PEP fixes

This commit is contained in:
Oliver Walters 2019-04-28 01:09:48 +10:00
parent aa04941bf1
commit d55ea1a982
14 changed files with 15 additions and 17 deletions

View File

@ -2,4 +2,4 @@
The InvenTree module provides high-level management and functionality.
It provides a number of helper functions and generic classes which are used by InvenTree apps.
"""
"""

View File

@ -1,4 +1,4 @@
"""
"""
Helper forms which subclass Django forms to provide additional functionality
"""

View File

@ -9,7 +9,7 @@ from django.http import StreamingHttpResponse
def str2bool(text, test=True):
""" Test if a string 'looks' like a boolean value.
""" Test if a string 'looks' like a boolean value.
Args:
text: Input text

View File

@ -7,7 +7,6 @@ from __future__ import unicode_literals
from django.db import models
from django.contrib.contenttypes.models import ContentType
from rest_framework.exceptions import ValidationError
from .helpers import str2bool
from django.db.models.signals import pre_delete
from django.dispatch import receiver
@ -125,7 +124,7 @@ class InvenTreeTree(models.Model):
e.g. ["Top", "Second", "Third", "This"]
Returns:
List of category names from the top level to this category
List of category names from the top level to this category
"""
return self.parentpath + [self]

View File

@ -1,4 +1,4 @@
"""
"""
Serializers used in various InvenTree apps
"""

View File

@ -1,4 +1,4 @@
"""
"""
Various Views which provide extra functionality over base Django Views.
In particular these views provide base functionality for rendering Django forms
@ -20,7 +20,7 @@ from rest_framework import views
class TreeSerializer(views.APIView):
""" JSON View for serializing a Tree object.
"""
"""
def itemToJson(self, item):
@ -259,7 +259,7 @@ class IndexView(TemplateView):
class SearchView(TemplateView):
""" View for InvenTree search page.
""" View for InvenTree search page.
Displays results of search query
"""

View File

@ -2,4 +2,4 @@
The Build module is responsible for managing "Build" transactions.
A Build consumes parts from stock to create new parts
"""
"""

View File

@ -55,7 +55,6 @@ class Build(models.Model):
batch = models.CharField(max_length=100, blank=True, null=True,
help_text='Batch code for this build output')
#: Date the build model was 'created'
creation_date = models.DateField(auto_now=True, editable=False)

View File

@ -5,4 +5,4 @@ A company can be either (or both):
- Supplier
- Customer
"""
"""

View File

@ -1,4 +1,4 @@
"""
"""
JSON serializers for Company app
"""

View File

@ -17,7 +17,7 @@ from .forms import CompanyImageForm
class CompanyIndex(ListView):
""" View for displaying list of companies
""" View for displaying list of companies
"""
model = Company

View File

@ -7,4 +7,4 @@ It includes models for:
- Part
- SupplierPart
- BomItem
"""
"""

View File

@ -226,7 +226,7 @@ class SupplierPartDetail(generics.RetrieveUpdateDestroyAPIView):
class SupplierPriceBreakList(generics.ListCreateAPIView):
""" API endpoint for list view of SupplierPriceBreak object
""" API endpoint for list view of SupplierPriceBreak object
- GET: Retrieve list of SupplierPriceBreak objects
- POST: Create a new SupplierPriceBreak object

View File

@ -6,4 +6,4 @@ It includes models for:
- StockLocation
- StockItem
- StockItemTracking
"""
"""