Browse files

Merge pull request #3 from brandonsavage/bug764187

Bug 764187 - Adding version field support for DLL files.
  • Loading branch information...
2 parents 729e535 + 4be3e71 commit ce5de9395c04da161fa2a6c245668990be31ecd9 @brandonsavage brandonsavage committed Jun 13, 2012
Showing with 5 additions and 1 deletion.
  1. +1 −0 apps/dll/models.py
  2. +1 −0 apps/dll/templates/dll/view.html
  3. +1 −0 migrations/04-add-version.sql
  4. +2 −1 migrations/schematic_settings.py
View
1 apps/dll/models.py
@@ -22,6 +22,7 @@ class File(models.Model):
modified_by = models.ForeignKey(User, related_name="modified_by")
file_name = models.CharField(max_length=200)
common_name = models.CharField(max_length=200, blank=True, null=True)
+ version = models.CharField(max_length=100, blank=True, null=True)
vendor = models.CharField(max_length=200, blank=True, null=True)
distributors = models.CharField(max_length=200, blank=True, null=True)
md5_hash = models.CharField(max_length=32, blank=True, null=True)
View
1 apps/dll/templates/dll/view.html
@@ -20,6 +20,7 @@
<tr><th>Modified</th><td>{{ dll_datetime_format(dlldata.date_modified) }} by {{ dlldata.modified_by }}</td></tr>
<tr><th>File Name</th><td>{{ dlldata.file_name }}</td></tr>
<tr><th>Common Name</th><td>{{ dlldata.common_name }}</td></tr>
+ <tr><th>Version</th><td>{{ dlldata.version }}</td></tr>
<tr><th>Vendor</th><td>{{ dlldata.vendor }}</td></tr>
<tr><th>Distributors</th><td>{{ dlldata.distributors }}</td></tr>
<tr><th>MD5 Hash</th><td>{{ dlldata.md5_hash }}</td></tr>
View
1 migrations/04-add-version.sql
@@ -0,0 +1 @@
+ALTER TABLE dll_file ADD COLUMN `version` varchar(100) NULL;
View
3 migrations/schematic_settings.py
@@ -2,8 +2,9 @@
import os
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+os.environ.setdefault('DJANGO_SETTNGO_SETTINGS_MODULE', 'dlldir.settings')
+
-# Set up playdoh.
import manage
from django.conf import settings

0 comments on commit ce5de93

Please sign in to comment.