fix(CardMenu): introduce cardRichObject in CardMenu
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
This commit is contained in:
@@ -127,6 +127,7 @@ export default {
|
|||||||
'isArchived',
|
'isArchived',
|
||||||
'boards',
|
'boards',
|
||||||
'cardActions',
|
'cardActions',
|
||||||
|
'stackById',
|
||||||
]),
|
]),
|
||||||
...mapState({
|
...mapState({
|
||||||
showArchived: state => state.showArchived,
|
showArchived: state => state.showArchived,
|
||||||
@@ -155,6 +156,18 @@ export default {
|
|||||||
boardId() {
|
boardId() {
|
||||||
return this.card?.boardId ? this.card.boardId : this.$route.params.id
|
return this.card?.boardId ? this.card.boardId : this.$route.params.id
|
||||||
},
|
},
|
||||||
|
currentCard() {
|
||||||
|
return this.$store.getters.cardById(this.card.id)
|
||||||
|
},
|
||||||
|
cardRichObject() {
|
||||||
|
return {
|
||||||
|
id: '' + this.currentCard.id,
|
||||||
|
name: this.currentCard.title,
|
||||||
|
boardname: this.currentBoard.title,
|
||||||
|
stackname: this.stackById(this.currentCard.stackId)?.title,
|
||||||
|
link: window.location.protocol + '//' + window.location.host + generateUrl('/apps/deck/') + `#/board/${this.currentBoard.id}/card/${this.currentCard.id}`,
|
||||||
|
}
|
||||||
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
openCard() {
|
openCard() {
|
||||||
|
|||||||
Reference in New Issue
Block a user