Feature : targeted private saved searches#20247
Feature : targeted private saved searches#20247tsmr wants to merge 39 commits intoglpi-project:mainfrom
Conversation
|
@trasher @flegastelois i do same PR with last correction included |
trasher
left a comment
There was a problem hiding this comment.
Few comments, very quick read
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
Co-authored-by: Johan Cwiklinski <[email protected]>
|
Change requested is not linked with my Pull Request |
There was a problem hiding this comment.
With the removal of the "is_private" field from the table, I think we should also revisit the creation form.
Indeed, during testing (by a teammate and me), I expected to find this field again once the saved search was created (given that it was visible in the creation form).
Displaying the notion of "Private / Public" makes less sense when talking about Target.
Perhaps we should simply reconsider the display of the creation form (terms to think about), example:
- Replace "Visibility" with "Default target"
- Replace "Private" with "Only for me"
- Replace "Public" with "Chosen entity options"
Thus, once the form is submitted, it will be clear whether or not a default target will be added.
|
Please note: this PR allows the targeting of private saved searches (and not public ones) so the "Only for me" is not true. |
|
Hello, This PR no longer takes into account that, since this change (#18385), it is not possible to create a saved search without having run the search beforehand. This then leads to saved searches that can no longer be clicked:
|

Add option to choose targets for private saved searches.
Modify CommonDBVisible to make it possible to restrict the types of target available, and to choose the right used to determine the availability of user type targets.
For a saved search, a target can either be a user or a group.
User and group dropdown take into account entity of the item when loading available targets.
The class used for the user target might need to be changed (SavedSearch_User is already used so I couldn't follow the naming convention set by the other CommonDBVisible items, so I created SavedSearch_UserTarget for now).
Also the new method getVisibilityRight could be used to dynamically get the right for the itemtype associated with the saved search (to only be able to targets users with the read right on the itemtype).
See PR for screenshots
#17587