diff --git a/snikket_web/prosodyclient.py b/snikket_web/prosodyclient.py index 2c76838..fbcccc6 100644 --- a/snikket_web/prosodyclient.py +++ b/snikket_web/prosodyclient.py @@ -100,6 +100,7 @@ class AdminInviteInfo: class AdminGroupInfo: id_: str name: str + muc_jid: typing.Optional[str] members: typing.Collection[str] @classmethod @@ -110,6 +111,7 @@ class AdminGroupInfo: return cls( id_=data["id"], name=data["name"], + muc_jid=data.get("muc_jid") or None, members=data.get("members", []), ) @@ -944,10 +946,12 @@ class ProsodyClient: self, name: str, *, + create_muc: bool = True, session: aiohttp.ClientSession, ) -> AdminGroupInfo: payload = { "name": name, + "create_muc": create_muc, } async with session.post( diff --git a/snikket_web/templates/admin_edit_circle.html b/snikket_web/templates/admin_edit_circle.html index 93e0d7f..c6dac22 100644 --- a/snikket_web/templates/admin_edit_circle.html +++ b/snikket_web/templates/admin_edit_circle.html @@ -1,5 +1,9 @@ {% extends "admin_app.html" %} -{% from "library.j2" import form_button, standard_button, value_or_hint, custom_form_button %} +{% from "library.j2" import form_button, standard_button, value_or_hint, custom_form_button, clipboard_button %} +{% block head_lead %} +{{ super() }} +{% include "copy-snippet.html" %} +{% endblock %} {% block content %}