2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-16 03:55:41 +00:00

Fixing python errors

This commit is contained in:
Oliver
2017-04-11 17:21:05 +10:00
parent 1cddec1035
commit 338dcd3b72
19 changed files with 28 additions and 25 deletions

View File

@ -10,5 +10,6 @@ class WarehouseAdmin(admin.ModelAdmin):
class StockItemAdmin(admin.ModelAdmin):
list_display = ('part', 'quantity', 'location', 'status', 'updated')
admin.site.register(Warehouse, WarehouseAdmin)
admin.site.register(StockItem, StockItemAdmin)

View File

@ -1,3 +1,3 @@
from django.test import TestCase
# from django.test import TestCase
# Create your tests here.

View File

@ -1,11 +1,10 @@
from django.shortcuts import render, get_object_or_404
from django.http import HttpResponse
from django.shortcuts import render
from .models import Warehouse, StockItem
from .models import Warehouse
def index(request):
warehouses = Warehouse.objects.filter(parent=None)
return render(request, 'stock/index.html', {'warehouses': warehouses})