PEP8 Cleanups

This commit is contained in:
Roberto Rosario
2014-11-11 14:58:37 -04:00
parent 5fbfe99c2f
commit 84493b7a72
34 changed files with 30 additions and 87 deletions

View File

@@ -12,14 +12,11 @@ class SmartLinkManager(models.Manager):
def get_for(self, document, smart_link_obj=None):
errors = []
result = {}
metadata_dict = {}
for document_metadata in document.document_metadata.all():
metadata_dict[document_metadata.metadata_type.name] = document_metadata.value
smart_link_qs = self.model.objects.filter(enabled=True)
if smart_link_obj:
smart_link_qs= smart_link_qs.filter(pk=smart_link_obj.pk)
smart_link_qs = smart_link_qs.filter(pk=smart_link_obj.pk)
smart_link_qs = smart_link_qs.filter(document_types=document.document_type)