diff --git a/zengine/messaging/model.py b/zengine/messaging/model.py index ee362659..8c89810e 100644 --- a/zengine/messaging/model.py +++ b/zengine/messaging/model.py @@ -176,7 +176,7 @@ class Subscriber(Model): is_visible = field.Boolean("Show under user's channel list", default=True) can_manage = field.Boolean("Can manage this channel", default=False) can_leave = field.Boolean("Membership is not obligatory", default=True) - last_seen_msg_time = field.DateTime("Last seen message's time") + last_seen_msg_time = field.TimeStamp("Last seen message's time") # status = field.Integer("Status", choices=SUBSCRIPTION_STATUS) diff --git a/zengine/messaging/views.py b/zengine/messaging/views.py index d1cebb9d..6834edb7 100644 --- a/zengine/messaging/views.py +++ b/zengine/messaging/views.py @@ -238,7 +238,9 @@ def report_last_seen_message(current): Subscriber(current).objects.filter(channel_id=current.input['channel_key'], user_id=current.user_id ).update(last_seen_msg_time=current.input['timestamp']) - + current.output = { + 'status': 'OK', + 'code': 200} def list_channels(current): """