Ejemplo n.º 1
0
def joinAllPrivateRooms(user):
    database.connect()
    clients = (Client.select().where((Client.owner == user)
                                     & (Client.private)))
    for client in clients:
        socketio.join_room("client_{}".format(client.id))
    database.close()
Ejemplo n.º 2
0
def userClients():
    clients = Client.select().where(Client.owner == g.user)
    return render_template("/user/clients.html", clients=clients)