Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

阅读次数不显示,leancloud创建Counter记录默认权限的问题 #556

Closed
5 of 11 tasks
tanmx opened this issue Dec 31, 2018 · 3 comments
Closed
5 of 11 tasks

Comments

@tanmx
Copy link

tanmx commented Dec 31, 2018

I agree and want to create new issue


Expected behavior

打开新的文章可以显示阅读次数

Actual behavior

最近新增的文章不显示阅读次数,之前的文章正常

NexT Information

NexT Version:

  • Latest Master branch
  • Latest Release version
  • Old version

NexT Scheme:

  • All schemes
  • Muse
  • Mist
  • Pisces
  • Gemini

NexT Configuration:

valine:
  enable: true
  appid: xxx
  appkey: xxx
  notify: false # mail notifier , https://github.com/xCss/Valine/wiki
  verify: false # Verification code
  placeholder: (发表评论) # comment box placeholder
  avatar: mm # gravatar style
  guest_info: nick,mail,link # custom comment header
  pageSize: 10 # pagination size
  visitor: false # leancloud-counter-security is not supported for now. When visitor is set to be true, appid and appkey are recommended to be the same as leancloud_visitors' for counter compatibility. Article reading statistic https://valine.js.org/visitor.html

leancloud_visitors:
  enable: true
  app_id: xxx
  app_key: xxx
  # Dependencies: https://github.com/theme-next/hexo-leancloud-counter-security
  # If you don't care about security in lc counter and just want to use it directly
  # (without hexo-leancloud-counter-security plugin), set the `security` to `false`.
  security: false
  betterPerformance: false

测试后发现新文章在leancloud的counter创建的记录的默认ACL为:

{"*":{"read":true,"write":false}}

手动修改为

{"*":{"read":true,"write":true}}

页面可以显示阅读次数,也可以增加次数

==请问如何修改leancloud默认创建记录的ACL?==

@stevenjoezhang
Copy link
Contributor

stevenjoezhang commented Jan 1, 2019

文章的评论是正常的么?
Need to optimize layout/_third-party/analytics/lean-analytics.swig, related to #271

@stevenjoezhang
Copy link
Contributor

stevenjoezhang commented Jan 1, 2019

@tanmx 你看看设置是否正确:https://leancloud.cn/docs/acl-guide.html#hash-1118516203
对于

如何修改leancloud默认创建记录的ACL

似乎与NexT无关,并且我自己测试是正常的。你可以参照这样:
2019-01-01 4 11 02
2019-01-01 4 12 22

@tanmx
Copy link
Author

tanmx commented Jan 1, 2019

@stevenjoezhang 谢谢 仔细检查后发现ACL列可以设置默认权限,问题解决了

@sli1989 sli1989 added the Solved label Jan 1, 2019
@sli1989 sli1989 changed the title 阅读次数不显示,leancloud创建Counter记录默认权限的问题 阅读次数不显示,leancloud创建Counter记录默认权限的问题 [read leancloud docs carefully] Jan 1, 2019
@ivan-nginx ivan-nginx changed the title 阅读次数不显示,leancloud创建Counter记录默认权限的问题 [read leancloud docs carefully] 阅读次数不显示,leancloud创建Counter记录默认权限的问题 [solved] Mar 4, 2019
@stevenjoezhang stevenjoezhang changed the title 阅读次数不显示,leancloud创建Counter记录默认权限的问题 [solved] 阅读次数不显示,leancloud创建Counter记录默认权限的问题 Mar 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants