nextcloud / polls

🗳️ Polls app for Nextcloud
https://apps.nextcloud.com/apps/polls
GNU Affero General Public License v3.0
254 stars 73 forks source link

Missing "Group" list items in the "Add Shares" chooser #2086

Closed WNYmathGuy closed 2 years ago

WNYmathGuy commented 2 years ago

What is going wrong? What did you observe?

In a recently build NC 22 instance, I have a plethora of User Groups and some similarly named Contact Groups. I can't confirm it at this moment, but I'm confident that the string differs slightly. e.g. the User Group is Board_Member and the Contact Group is Board Member.

A clear and concise description of what is wrong.

Steps to reproduce the behavior

  1. Create a new or select any existing Poll, then open the section for Shares
  2. Click on the field for + Add Shares and begin to type the letters of one of the user groups.
  3. Observe that a User Group is not selectable, but a Contact Group similarly named is selectable.
  4. Keep typing letters till it's a unique User Group designation and only the Everyone User Group will show.

PollsBugReport2

Add a screenshot of the misbehavior PollsBugReport1

PollsBugReport3

How should it work?

The interactive filter/group chooser share field needs to be able to display general user groups that administrators created in a NC instance.

A clear and concise description of

Information about your polls installation

Polls version: 3.3.0

Fresh installation or update from a prior version (from which one)?

How did you install this version? (Appstore or describe installation)

Information about your Instance of Nextcloud

Generated System Report

Link: https://service.harrogatesquare.com/index.php/s/w7DH2Ay6w25iG5s Password: eeQp7cl97FYSPV9fhbnS

dartcafe commented 2 years ago

I cannot reproduce this, I get the user group and the contact group as well. Please check your sharing settings settings/admin/sharing If this is checked, you have to be member of the group, you search for. grafik

WNYmathGuy commented 2 years ago

If this is checked, you have to be member of the group, you search for. grafik

That's not checked on either of my NC instances.

I did more experimentation when I got home yesterday. My older but fully upgraded NC instance has trouble with the same thing as the new NC instance. What I'm finding out right now, is it might be a couple of factors based on experimentation.

  1. Users, contact lists, and contacts are discovered with case insensitive searches, user groups are requiring case sensitive strings
  2. User groups that are all lower-case one-word alpha strings come up in a partial search.
  3. User groups that contain non-alphabet characters or mixed case strings need an exact match and the full string to be listed.

Screenshot from 2021-11-11 20-46-46

Screenshot from 2021-11-11 20-47-07

Screenshot from 2021-11-11 20-23-00

Screenshot from 2021-11-11 20-29-58

Screenshot from 2021-11-11 20-32-00

Screenshot from 2021-11-11 20-45-28

dartcafe commented 2 years ago

Even this is not reproducible for me: grafik

WNYmathGuy commented 2 years ago

Well, hell. Would the version of MariaDB or MySQL make a difference? I don't use the lower number ones from APT for Ubuntu, I have the better ones direct from the maker's sites.

I guess you could make it a low priority thing though since I found that typing out the full same case string allows me to get the intended results.

Can you show me the SQL statements you use to populate that filtration of entities?

dartcafe commented 2 years ago

Group searching is done here, using the core GroupManager: https://github.com/nextcloud/polls/blob/ca43714937e58e357c96b7685b98e95b321b8599/lib/Model/UserGroup/Group.php#L63-L77

The app forms no SQL statements. And I don't think that the version makes any difference.

Is there any difference between adding a share in the polls app to adding it in the files app?

github-actions[bot] commented 2 years ago

This issue is marked as stale, because it had no activity in the last 30 days. It will be closed in 5 days.

github-actions[bot] commented 3 months ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.