mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
35 lines
636 B
Python
35 lines
636 B
Python
# -*- coding: utf-8 -*-
|
|
from __future__ import unicode_literals
|
|
|
|
from django.contrib import admin
|
|
from import_export.admin import ImportExportModelAdmin
|
|
|
|
from .models import Build, BuildItem
|
|
|
|
|
|
class BuildAdmin(ImportExportModelAdmin):
|
|
|
|
list_display = (
|
|
'part',
|
|
'status',
|
|
'batch',
|
|
'quantity',
|
|
'creation_date',
|
|
'completion_date',
|
|
'title',
|
|
'notes',
|
|
)
|
|
|
|
|
|
class BuildItemAdmin(admin.ModelAdmin):
|
|
|
|
list_display = (
|
|
'build',
|
|
'stock_item',
|
|
'quantity'
|
|
)
|
|
|
|
|
|
admin.site.register(Build, BuildAdmin)
|
|
admin.site.register(BuildItem, BuildItemAdmin)
|