1)查看群成员的时候,经常出现这个样子:
一直没发显示:群主和群成员。 据我调试,好像是js 没有执行到 发送 获取 “群成员”和“群主”信息的接口的代码。要核实一下:
获取群成员的js如下:
conn.queryRoomMember({roomId: ‘420621056150#appkey‘,success: function(members){console.log(JSON.stringify(members))}})
返回:array对象,如下:
[{"jid":"[email protected]","affiliation":"member","role":"participant","nick":"webim/+8615912341015_3398351031"}]
获取群主的js接口如下:
conn.queryRoomOwner({roomId: ‘420621056150#appkey‘,success: function(onwers){console.log(JSON.stringify(onwers))}})
返回:array读写:
[{"jid":"[email protected]","affiliation":"owner","role":null,"nick":null}]
时间: 2024-10-29 14:40:27