rtcclientownedBy返回用户ID而不是电子邮件地址
我正在使用 Python 包 rtclcient (v0.6.0) 从工作项获取信息。 我从 RTC 工作项查询的一些属性包括:
returned_properties_list = [
"rtc_cm:modifiedBy",
"dc:modified",
"rtc_cm:contextId",
"dc:subject",
"oslc_cm:priority",
"dc:creator",
"rtc_cm:due",
"rtc_cm:estimate",
"rtc_cm:correctedEstimate",
"rtc_cm:timeSpent",
"rtc_cm:startDate",
"dc:created",
"rtc_cm:resolvedBy",
"rtc_cm:plannedFor",
"rtc_cm:ownedBy",
]
当这些项的查询完成并检查返回的变量时,我注意到“ownedBy”值是用户的 ID,而不是他们的电子邮件地址。 如果我查看 raw_data['rtc_cm:ownedBy']['@rdf:resource']
的值,它是一个指向该用户个人资料的链接。
在个人资料上,我可以看到作为“ownedBy”值接收的相同用户 ID。 个人资料上还有用户的电子邮件地址。这个电子邮件地址值是我需要的,但我似乎找不到使用 rtcclient python 包查询该值的方法。
我尝试将 "rtc_cm:emailAddress"
添加到我的查询属性中,但没有成功,
任何人都可以帮助我使用 rtcclient 包获取 RTC 票证的ownedBy 用户电子邮件地址吗?谢谢
I am using the Python package rtclcient (v0.6.0) to get info from work item.
Some of the properties I am querying from my RTC work item include:
returned_properties_list = [
"rtc_cm:modifiedBy",
"dc:modified",
"rtc_cm:contextId",
"dc:subject",
"oslc_cm:priority",
"dc:creator",
"rtc_cm:due",
"rtc_cm:estimate",
"rtc_cm:correctedEstimate",
"rtc_cm:timeSpent",
"rtc_cm:startDate",
"dc:created",
"rtc_cm:resolvedBy",
"rtc_cm:plannedFor",
"rtc_cm:ownedBy",
]
When the query for these items finish and I examine the returned variables, I notice that the 'ownedBy' value is the user's id, not their email address.
If I look at the value of raw_data['rtc_cm:ownedBy']['@rdf:resource']
it is a link which goes to that user's profile.
On the profile I can see the same User ID which is being recieved as the 'ownedBy' value.
Also on the profile is the User's E-mail Address. This email address value is what I need, but I can't seem to find a way to query for this value using the rtcclient python package.
I've tried adding "rtc_cm:emailAddress"
to my query properties but no luck,
Can anyone help me get the ownedBy user email address for a RTC ticket using the rtcclient package? Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
通过克隆 rtcclient 存储库并添加我自己的自定义函数 getUserEmail 来修复
fixed by cloning the rtcclient repo, and adding my own custom function getUserEmail