Merge branch 'marc1006-fixes'

This commit is contained in:
Lauri Ojansivu 2020-05-14 01:06:46 +03:00
commit 9c6cd51ca7
58 changed files with 240 additions and 77 deletions

View file

@ -27,6 +27,8 @@ and adds the following translations:
and fixes the following bugs: and fixes the following bugs:
- [Fix Deleting linked card makes board not load](https://github.com/wekan/wekan/issues/2785).
Thanks to marc1006 and xet7.
- [Fix getStartDayOfWeek once again](https://github.com/wekan/wekan/pull/3061). - [Fix getStartDayOfWeek once again](https://github.com/wekan/wekan/pull/3061).
Thanks to marc1006. Thanks to marc1006.
- [Fix shortcuts list and support card shortcuts when hovering - [Fix shortcuts list and support card shortcuts when hovering

View file

@ -956,7 +956,23 @@ BlazeComponent.extendComponent({
}, },
'click .js-delete': Popup.afterConfirm('cardDelete', function() { 'click .js-delete': Popup.afterConfirm('cardDelete', function() {
Popup.close(); Popup.close();
// verify that there are no linked cards
if (Cards.find({ linkedId: this._id }).count() === 0) {
Cards.remove(this._id); Cards.remove(this._id);
} else {
// TODO: Maybe later we can list where the linked cards are.
// Now here is popup with a hint that the card cannot be deleted
// as there are linked cards.
// Related:
// client/components/lists/listHeader.js about line 248
// https://github.com/wekan/wekan/issues/2785
const message = `${TAPi18n.__(
'delete-linked-card-before-this-card',
)} linkedId: ${
this._id
} at client/components/cards/cardDetails.js and https://github.com/wekan/wekan/issues/2785`;
alert(message);
}
Utils.goBoardId(this.boardId); Utils.goBoardId(this.boardId);
}), }),
'change .js-field-parent-board'(event) { 'change .js-field-parent-board'(event) {

View file

@ -658,10 +658,7 @@ BlazeComponent.extendComponent({
_id = element.copy(this.boardId, this.swimlaneId, this.listId); _id = element.copy(this.boardId, this.swimlaneId, this.listId);
// 1.B Linked card // 1.B Linked card
} else { } else {
delete element._id; _id = element.link(this.boardId, this.swimlaneId, this.listId);
element.type = 'cardType-linkedCard';
element.linkedId = element.linkedId || element._id;
_id = Cards.insert(element);
} }
Filter.addException(_id); Filter.addException(_id);
// List insertion // List insertion
@ -675,7 +672,7 @@ BlazeComponent.extendComponent({
element.sort = Boards.findOne(this.boardId) element.sort = Boards.findOne(this.boardId)
.swimlanes() .swimlanes()
.count(); .count();
element.type = 'swimlalne'; element.type = 'swimlane';
_id = element.copy(this.boardId); _id = element.copy(this.boardId);
} else if (this.isBoardTemplateSearch) { } else if (this.isBoardTemplateSearch) {
board = Boards.findOne(element.linkedId); board = Boards.findOne(element.linkedId);

View file

@ -223,8 +223,35 @@ BlazeComponent.extendComponent({
Template.listMorePopup.events({ Template.listMorePopup.events({
'click .js-delete': Popup.afterConfirm('listDelete', function() { 'click .js-delete': Popup.afterConfirm('listDelete', function() {
Popup.close(); Popup.close();
this.allCards().map(card => Cards.remove(card._id)); // TODO how can we avoid the fetch call?
const allCards = this.allCards().fetch();
const allCardIds = _.pluck(allCards, '_id');
// it's okay if the linked cards are on the same list
if (
Cards.find({
$and: [
{ listId: { $ne: this._id } },
{ linkedId: { $in: allCardIds } },
],
}).count() === 0
) {
allCardIds.map(_id => Cards.remove(_id));
Lists.remove(this._id); Lists.remove(this._id);
} else {
// TODO: Figure out more informative message.
// Popup with a hint that the list cannot be deleted as there are
// linked cards. We can adapt the query above so we can list the linked
// cards.
// Related:
// client/components/cards/cardDetails.js about line 969
// https://github.com/wekan/wekan/issues/2785
const message = `${TAPi18n.__(
'delete-linked-cards-before-this-list',
)} linkedId: ${
this._id
} at client/components/lists/listHeader.js and https://github.com/wekan/wekan/issues/2785`;
alert(message);
}
Utils.goBoardId(this.boardId); Utils.goBoardId(this.boardId);
}), }),
}); });

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Viimeksi muokattu", "last-modified-at": "Viimeksi muokattu",
"last-activity": "Viimeisin toiminta", "last-activity": "Viimeisin toiminta",
"voting": "Äänestys", "voting": "Äänestys",
"archived": "Arkistoitu" "archived": "Arkistoitu",
"delete-linked-card-before-this-card": "Et voi poistaa tätä korttia ennenkuin ensin poistat linkitetyn kortin jolla on",
"delete-linked-cards-before-this-list": "Et voi poistaa tätä listaa ennenkuin poistat linkitetyt kortit jotka osoittavat kortteihin tässä listassa"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Dernière modification le", "last-modified-at": "Dernière modification le",
"last-activity": "Dernière activité", "last-activity": "Dernière activité",
"voting": "Vote", "voting": "Vote",
"archived": "Archivé" "archived": "Archivé",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "שינוי אחרון ב־", "last-modified-at": "שינוי אחרון ב־",
"last-activity": "פעילות אחרונה", "last-activity": "פעילות אחרונה",
"voting": "הצבעה", "voting": "הצבעה",
"archived": "בארכיון" "archived": "בארכיון",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Laatste aanpassing op", "last-modified-at": "Laatste aanpassing op",
"last-activity": "Laatste activiteit", "last-activity": "Laatste activiteit",
"voting": "Stemmen", "voting": "Stemmen",
"archived": "Gearchiveerd" "archived": "Gearchiveerd",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -309,7 +309,7 @@
"error-board-notAMember": "Você precisa ser um membro desse quadro para fazer isto", "error-board-notAMember": "Você precisa ser um membro desse quadro para fazer isto",
"error-json-malformed": "Seu texto não é um JSON válido", "error-json-malformed": "Seu texto não é um JSON válido",
"error-json-schema": "Seu JSON não inclui as informações no formato correto", "error-json-schema": "Seu JSON não inclui as informações no formato correto",
"error-csv-schema": "Your CSV(Comma Separated Values)/TSV (Tab Separated Values) does not include the proper information in the correct format", "error-csv-schema": "Seu CSV(Comma Separated Values)/TSV (Tab Separated Values) não inclui a informação adequada no formato correto",
"error-list-doesNotExist": "Esta lista não existe", "error-list-doesNotExist": "Esta lista não existe",
"error-user-doesNotExist": "Este usuário não existe", "error-user-doesNotExist": "Este usuário não existe",
"error-user-notAllowSelf": "Você não pode convidar a si mesmo", "error-user-notAllowSelf": "Você não pode convidar a si mesmo",
@ -317,10 +317,10 @@
"error-username-taken": "Esse username já existe", "error-username-taken": "Esse username já existe",
"error-email-taken": "E-mail já está em uso", "error-email-taken": "E-mail já está em uso",
"export-board": "Exportar quadro", "export-board": "Exportar quadro",
"export-board-json": "Export board to JSON", "export-board-json": "Exportar quadro para JSON",
"export-board-csv": "Export board to CSV", "export-board-csv": "Exportar quadro para CSV",
"export-board-tsv": "Export board to TSV", "export-board-tsv": "Exportar quadro para TSV",
"export-board-html": "Export board to HTML", "export-board-html": "Exportar quadro para HTML",
"exportBoardPopup-title": "Exportar quadro", "exportBoardPopup-title": "Exportar quadro",
"sort": "Ordenar", "sort": "Ordenar",
"sort-desc": "Clique para Ordenar Lista", "sort-desc": "Clique para Ordenar Lista",
@ -357,16 +357,16 @@
"import-board-c": "Importar quadro", "import-board-c": "Importar quadro",
"import-board-title-trello": "Importar quadro do Trello", "import-board-title-trello": "Importar quadro do Trello",
"import-board-title-wekan": "Importar quadro a partir de exportação prévia", "import-board-title-wekan": "Importar quadro a partir de exportação prévia",
"import-board-title-csv": "Import board from CSV/TSV", "import-board-title-csv": "Importar quadro de CSV/TSV",
"from-trello": "Do Trello", "from-trello": "Do Trello",
"from-wekan": "A partir de exportação prévia", "from-wekan": "A partir de exportação prévia",
"from-csv": "From CSV/TSV", "from-csv": "De CSV/TSV",
"import-board-instruction-trello": "No seu quadro do Trello, vá em 'Menu', depois em 'Mais', 'Imprimir e Exportar', 'Exportar JSON', então copie o texto emitido", "import-board-instruction-trello": "No seu quadro do Trello, vá em 'Menu', depois em 'Mais', 'Imprimir e Exportar', 'Exportar JSON', então copie o texto emitido",
"import-board-instruction-csv": "Paste in your Comma Separated Values(CSV)/ Tab Separated Values (TSV) .", "import-board-instruction-csv": "Cole seu Comma Separated Values(CSV)/ Tab Separated Values (TSV) .",
"import-board-instruction-wekan": "Em seu quadro vá para 'Menu', depois 'Exportar quadro' e copie o texto no arquivo baixado.", "import-board-instruction-wekan": "Em seu quadro vá para 'Menu', depois 'Exportar quadro' e copie o texto no arquivo baixado.",
"import-board-instruction-about-errors": "Se você receber erros ao importar o quadro, às vezes a importação ainda funciona e o quadro está na página Todos os Quadros.", "import-board-instruction-about-errors": "Se você receber erros ao importar o quadro, às vezes a importação ainda funciona e o quadro está na página Todos os Quadros.",
"import-json-placeholder": "Cole seus dados JSON válidos aqui", "import-json-placeholder": "Cole seus dados JSON válidos aqui",
"import-csv-placeholder": "Paste your valid CSV/TSV data here", "import-csv-placeholder": "Cole aqui os dados válidos de seu CSV/TSV",
"import-map-members": "Mapear membros", "import-map-members": "Mapear membros",
"import-members-map": "Seu quadro importado possui alguns membros. Por favor, mapeie os membros que você deseja importar para seus usuários", "import-members-map": "Seu quadro importado possui alguns membros. Por favor, mapeie os membros que você deseja importar para seus usuários",
"import-show-user-mapping": "Revisar mapeamento dos membros", "import-show-user-mapping": "Revisar mapeamento dos membros",
@ -399,7 +399,7 @@
"swimlaneActionPopup-title": "Ações de Raia", "swimlaneActionPopup-title": "Ações de Raia",
"swimlaneAddPopup-title": "Adicionar uma Raia abaixo", "swimlaneAddPopup-title": "Adicionar uma Raia abaixo",
"listImportCardPopup-title": "Importe um cartão do Trello", "listImportCardPopup-title": "Importe um cartão do Trello",
"listImportCardsTsvPopup-title": "Import Excel CSV/TSV", "listImportCardsTsvPopup-title": "Importar Excel CSV/TSV",
"listMorePopup-title": "Mais", "listMorePopup-title": "Mais",
"link-list": "Vincular a esta lista", "link-list": "Vincular a esta lista",
"list-delete-pop": "Todas as ações serão excluidas da lista de atividades e você não poderá recuperar a lista. Não há como desfazer.", "list-delete-pop": "Todas as ações serão excluidas da lista de atividades e você não poderá recuperar a lista. Não há como desfazer.",
@ -799,10 +799,12 @@
"saturday": "Sábado", "saturday": "Sábado",
"sunday": "Domingo", "sunday": "Domingo",
"status": "Status", "status": "Status",
"swimlane": "Swimlane", "swimlane": "Raia",
"owner": "Owner", "owner": "Proprietário",
"last-modified-at": "Last modified at", "last-modified-at": "Última modificação em",
"last-activity": "Last activity", "last-activity": "Última atividade",
"voting": "Voting", "voting": "Votação",
"archived": "Archived" "archived": "Arquivado",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -320,7 +320,7 @@
"export-board-json": "Экспортировать доску в JSON", "export-board-json": "Экспортировать доску в JSON",
"export-board-csv": "Экспортировать доску в CSV", "export-board-csv": "Экспортировать доску в CSV",
"export-board-tsv": "Экспортировать доску в TSV", "export-board-tsv": "Экспортировать доску в TSV",
"export-board-html": "Export board to HTML", "export-board-html": "Экспортировать доску в HTML",
"exportBoardPopup-title": "Экспортировать доску", "exportBoardPopup-title": "Экспортировать доску",
"sort": "Сортировать", "sort": "Сортировать",
"sort-desc": "Нажмите, чтобы отсортировать список", "sort-desc": "Нажмите, чтобы отсортировать список",
@ -804,5 +804,7 @@
"last-modified-at": "Последний раз изменено", "last-modified-at": "Последний раз изменено",
"last-activity": "Последние действия", "last-activity": "Последние действия",
"voting": "Голосование", "voting": "Голосование",
"archived": "Архивировано" "archived": "Архивировано",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Senast ändrad", "last-modified-at": "Senast ändrad",
"last-activity": "Senaste aktivitet", "last-activity": "Senaste aktivitet",
"voting": "Röstning", "voting": "Röstning",
"archived": "Arkiverad" "archived": "Arkiverad",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -804,5 +804,7 @@
"last-modified-at": "Last modified at", "last-modified-at": "Last modified at",
"last-activity": "Last activity", "last-activity": "Last activity",
"voting": "Voting", "voting": "Voting",
"archived": "Archived" "archived": "Archived",
"delete-linked-card-before-this-card": "You can not delete this card before first deleting linked card that has",
"delete-linked-cards-before-this-list": "You can not delete this list before first deleting linked cards that are pointing to cards in this list"
} }

View file

@ -438,6 +438,21 @@ Cards.helpers({
return _id; return _id;
}, },
link(boardId, swimlaneId, listId) {
// TODO is there a better method to create a deepcopy?
linkCard = JSON.parse(JSON.stringify(this));
// TODO is this how it is meant to be?
linkCard.linkedId = linkCard.linkedId || linkCard._id;
linkCard.boardId = boardId;
linkCard.swimlaneId = swimlaneId;
linkCard.listId = listId;
linkCard.type = 'cardType-linkedCard';
delete linkCard._id;
// TODO shall we copy the labels for a linked card?!
delete linkCard.labelIds;
return Cards.insert(linkCard);
},
list() { list() {
return Lists.findOne(this.listId); return Lists.findOne(this.listId);
}, },