summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Reichel <sre@ring0.de>2015-04-26 11:29:29 +0200
committerSebastian Reichel <sre@ring0.de>2015-04-26 11:29:29 +0200
commit2dce2a49d5ca580d036b14b04612182411988572 (patch)
treebb13611abeb1a3c0d6b8844240dd5f7a78e59a78
parent57a827ee21921942df659f2e0f94473d8a731ac0 (diff)
parent1ed153fa3952a0f06dbf657c269ad92ab00cf8c7 (diff)
downloadktt-inventory-system-2dce2a49d5ca580d036b14b04612182411988572.tar.bz2
Merge remote-tracking branch 'github/master'
-rw-r--r--inventar/templates/base.html6
-rw-r--r--inventar/urls.py6
-rw-r--r--inventory/admin.py3
-rw-r--r--inventory/models.py12
l---------inventory/static/admin (renamed from static/admin)0
-rw-r--r--inventory/static/admin.svg (renamed from static/admin.svg)0
-rw-r--r--inventory/static/barcode.svg (renamed from static/barcode.svg)0
-rw-r--r--inventory/static/children.svg (renamed from static/children.svg)0
-rw-r--r--inventory/static/chosen/chosen-sprite.png (renamed from static/chosen/chosen-sprite.png)bin559 -> 559 bytes
-rw-r--r--inventory/static/chosen/chosen.css (renamed from static/chosen/chosen.css)0
-rw-r--r--inventory/static/chosen/chosen.jquery.js (renamed from static/chosen/chosen.jquery.js)0
-rw-r--r--inventory/static/chosen/chosen.jquery_ready.js (renamed from static/chosen/chosen.jquery_ready.js)0
-rw-r--r--inventory/static/design.css (renamed from static/design.css)0
-rw-r--r--inventory/static/edit.svg (renamed from static/edit.svg)0
-rw-r--r--inventory/static/false.svg (renamed from static/false.svg)0
-rw-r--r--inventory/static/home.svg (renamed from static/home.svg)0
-rw-r--r--inventory/static/image.svg (renamed from static/image.svg)0
-rw-r--r--inventory/static/info.svg (renamed from static/info.svg)0
-rw-r--r--inventory/static/note.svg (renamed from static/note.svg)0
-rw-r--r--inventory/static/owner.svg (renamed from static/owner.svg)0
-rw-r--r--inventory/static/parent.svg (renamed from static/parent.svg)0
-rw-r--r--inventory/static/search.svg (renamed from static/search.svg)0
-rw-r--r--inventory/static/stats.svg (renamed from static/stats.svg)0
-rw-r--r--inventory/static/tag.svg (renamed from static/tag.svg)0
-rw-r--r--inventory/static/temporary_parent.svg (renamed from static/temporary_parent.svg)0
-rw-r--r--inventory/static/truck.svg (renamed from static/truck.svg)0
-rw-r--r--inventory/static/true.svg (renamed from static/true.svg)0
-rw-r--r--inventory/static/used.svg (renamed from static/used.svg)0
28 files changed, 15 insertions, 12 deletions
diff --git a/inventar/templates/base.html b/inventar/templates/base.html
index d72414a..a97ed7e 100644
--- a/inventar/templates/base.html
+++ b/inventar/templates/base.html
@@ -13,9 +13,9 @@
<div class="body">
<div class="menu">
<ul>
- <li><a href="{% url home %}"><img src="/static/home.svg" width="24" height="24" /> {% trans "Home" %}</a></li>
- <li><a href="{% url admin:index %}"><img src="/static/admin.svg" width="24" height="24" /> {% trans "Admin Area" %}</a></li>
- <li><a href="{% url stats %}"><img src="/static/stats.svg" width="24" height="24" /> {% trans "Statistics" %}</a></li>
+ <li><a href="{% url "home" %}"><img src="/static/home.svg" width="24" height="24" /> {% trans "Home" %}</a></li>
+ <li><a href="{% url "admin:index" %}"><img src="/static/admin.svg" width="24" height="24" /> {% trans "Admin Area" %}</a></li>
+ <li><a href="{% url "stats" %}"><img src="/static/stats.svg" width="24" height="24" /> {% trans "Statistics" %}</a></li>
<li><br></li>
<li>{% trans "Search Item" %}:
<ul>
diff --git a/inventar/urls.py b/inventar/urls.py
index 7554e92..2a6598b 100644
--- a/inventar/urls.py
+++ b/inventar/urls.py
@@ -13,6 +13,8 @@
# PERFORMANCE OF THIS SOFTWARE.
from django.conf.urls import patterns, include, url
+from django.conf.urls.static import static
+from django.conf import settings
from django.contrib import admin
admin.autodiscover()
@@ -26,7 +28,7 @@ from inventory.views import stats
urlpatterns = patterns('',
url(r'^$', home, name='home'),
- (r'^openid/', include('django_openid_auth.urls')),
+ #(r'^openid/', include('django_openid_auth.urls')),
url(r'^item/(?P<selectedid>[0-9A-Za-z]{4})/$', item, name='item'),
url(r'^search/(?P<term>[^/]+)/$', search, name='search'),
@@ -34,4 +36,4 @@ urlpatterns = patterns('',
url(r'^stats/$', stats, name='stats'),
url(r'^admin/', include(admin.site.urls)),
-)
+) + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
diff --git a/inventory/admin.py b/inventory/admin.py
index bff5587..d805d37 100644
--- a/inventory/admin.py
+++ b/inventory/admin.py
@@ -54,7 +54,8 @@ class BarcodeAdmin(admin.ModelAdmin):
search_fields = ['code',]
class EliminationAdmin(admin.ModelAdmin):
- filter_vertical = ('item',)
+ #filter_vertical = ('item',)
+ pass
admin.site.register(models.Item, ItemAdmin)
admin.site.register(models.Owner)
diff --git a/inventory/models.py b/inventory/models.py
index 8d1aa4b..3e21cf7 100644
--- a/inventory/models.py
+++ b/inventory/models.py
@@ -74,22 +74,22 @@ class Item(models.Model):
description = models.TextField(blank=True, verbose_name=_('description'))
business_area = models.ForeignKey(BusinessArea, verbose_name=_('business area'))
category = models.ForeignKey(Category, verbose_name=_('category'))
- decommissioned = models.BooleanField(verbose_name=_('decommissioned'))
+ decommissioned = models.BooleanField(verbose_name=_('decommissioned'),default=False)
targetQuantity = models.IntegerField(blank=True, null=True, verbose_name=_('target quantity'))
- depreciation = models.BooleanField(verbose_name=_('deprecation'))
+ depreciation = models.BooleanField(verbose_name=_('deprecation'),default=False)
datasheet = models.FileField(upload_to="datasheets/", blank=True, null=True, verbose_name=_('datasheet'))
parent = models.ForeignKey('self', blank=True, null=True, on_delete=models.SET_NULL, verbose_name=_('parent'), related_name='item_parents')
temp_parent = models.ForeignKey('self', blank=True, null=True, on_delete=models.SET_NULL, verbose_name=_('temporal parent'), related_name='item_temp_parents')
- inUse = models.BooleanField(verbose_name=_('in use'))
+ inUse = models.BooleanField(verbose_name=_('in use'),default=False)
supplier = models.TextField(blank=True, verbose_name=_('supplier'))
note = models.TextField(blank=True, verbose_name=_('note'))
ean = models.IntegerField(blank=True, null=True, verbose_name=_('EAN'))
- premium = models.BooleanField(verbose_name=_('premium'))
- unlabeled = models.BooleanField(verbose_name=_('unlabeled'))
+ premium = models.BooleanField(verbose_name=_('premium'),default=False)
+ unlabeled = models.BooleanField(verbose_name=_('unlabeled'),default=False)
image = models.ImageField(upload_to="images/", blank=True, null=True, verbose_name=_('image'))
contact = models.TextField(blank=True, verbose_name=_('contact'))
tag = models.ManyToManyField(Tag, verbose_name=_('tags'))
- permanentLoan = models.BooleanField(verbose_name=_('permanent loan'))
+ permanentLoan = models.BooleanField(verbose_name=_('permanent loan'),default=False)
owner = models.ForeignKey(Owner, blank=True, null=True, on_delete=models.SET_NULL, verbose_name=_('owner'))
def barcodes(self):
diff --git a/static/admin b/inventory/static/admin
index 776e936..776e936 120000
--- a/static/admin
+++ b/inventory/static/admin
diff --git a/static/admin.svg b/inventory/static/admin.svg
index 29042d0..29042d0 100644
--- a/static/admin.svg
+++ b/inventory/static/admin.svg
diff --git a/static/barcode.svg b/inventory/static/barcode.svg
index d2f9efc..d2f9efc 100644
--- a/static/barcode.svg
+++ b/inventory/static/barcode.svg
diff --git a/static/children.svg b/inventory/static/children.svg
index a01f401..a01f401 100644
--- a/static/children.svg
+++ b/inventory/static/children.svg
diff --git a/static/chosen/chosen-sprite.png b/inventory/static/chosen/chosen-sprite.png
index 113dc98..113dc98 100644
--- a/static/chosen/chosen-sprite.png
+++ b/inventory/static/chosen/chosen-sprite.png
Binary files differ
diff --git a/static/chosen/chosen.css b/inventory/static/chosen/chosen.css
index e704d3b..e704d3b 100644
--- a/static/chosen/chosen.css
+++ b/inventory/static/chosen/chosen.css
diff --git a/static/chosen/chosen.jquery.js b/inventory/static/chosen/chosen.jquery.js
index 6d63089..6d63089 100644
--- a/static/chosen/chosen.jquery.js
+++ b/inventory/static/chosen/chosen.jquery.js
diff --git a/static/chosen/chosen.jquery_ready.js b/inventory/static/chosen/chosen.jquery_ready.js
index 65308b8..65308b8 100644
--- a/static/chosen/chosen.jquery_ready.js
+++ b/inventory/static/chosen/chosen.jquery_ready.js
diff --git a/static/design.css b/inventory/static/design.css
index b900217..b900217 100644
--- a/static/design.css
+++ b/inventory/static/design.css
diff --git a/static/edit.svg b/inventory/static/edit.svg
index 0ccf49d..0ccf49d 100644
--- a/static/edit.svg
+++ b/inventory/static/edit.svg
diff --git a/static/false.svg b/inventory/static/false.svg
index b10fbfe..b10fbfe 100644
--- a/static/false.svg
+++ b/inventory/static/false.svg
diff --git a/static/home.svg b/inventory/static/home.svg
index 58a64ce..58a64ce 100644
--- a/static/home.svg
+++ b/inventory/static/home.svg
diff --git a/static/image.svg b/inventory/static/image.svg
index a0e80c0..a0e80c0 100644
--- a/static/image.svg
+++ b/inventory/static/image.svg
diff --git a/static/info.svg b/inventory/static/info.svg
index 15242b6..15242b6 100644
--- a/static/info.svg
+++ b/inventory/static/info.svg
diff --git a/static/note.svg b/inventory/static/note.svg
index 272543a..272543a 100644
--- a/static/note.svg
+++ b/inventory/static/note.svg
diff --git a/static/owner.svg b/inventory/static/owner.svg
index 17b364b..17b364b 100644
--- a/static/owner.svg
+++ b/inventory/static/owner.svg
diff --git a/static/parent.svg b/inventory/static/parent.svg
index 42981e3..42981e3 100644
--- a/static/parent.svg
+++ b/inventory/static/parent.svg
diff --git a/static/search.svg b/inventory/static/search.svg
index b574620..b574620 100644
--- a/static/search.svg
+++ b/inventory/static/search.svg
diff --git a/static/stats.svg b/inventory/static/stats.svg
index 6b7862f..6b7862f 100644
--- a/static/stats.svg
+++ b/inventory/static/stats.svg
diff --git a/static/tag.svg b/inventory/static/tag.svg
index 9588018..9588018 100644
--- a/static/tag.svg
+++ b/inventory/static/tag.svg
diff --git a/static/temporary_parent.svg b/inventory/static/temporary_parent.svg
index 35147cd..35147cd 100644
--- a/static/temporary_parent.svg
+++ b/inventory/static/temporary_parent.svg
diff --git a/static/truck.svg b/inventory/static/truck.svg
index cbbac92..cbbac92 100644
--- a/static/truck.svg
+++ b/inventory/static/truck.svg
diff --git a/static/true.svg b/inventory/static/true.svg
index 7cdb9ee..7cdb9ee 100644
--- a/static/true.svg
+++ b/inventory/static/true.svg
diff --git a/static/used.svg b/inventory/static/used.svg
index 2092fe8..2092fe8 100644
--- a/static/used.svg
+++ b/inventory/static/used.svg