Patch #35610

Cleanups after Wiki tab removal from project settings (#26579)

Added by Marius BALTEANU about 1 month ago. Updated about 1 month ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Marius BALTEANU% Done:

0%

Category:Code cleanup/refactoring
Target version:5.0.0

Description

This is extracted from #34643.

  • 1. Remove 'edit' action from :manage_wiki permission definition in Redmine::AccessControl.
    Wikis#edit is removed by r17018.
  • 2. Redirect_to project_path after WikisController#destroy.
    • Project settings 'wiki' tab is removed by r16917 & r17017.
    • This action is executed outside the project settings scope after r16916, thus we can better redirect to project_path.
  • 3. Set :wiki menu_item for WikisController#destroy.
    This action is executed inside the project wiki scope after r16916, thus we can better set the menu_item accordingly.

0001-Remove-edit-action-from-manage_wiki-permission-defin.patch Magnifier (1.04 KB) Mischa The Evil, 2021-01-27 09:59

0002-Redirect_to-project_path-after-WikisController-destr.patch Magnifier (1.69 KB) Mischa The Evil, 2021-01-27 09:59

0003-Set-wiki-menu_item-for-WikisController-destroy.patch Magnifier (939 Bytes) Mischa The Evil, 2021-01-27 09:59


Related issues

Copied from Redmine - Patch #34643: Cleanups and fixes after Wiki tab removal from project se... Closed

Associated revisions

Revision 21086
Added by Marius BALTEANU about 1 month ago

Remove 'edit' action from :manage_wiki permission definition in Redmine::AccessControl. Wikis#edit is removed by r17018. (#35610).

Patch by Mischa The Evil.

Revision 21087
Added by Marius BALTEANU about 1 month ago

Redirect_to project_path after WikisController#destroy (#35610).

  • Project settings 'wiki' tab is removed by r16917 & r17017.
  • This action is executed outside the project settings scope after r16916,
    thus we can better redirect to project_path.

Patch by Mischa The Evil.

Revision 21088
Added by Marius BALTEANU about 1 month ago

Set :wiki menu_item for WikisController#destroy (#35610).

This action is executed inside the project wiki scope after r16916,
thus we can better set the menu_item accordingly.

Patch by Mischa The Evil.

Revision 21105
Added by Marius BALTEANU about 1 month ago

Removes unused wikis/edit.js.erb view (#35610).

History

#1 Updated by Marius BALTEANU about 1 month ago

  • Copied from Patch #34643: Cleanups and fixes after Wiki tab removal from project settings (#26579) added

#2 Updated by Marius BALTEANU about 1 month ago

  • File deleted (0004-Disable-the-wiki-module-after-deletion-of-a-project-.patch)

#3 Updated by Marius BALTEANU about 1 month ago

  • File deleted (0005-Changed-wiki-start_page-name-to-I18n-ed-field_start_.patch)

#4 Updated by Marius BALTEANU about 1 month ago

  • Description updated (diff)

#5 Updated by Marius BALTEANU about 1 month ago

  • Status changed from New to Closed

Patches committed, thank you.

#6 Updated by Mischa The Evil about 1 month ago

  • Status changed from Closed to Reopened

Thanks for handling this. Now that I've had a second look at this though, I noticed that the remaining 'edit' JavaScript view (source:/trunk/app/views/wikis/edit.js.erb) is obsolete too and that it can be removed. Can this be handled via this issue (without a patch from me) too?

#7 Updated by Marius BALTEANU about 1 month ago

  • Status changed from Reopened to Closed

Mischa The Evil wrote:

Thanks for handling this. Now that I've had a second look at this though, I noticed that the remaining 'edit' JavaScript view (source:/trunk/app/views/wikis/edit.js.erb) is obsolete too and that it can be removed. Can this be handled via this issue (without a patch from me) too?

View removed in r21105, thanks.

Also available in: Atom PDF