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

Show all events (both public and those with ACL active) but only to display the list of events. #1917

Open
mckillo opened this issue Feb 28, 2025 · 12 comments

Comments

@mckillo
Copy link
Collaborator

mckillo commented Feb 28, 2025

Case from the Forum.

Question:
How can I display all events (both public and those with ACL restrictions) in any views where events are listed? Additionally, how can I download an iCal file that includes all events?

Environment:

  • JEM 4.3.2
  • Event 1: Access = Public
  • Event 2: Access = Registered

Current Behavior:
In the event list view or calendar view, an iCal file download icon is displayed. However, if the user is not logged in, the iCal file only includes Event 1 (public). If the user logs in, the iCal file includes both Event 1 and Event 2.

@mckillo
Copy link
Collaborator Author

mckillo commented Feb 28, 2025

Possible solution (draft):

Adding a new parameter in the Global Settings to show all events in the list view. For example, this could include displaying a lock icon on the right side of the event title. This way, users can see the events and download the iCal file, but they won’t be able to access the event details unless they log in or have the necessary permissions.

The idea is to have an option in the JEM Global Settings that allows access to all events (both public and those with ACL active) but only to display the list of events. Currently, JEM (Joomla Event Manager) only has a single access setting, similar to Joomla articles.

Image

In the calendar view, the user can see events with ACL restrictions. However, if the user does not have permission to access the event, it is displayed with a closed lock icon. If the user attempts to access the event by clicking on the event title, JEM displays the following message:

Image

In the event list will be:

Image

In this case, the user can still download the iCal file, which includes this event.

The admin could enable this functionality by adding a new parameter in the JEM Global Settings.

What is your opinion on this proposal?

@mckillo
Copy link
Collaborator Author

mckillo commented Feb 28, 2025

In the backend, this is the draft to set the levels (multi-selection):

Image

This is a mask filter that applies user levels and ACL (Access Control List) for each event to determine whether the user has access or not.

@mckillo
Copy link
Collaborator Author

mckillo commented Feb 28, 2025

This new feature needs a branch https://github.com/jemproject/JEM-Project/tree/level-access-to-show-events.
I will upload the code for testing.

@mckillo
Copy link
Collaborator Author

mckillo commented Feb 28, 2025

Image

mckillo added a commit that referenced this issue Feb 28, 2025
mckillo added a commit that referenced this issue Feb 28, 2025
@mckillo mckillo added the beta label Feb 28, 2025
@mckillo mckillo added this to the JEM 4.3.3 milestone Feb 28, 2025
mckillo added a commit that referenced this issue Feb 28, 2025
@mckillo
Copy link
Collaborator Author

mckillo commented Feb 28, 2025

To testing in calendar view.
It will update the other views, next days.

@jojo12
Copy link
Contributor

jojo12 commented Mar 1, 2025

[Perhaps I don't understand enough!]
I am really not happy!
If what/when/where is public, then there is much too much information.
e.g. there is a meeting for a demonstration on a certain time on a certain place. This are too many public informations for people who want to disturb this. And an icon to inform, that this isn't public, doesn't help!
(I tried with: event is only for registered, Access Level is registered, then the event is visible for public but with a Lock)

When I try with ACL public, then the event is hidden for public! This is much better!!!

EDIT:
So at least, there should be a possibility, to disable all this!

@mckillo
Copy link
Collaborator Author

mckillo commented Mar 2, 2025

I have changed the definition of this new fied:

Image

I think so; it's clearer and more understandable.
The public access level is always active by default to ensure compatibility with the current settings.
In the next commit, I fix some issues, add help text, and implement this field in the eventlist view.

@mckillo
Copy link
Collaborator Author

mckillo commented Mar 2, 2025

An in the second phase:
I will also add an option to select which fields are included in the iCal file for locked events.

  • UID
  • CATEGORIES
  • LINK
  • LOCATION

mckillo added a commit that referenced this issue Mar 2, 2025
The new field is now named 'Show Locked Events'.
It is stored in `_jem_config` as `access_level_listview`.
This feature is active (show lock icon) in the following views: calendar, eventview, and others, for both responsive and legacy layouts.
@mckillo
Copy link
Collaborator Author

mckillo commented Mar 2, 2025

The new field is now named 'Show Locked Events'.
It is stored in _jem_config as access_level_listview.
This feature is active (show lock icon) in the following views: calendar, eventview, and others, for both responsive and legacy layouts.

@jojo12
Copy link
Contributor

jojo12 commented Mar 2, 2025

That means: events with visible lock can be exported with ical (only description and link not). Is this right?

@mckillo
Copy link
Collaborator Author

mckillo commented Mar 2, 2025

Yes, I think that it will be possible to filter this fields in the info of ical file.

"EDIT: By default, UID and LINK will not be included, except if in the setting is set to include link to the event (details).
I have doubts about LOCATION (venues) and CATEGORIES, because they have access, and that is the filter to include or nor.
What is your opinion?

@mckillo
Copy link
Collaborator Author

mckillo commented Mar 2, 2025

Venues have an access value in the _jem_venues table, but there is no code handling it :-(
I found an issue requesting support for access levels in venues (See #1122).
In next second phase, I wil try to dev it.

@mckillo mckillo added the fixed Have a commit with the solution. label Mar 3, 2025
@mckillo mckillo modified the milestones: JEM 4.3.3, JEM 4.4.0 Mar 3, 2025
@mckillo mckillo removed the fixed Have a commit with the solution. label Mar 3, 2025
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

2 participants