Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactored behavior for duplicating resources and elements #14411

Merged
merged 6 commits into from Feb 23, 2019

Conversation

@GulomovCreative
Copy link
Contributor

GulomovCreative commented Feb 19, 2019

What does it do?

  1. Adds normal resource duplication dialog like duplicating via context menu in resource tree
  2. Adds new redirect to duplicate option before duplicating resources and elements (Templates, TVs, Chunks, Snippets and Plugins)
  3. Fixs misbehavior duplicate children checkbox
  4. Adds related headers for duplicating modal

ux

Why is it needed?

Good UX behavior + description from related issue #4834

Duplicating a resource behaves inconsistently when used via context menu in resource tree and via a button on resource edit form. The former opens a dialog with option to include children resources and setting title for a duplicate and allows to cancel duplication. The latter issues warning about all child resources being duplicated and creates new resource. User is presented with a form for a new resource and if cancels edition an empty untitled resource is left.

Both should have the same behavior of the former (there was an issue for it), ie. context menu command.

Note for testers

  1. There are a few bugs, but they are not related to this PR. Later, I or someone will post the issues.
  2. Checks for the existance on node in this PR are needed for these cases when resource hide in tree (for example: miniShop2 uses show in tree 0 to hide products).

Related issue(s)/PR(s)

Closes #4834 and closes #14409

@Mark-H

Mark-H approved these changes Feb 21, 2019

@JoshuaLuckers JoshuaLuckers self-assigned this Feb 21, 2019

@JoshuaLuckers JoshuaLuckers merged commit 64f74a8 into modxcms:3.x Feb 23, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.