mirror of
https://github.com/plankanban/planka.git
synced 2025-12-09 17:23:18 +03:00
[PR #668] [MERGED] feat: Add ability to duplicate a card #1100
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/plankanban/planka/pull/668
Author: @mattboll
Created: 4/4/2024
Status: ✅ Merged
Merged: 4/5/2024
Merged by: @meltyshev
Base:
master← Head:feature/duplicate📝 Commits (2)
bec2379feat: Add ability to duplicate a cardb86af05fix: Add members and labels when duplicating, refactoring📊 Changes
21 files changed (+505 additions, -6 deletions)
View changed files
📝
client/src/actions/cards.js(+34 -1)📝
client/src/api/cards.js(+7 -0)📝
client/src/components/Card/ActionsStep.jsx(+12 -0)📝
client/src/components/Card/Card.jsx(+3 -0)📝
client/src/components/CardModal/CardModal.jsx(+11 -0)📝
client/src/constants/ActionTypes.js(+3 -0)📝
client/src/constants/EntryActionTypes.js(+2 -0)📝
client/src/containers/CardContainer.js(+1 -0)📝
client/src/containers/CardModalContainer.js(+1 -0)📝
client/src/entry-actions/cards.js(+14 -0)📝
client/src/locales/en/core.js(+3 -0)📝
client/src/locales/fr/core.js(+1 -0)📝
client/src/models/Card.js(+54 -1)📝
client/src/models/Task.js(+15 -0)📝
client/src/sagas/core/services/cards.js(+70 -3)📝
client/src/sagas/core/watchers/cards.js(+2 -0)📝
client/src/selectors/cards.js(+42 -0)➕
server/api/controllers/cards/duplicate.js(+82 -0)📝
server/api/helpers/boards/import-from-trello.js(+3 -1)➕
server/api/helpers/cards/duplicate-one.js(+144 -0)...and 1 more files
📄 Description
Hi,
I really needed to duplicate some cards so I made this, I would love to see it upstream.
It's related to #48 #149 #317
It adds a button to duplicate the card, from the cardModal or the ActionsPopup
It's far from perfect but it's acceptable for my use case. I can work a little bit more on the pull request if needed.
I was not sure what could be the best way to duplicate tasks with cards, if the code is good enough I can do the same thing to duplicate labels, I'm not sure what other data would be relevant, right now it copies the card (name, description…) and tasks.
Also, the new card name is "old name (copy)"
Regards,
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.