Hello. I am using Contribution plugin. I have a question about it.
How to disable the public and anonymous item options?
I would like the user not to control the public view of the document they contributed.
The public options is a trouble because it allows the contributor (user) to decide whether a document is public or ceases to be so at any time, even though the admin has already configured it as public.
The plugin is opinionated about who has control of the visibility and anonymity of contributed items. In other words, there is no easy way to prevent contributrors from changing the status of their own contributions. This is by design as a way to ensure ownership.
It could work the way you’re asking if you’re comfortable modifying the code. Open this file:
I also found a solution to disable the public option of the contribution form. I added these lines in ContributionController.php. In this way, marking the public option is a necessary condition for the user to send the document. If the user does not check the public option, a message appears on the screen.