diff options
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | servo/models/invoices.py | 3 | ||||
-rw-r--r-- | servo/models/note.py | 18 |
3 files changed, 12 insertions, 11 deletions
@@ -118,7 +118,7 @@ After which you should restart your Servo instance. Documentation ============= -End-user documentation for the system is available [here](https://docs.servoapp.com). +End-user documentation for the system is available [here](https://docs.servoapp.com). A user-friendly list of changes is published [here](https://docs.servoapp.com/changelog/). FAQ diff --git a/servo/models/invoices.py b/servo/models/invoices.py index d88fe60..7fa4287 100644 --- a/servo/models/invoices.py +++ b/servo/models/invoices.py @@ -110,7 +110,7 @@ class Invoice(models.Model): return reverse("invoices-view_invoice", args=[self.pk]) class Meta: - ordering = ('-id', ) + ordering = ('-id',) app_label = 'servo' get_latest_by = "id" @@ -177,6 +177,7 @@ def trigger_order_dispatched(sender, instance, created, **kwargs): description = _(u'Order %s dispatched') % instance.order.code instance.order.notify('dispatched', description, instance.created_by) + @receiver(post_save, sender=Payment) def trigger_payment_received(sender, instance, created, **kwargs): if created: diff --git a/servo/models/note.py b/servo/models/note.py index da9e08a..28393b0 100644 --- a/servo/models/note.py +++ b/servo/models/note.py @@ -419,11 +419,11 @@ class Note(MPTTModel): sender = location.title data = urllib.urlencode({ - 'username': settings.SMS_HTTP_USERNAME, - 'password': settings.SMS_HTTP_PASSWORD, - 'numberto': recipient.replace(' ', ''), + 'username' : settings.SMS_HTTP_USERNAME, + 'password' : settings.SMS_HTTP_PASSWORD, + 'numberto' : recipient.replace(' ', ''), 'numberfrom': sender.encode(SMS_ENCODING), - 'message': self.body.encode(SMS_ENCODING), + 'message' : self.body.encode(SMS_ENCODING), }) from ssl import _create_unverified_context @@ -544,16 +544,16 @@ class Message(models.Model): sent_at = models.DateTimeField(null=True) received_at = models.DateTimeField(null=True) STATUSES = ( - ('SENT', 'SENT'), + ('SENT', 'SENT'), ('DELIVERED', 'DELIVERED'), - ('RECEIVED', 'RECEIVED'), - ('FAILED', 'FAILED'), + ('RECEIVED', 'RECEIVED'), + ('FAILED', 'FAILED'), ) status = models.CharField(max_length=16, choices=STATUSES) METHODS = ( ('EMAIL', 'EMAIL'), - ('SMS', 'SMS'), - ('GSX', 'GSX'), + ('SMS', 'SMS'), + ('GSX', 'GSX'), ) method = models.CharField( max_length=16, |