Beispiel #1
0
    def save(self, *args, **kwargs):
        from message_helper import read_message

        created = self.id is not None
        # Send an email if this are a new contributor
        if created:
            # Contribute
            parsed = read_message(self.device.phone_number, self.message, auto_mode=False)
            self.keyword = self.message.split()[0]
            self.parsed = parsed
        super(Message, self).save(*args, **kwargs)
Beispiel #2
0
def receive_sms(mobile_number, message):
    read_message(mobile_number, message)