aboutsummaryrefslogtreecommitdiffstats
path: root/gsxws
diff options
context:
space:
mode:
authorFilipp Lepalaan <f@230.to>2013-09-06 22:02:11 +0300
committerFilipp Lepalaan <f@230.to>2013-09-06 22:02:11 +0300
commit36c1e480887902ff7ae0a03c6aa51bbf97a6d036 (patch)
tree0d70144c060e444de3b21dcbe2b04fc45ef4e016 /gsxws
parentf637233e97c1dee118097b25869a880df640ba8b (diff)
downloadpy-gsxws-36c1e480887902ff7ae0a03c6aa51bbf97a6d036.tar.gz
py-gsxws-36c1e480887902ff7ae0a03c6aa51bbf97a6d036.tar.bz2
py-gsxws-36c1e480887902ff7ae0a03c6aa51bbf97a6d036.zip
Added set_status and set_techid to shortcuts to Repair
Diffstat (limited to 'gsxws')
-rw-r--r--gsxws/repairs.py18
1 files changed, 12 insertions, 6 deletions
diff --git a/gsxws/repairs.py b/gsxws/repairs.py
index 79049fb..89eba81 100644
--- a/gsxws/repairs.py
+++ b/gsxws/repairs.py
@@ -17,6 +17,12 @@ REPAIR_TYPES = (
('WH', "Mail-In"),
)
+REPAIR_STATUSES = (
+ ('AWTP', 'Awaiting Parts'),
+ ('AWTR', 'Parts Allocated'),
+ ('BEGR', 'In Repair'),
+ ('RFPU', 'Ready for Pickup')
+)
class Customer(GsxObject):
"""
@@ -215,12 +221,6 @@ class CarryInRepair(Repair):
to a repair. On successful update, the repair confirmation number and
quote for any newly added parts would be returned.
In case of any validation error or unsuccessful update, a fault code is issued.
-
- Carry-In Repair Update Status Codes:
- AWTP Awaiting Parts
- AWTR Parts Allocated
- BEGR In Repair
- RFPU Ready for Pickup
"""
self._namespace = "asp:"
@@ -232,6 +232,12 @@ class CarryInRepair(Repair):
self._data.update(newdata)
return self._submit("repairData", "UpdateCarryIn", "repairConfirmation")
+ def set_techid(self, new_techid):
+ return self.update({'technicianId': new_techid})
+
+ def set_status(self, new_status):
+ return self.update({'statusCode': new_status})
+
class IndirectOnsiteRepair(Repair):
"""