Share unpublished components with manageable tokens#6271
Share unpublished components with manageable tokens#6271tramuntanal merged 43 commits intodecidim:developfrom
Conversation
|
Hi @ivan-mr, thanks for the review! The visit counter is not incrementing for those tokens because the components are published, thus not needing tokens to be accessed. Since the permissions resolve once the component is checked to be published, the share token is not fetched or modified, despite being present in the url. Seeing it might be misleading for some users, maybe tokens for a component should be deleted (*or hidden) when the component gets published? @decidim/product @microstudi want to share any thoughts on this? Edit: For now I'll just hide tokens when the component is not published.
|
|
I found the code correct. But I will still wait for the @decidim/product response on this small change in functionality. |
For me, this "Share tokens" screen has a UX issue that's inherited from the rest of the admin panel: that we don't explain much about how this works and its behavior. I think that we should explain a bit about how it works and also that these tokens will get destroyed when the component is published. |
|
@verarojman would you be so kind to add an explanatory text in the "Share tokens" panel explaining
|
|
@tramuntanal I've reviewed this PR and looks good to me. Thanks for the contribution @verarojman! |
Extracted from decidim/decidim#6271

🎩 What? Why?
As part of the development of #6176, the need for a system that allows sharing unpublished components with non-admin users has arised. This PR adds a token system to share unpublished components (easily extendable to other resources) and manage these tokens from the component's configuration screen.
Tokens store the user that created them, as well as the times it is used, the last time used and its expiration date to better control access to these unpublished resources.
📌 Related Issues
📋 Subtasks
📷 Screenshots