diff --git a/src/components/Discover/Filter/ActAndSeq.vue b/src/components/Discover/Filter/ActAndSeq.vue index abed043..14599d8 100644 --- a/src/components/Discover/Filter/ActAndSeq.vue +++ b/src/components/Discover/Filter/ActAndSeq.vue @@ -78,6 +78,13 @@ export default { lastItemIndex: null, } }, + computed: { + data: function() { + // TODO Activity List 的 dblclick, drag & drop 要改假刪除 + // Activity List 要排序 + return this.data.sort((x, y) => y.occurrences - x.occurrences); + } + }, watch: { listSeq(newval){ this.listSequence = newval; @@ -129,8 +136,6 @@ export default { evt.oldIndex !== listIndex ? lastChild.style.display = '' : null; // reset: 拖曳最後一個元素時,倒數第二的元素的箭頭要隱藏 this.lastItemIndex = null; - // Activity List 要排序 - this.data.sort((x, y) => y.occurrences - x.occurrences); this.$emit('update:listSeq', this.listSequence); },