匿名访问列表作者信息 [英] Anonymous Access to List Author Information

查看:59
本文介绍了匿名访问列表作者信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用REST API显示列表,但是当我使匿名用户可以访问该站点和列表时,我的api调用停止了工作.我进行了进一步调查,似乎是我在显示和调用作者信息.如果我删除 我打来的任何作者"字段都可以正常使用.

I'm trying to display a list using REST api, but when I made the site and list accessible to anonymous users my api call stopped working. I investigated further and it appears to be the fact that I am displaying and calling author information. If I remove any Author fields from my call it works without a hitch.

但是,我至少要显示匿名用户的作者姓名(显示名称或名字/姓氏).如果我还可以显示电子邮件地址和电话号码,那将是更好的选择,但我会尽力而为.以下是我目前的情况 使用我的API调用网址时,会根据日期/站点计算一些变量:

However, I want to at least display the author name for anonymous users (display name or first/last name). It would be preferable if I could display email address and phone number as well, but I'll take what I can get. The following is what I'm currently using for my API call url, there are some variables that are calculated based on date/site:

requestUrl +``/_api/web/lists/getbytitle('内部分类')/项目?$ select =标题,描述,类别/标题,价格,ID,已创建,作者/电子邮件,作者/用户名,作者/名字,作者/姓氏,作者/标题,作者/ID& $ filter =(出售的eq 0)和 (状态为'已批准')和(创建的ge datetime'''+三十天+``')& $ orderby =创建的desc& $ expand = Category,Author'

requestUrl + "/_api/web/lists/getbytitle('Internal Classifieds')/items?$select=Title,Description,Category/Title,Price,ID,Created,Author/EMail,Author/UserName,Author/FirstName,Author/LastName,Author/Title,Author/ID&$filter=(Sold eq 0) and (Status eq 'Approved') and (Created ge datetime'" + thirtyDays + "')&$orderby=Created desc&$expand=Category,Author"

是否有任何关于如何允许匿名用户访问此作者信息的想法?我可以考虑一种解决方法,但是如果可以使用一个简单的设置,我宁愿这样做. em>

Any thoughts as to how to allow anonymous users access to this author information? I can think of a work around but if there's a simple setting that I can use, I would rather do that.

推荐答案

您可以停用以下功能并尝试.


最好的问候,


这篇关于匿名访问列表作者信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆