aboutsummaryrefslogtreecommitdiffstats
path: root/servo/models
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2015-12-11 11:44:47 +0200
committerFilipp Lepalaan <filipp@mac.com>2015-12-11 11:44:47 +0200
commit9b0079214a8f011dc1e4919ccd9fc7504a8b62e1 (patch)
tree751519b543cd766505f23759ab27b539ad3c8146 /servo/models
parentc19241dc3812c92b150376c3c8108c3359aaf488 (diff)
downloadServo-9b0079214a8f011dc1e4919ccd9fc7504a8b62e1.tar.gz
Servo-9b0079214a8f011dc1e4919ccd9fc7504a8b62e1.tar.bz2
Servo-9b0079214a8f011dc1e4919ccd9fc7504a8b62e1.zip
Cleanup
Diffstat (limited to 'servo/models')
-rw-r--r--servo/models/parts.py1
-rw-r--r--servo/models/repair.py6
2 files changed, 7 insertions, 0 deletions
diff --git a/servo/models/parts.py b/servo/models/parts.py
index c7076d8..f854fdc 100644
--- a/servo/models/parts.py
+++ b/servo/models/parts.py
@@ -264,6 +264,7 @@ class ServicePart(models.Model):
part.returnOrderNumber = self.return_order
if self.box_number > 0:
part.boxNumber = self.box_number
+
return part
def needs_comptia_code(self):
diff --git a/servo/models/repair.py b/servo/models/repair.py
index c7ae4a1..9649b86 100644
--- a/servo/models/repair.py
+++ b/servo/models/repair.py
@@ -190,6 +190,9 @@ class Repair(models.Model):
issue_code = models.CharField(max_length=7, default='')
def get_symptom_code_choices(self):
+ """
+ Returns the possible symptom codes for the current serial number
+ """
# @fixme: what if it's someone else ordering the part?
self.gsx_account.connect(self.created_by)
ckey = 'symptom_codes-%s' % self.device.sn
@@ -197,6 +200,9 @@ class Repair(models.Model):
return cache_getset(ckey, si.fetch)
def get_issue_code_choices(self):
+ """
+ Returns the possible issue codes for the current symptom code
+ """
# @fixme: what if it's someone else ordering the part?
self.gsx_account.connect(self.created_by)
ckey = 'issue_codes-%s' % self.symptom_code