1. Jeffrey Gelens
  2. django-bricks

Commits

Jeffrey Gelens  committed 00bc44d

Beautification

  • Participants
  • Parent commits 6fa82b5
  • Branches default

Comments (0)

Files changed (3)

File bricks/admin.py

View file
  • Ignore whitespace
 from django.contrib import admin
 from django import forms
-from django.contrib.contenttypes import generic
 from models import Brick, Wall, WallPart, Language
 
 class WallPartForm(forms.ModelForm):
 
     class Media:
         js = (
+            'scripts/jquery-ui-sortable.js',
             'scripts/admin/jquery-init.js',
-            'scripts/jquery-ui-sortable.js',
             'scripts/admin/tabular-inline-sortable.js',
             'scripts/admin/tabular-inline-edit.js',
         )
 class BrickInline(admin.TabularInline):
     model = Brick
 
+
 class WallPartAdmin(admin.ModelAdmin):
     model = WallPart
 

File bricks/models.py

View file
  • Ignore whitespace
 from django.db import models
+from django.conf import settings
 from django.utils.translation import ugettext_lazy as _
 from django.utils.translation import ugettext as __
-from django.conf import settings
 from django.contrib.contenttypes.models import ContentType
 from django.contrib.contenttypes import generic
 
     def __unicode__(self):
         return dict(settings.LANGUAGES).get(self.code)
 
+
 class Wall(models.Model):
     """
     A wall is a set of ordered bricks

File bricks/tests.py

  • Ignore whitespace
-"""
-This file demonstrates two different styles of tests (one doctest and one
-unittest). These will both pass when you run "manage.py test".
-
-Replace these with more appropriate tests for your application.
-"""
-
-from django.test import TestCase
-
-class SimpleTest(TestCase):
-    def test_basic_addition(self):
-        """
-        Tests that 1 + 1 always equals 2.
-        """
-        self.failUnlessEqual(1 + 1, 2)
-
-__test__ = {"doctest": """
-Another way to test that 1 + 1 is equal to 2.
-
->>> 1 + 1 == 2
-True
-"""}
-