wechaty / puppet-supports

Wechaty Puppet Services (WPS)
https://wechaty.js.org/docs/puppet-services/
Apache License 2.0
33 stars 4 forks source link

[BUG]WorkPro:findAll如何不获取到群成员或者对其有区分 #563

Closed 233312-ship-it closed 2 weeks ago

233312-ship-it commented 2 months ago

findAll 全部成员都获取到了

findAll如何不获取到群成员或者对其有区分

IQZZ020501 commented 2 months ago

const allContacts = await wechat.Contact.findAll(); const externalContacts = allContacts.filter(c => c.payload?.friend === true && c.payload?.type === 1 && !c.coworker()); 这个是获取到企微外部联系人的,获取到内部的把后面的判断去掉就好了