craftcms / craftcms/cms

FR: Duplicate asset or copy asset to a different volume

Open
#2,755 0 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

assets :file_folder:
Dominant language
PHP
Stars
3.6k
Forks
705
Avg merge
1d 5h
Merged PRs (30d)
134

Description

Description

It would be great to provide an option to select one or more assets and either copy them to a different volume or duplicate them in the current volume and use the existing feature to drag them to a different volume.

Currently to create a duplicate image asset you need to edit the image and select the option to save it as a new asset. Would be nice to have this option in the context menu.

One fantastic feature of craft is you can assign custom fields to asset volumes. So as an example I could have an image in my "images" volume that has the custom field "caption". I may want to use the same image in a different volume, for example "heroes" (for header images) and for that volume I may want to use different custom fields. Having a option to quickly create a copy of the asset in another volume or duplicate the asset(s) and then drag and drop to the other volume would be great.

One specific case of this is the "Splash" plugin which provides the facility to download images from Unsplash to a specific volume. It would be great to easily copy these images to other volumes within the "assets" section to reuse them in multiple contexts.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files or tests are named. Start by tracing the asset section’s selection, context-menu, and volume drag-and-drop entry points, then define how duplicate and cross-volume copy should behave for selected assets; done means both requested reuse workflows are supported.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.