Web based family history software

Question Search and replace

  • Peter_S
  • Topic Author
  • Away
  • Premium Member
  • Premium Member
More
6 months 4 weeks ago - 6 months 4 weeks ago #1 by Peter_S
Search and replace was created by Peter_S
The Search and Replace function can be performed by users with the Editor role via the Search menu. This is a very powerful and risky function, which also makes changes directly to the database, bypassing moderator approval of changes.
I suggest that this function not be made available to editors.

Peter

webtrees 2.1.22, vesta modules, chart modules of magicsunday, extended family and imprint of hartenthaler
PHP 8.3.12, MariaDB 10.11.8
Webhosting: genonline.de
Last edit: 6 months 4 weeks ago by Peter_S.

Please Log in or Create an account to join the conversation.

  • JustCarmen
  • Away
  • Elite Member
  • Elite Member
More
6 months 4 weeks ago #2 by JustCarmen
Replied by JustCarmen on topic Search and replace
Add this to the css/js module:

<style>.menu-search-replace {display: none}</style>

You can perform your own edits via the datafix module. No need for the search/replace function in the frontend.


Carmen
Designer of the JustLight theme (comes with a light and dark color palette), Fancy Imagebar, Fancy Research Links and Fancy Treeview for webtrees 2


Check my website at www.justcarmen.nl

Please Log in or Create an account to join the conversation.

More
6 months 4 weeks ago - 6 months 4 weeks ago #3 by kiwi
Replied by kiwi on topic Search and replace
Both proposals are good. But really would it not be better, safer, and simpler to just remove the front-end search & replace function completely?
Last edit: 6 months 4 weeks ago by kiwi.

Please Log in or Create an account to join the conversation.

  • Peter_S
  • Topic Author
  • Away
  • Premium Member
  • Premium Member
More
6 months 4 weeks ago #4 by Peter_S
Replied by Peter_S on topic Search and replace
Thank‘s Nigel, you are right. It is completely sufficient to make the function available exclusively via the Control Panel. 
If there are no objections, I will create a Github issue.

Peter

webtrees 2.1.22, vesta modules, chart modules of magicsunday, extended family and imprint of hartenthaler
PHP 8.3.12, MariaDB 10.11.8
Webhosting: genonline.de

Please Log in or Create an account to join the conversation.

More
6 months 4 weeks ago #5 by Sir Peter
Replied by Sir Peter on topic Search and replace

... makes changes directly to the database, bypassing moderator approval of changes.
 
Objection! The above statement is not correct. I did a quick test searching and replacing a NAME part for several individuals and these changes now require approval.
Instead of removing this feature completely I suggest to make the Search menu configurable with an option to either include or exclude the Search and Replace feature from the menu.

Peter

Please Log in or Create an account to join the conversation.

  • Peter_S
  • Topic Author
  • Away
  • Premium Member
  • Premium Member
More
6 months 4 weeks ago #6 by Peter_S
Replied by Peter_S on topic Search and replace
Thanks for the clarification. I tested it again and it seems that it was tested first with an user without approval restrictions. 

Peter

webtrees 2.1.22, vesta modules, chart modules of magicsunday, extended family and imprint of hartenthaler
PHP 8.3.12, MariaDB 10.11.8
Webhosting: genonline.de

Please Log in or Create an account to join the conversation.

More
6 months 4 weeks ago #7 by xiao
Replied by xiao on topic Search and replace

... makes changes directly to the database, bypassing moderator approval of changes.

 
Objection! The above statement is not correct. I did a quick test searching and replacing a NAME part for several individuals and these changes now require approval.
Instead of removing this feature completely I suggest to make the Search menu configurable with an option to either include or exclude the Search and Replace feature from the menu.
I agree that this point should be decided to display the function at the front desk by the administrator on the control panel.

Please Log in or Create an account to join the conversation.

More
6 months 4 weeks ago #8 by Franz Frese
Replied by Franz Frese on topic Search and replace
The editor should be able to edit, even such risky things: no risk no fun. Else you would not need one. I suppose only an advanced / expierienced editor would use that function.
The control panel is for the administrator. his task is to admin and not to edit content.

Please Log in or Create an account to join the conversation.

More
6 months 4 weeks ago #9 by bschwede
Replied by bschwede on topic Search and replace

Instead of removing this feature completely I suggest to make the Search menu configurable with an option to either include or exclude the Search and Replace feature from the menu.


 
I think this feature should be available for editors in general. An option in the admin backend for a more granular activation of the function would be nice (possibly depending from a certain user role?!).

I suggest an additional preview for the intended changes analogous to the datafix search and replace function could be helpful to reduce risk of unwanted changes.

Regards, Bernd

Please Log in or Create an account to join the conversation.

  • JustCarmen
  • Away
  • Elite Member
  • Elite Member
More
6 months 3 weeks ago #10 by JustCarmen
Replied by JustCarmen on topic Search and replace

I suggest an additional preview for the intended changes analogous to the datafix search and replace function could be helpful to reduce risk of unwanted changes.
Exactly, that is precisely why I have hidden this option from the menu. Too risky. If an editor wants to make general edits he can come to me and I will make the changes with the data-fix module.


Carmen
Designer of the JustLight theme (comes with a light and dark color palette), Fancy Imagebar, Fancy Research Links and Fancy Treeview for webtrees 2


Check my website at www.justcarmen.nl

Please Log in or Create an account to join the conversation.

More
6 months 3 weeks ago #11 by kiwi
Replied by kiwi on topic Search and replace
@justcarmen - I totally agree.

Having an editor make perhaps hundreds of changes, then admin having to approve them all seems extremely inefficient to me. I’ve been removing it from my installation for years, and will continue to do so.

I once had to clean up a big mess after an otherwise reliable editor messed up a bulk replace. Never again.

Please Log in or Create an account to join the conversation.

More
6 months 3 weeks ago #12 by fisharebest
Replied by fisharebest on topic Search and replace
The search-replace in the front-end is

(a) Much simpler than the one in the control panel. It has fewer options, no preview, etc.

(b) Much more complicated than the one in the control panel. It only works on visible data. So if you search/replace a place-name, it won't change the place in any private facts/records.

I'd be happy to remove it.

Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net

Please Log in or Create an account to join the conversation.

More
6 months 3 weeks ago #13 by RickM
Replied by RickM on topic Search and replace
Personally, I think removing the option is not the right choice. Sometimes fewer clicks to get something done is a good thing.

I agree the power of that tool alone suggests one should have careful control over it.. A simple have or have not 'Menu' choice in Control Panel would offer some flexibility at the very least. Some extra coding would be required to provide access per user type that is for sure. A little more difficult would add more flexibility for sure.

One could make an argument that an appropriate 'backup' should be made BEFORE the Search and Replace action occurs. That might have to be manually done or, with even more coding, done automatically.

Lets not 'take away' what we have. Lets have options instead..

 

Rick M
Tauranga
New Zealand - Nu Tirani

alineofmalkins.com/wt-malkins
Webtrees v2.2.1
Hosted by HostAmarada on litespeed Server, PHP v8.3

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum