Mercurial > libervia-backend
changeset 2434:7fa9456032e7
plugin tickets: specify parent service when using getCommentsService + fill reporter_jid is missing (will be discarded later if not in the schema)
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 15 Nov 2017 08:58:38 +0100 |
parents | 014feb75092d |
children | 49884c579266 |
files | src/plugins/plugin_misc_tickets.py |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/plugins/plugin_misc_tickets.py Wed Nov 15 08:57:19 2017 +0100 +++ b/src/plugins/plugin_misc_tickets.py Wed Nov 15 08:58:38 2017 +0100 @@ -164,7 +164,7 @@ now = utils.xmpp_date() if not item_id: values['created'] = now - comments_service = self._m.getCommentsService(client) + comments_service = yield self._m.getCommentsService(client, service) # we need to use uuid for comments node, because we don't know item id in advance # (we don't want to set it ourselves to let the server choose, so we can have @@ -184,6 +184,8 @@ if not values.get('reporter'): identity = yield self._i.getIdentity(client, client.jid) values['reporter'] = identity['nick'] + if not values.get('reporter_jid'): + values['reporter_jid'] = client.jid.full() item_id = yield self._s.sendDataFormItem(client, service, node, values, schema, item_id, extra, deserialise) defer.returnValue(item_id)