如何构建显示访问信息的 Drupal 视图
我需要创建一个节点选择的视图,其中一些当前用户可能有权或可能无权访问。我希望能够做的是,知道对节点的访问是什么,打印出该节点的链接,或者打印一条声明,让他们知道如果首先满足某些条件,则无法访问该节点。
我原以为这是一件很简单的事情,但尝试后,我不知道如何进行。有人知道如何创建这样的视图吗?
更新:
看起来这可能是使用视图自定义字段的简单问题模块
I need to create a Views of selection of nodes, some of which the current user may or may not have access to. What I would like to be able to do is, known what the access is to a node, print out either a link to the node, or a statement letting them know there is no access to that node without certain conditions met first.
I had thought this was a pretty simple matter, but on attempting it, I don't know how to proceed. Anyone know how to create such a Views?
Update:
Looks like this might be a simple matter of using the Views Custom Field module
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
事实上,我发现的最简单的解决方案是使用 Views Custom Field module 来检查用户是否有权访问节点并根据该节点生成输出:
Indeed, the simplest solution I found was to use the Views Custom Field module to check if the user has access to the node and depending on that, generating output: