Skip to content

Commit

Permalink
fix: openOnly doesn't only mean the stage should be open, but also me…
Browse files Browse the repository at this point in the history
…an the item must be droppable now
  • Loading branch information
AlvISsReimu committed Nov 8, 2024
1 parent 2432923 commit 796ed9d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/stats/DataTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,7 @@ export default {
filteredData() {
let data = this.items
if (this.type === 'item') {
if (this.dataTable.onlyOpen) data = data.filter(el => existUtils.existence(el.stage, true))
if (this.dataTable.onlyOpen) data = data.filter(el => existUtils.existence(el.stage, true) && (el.end === null || el.end > Date.now()))
if (!this.dataTable.showPermanent) data = data.filter(el => el.stage.stageType !== 'MAIN' && el.stage.stageType !== 'SUB' && el.stage.stageType !== 'DAILY')
if (!this.dataTable.showActivity) data = data.filter(el => el.stage.stageType !== 'ACTIVITY')
} else if (this.type === 'stage') {
Expand Down
4 changes: 2 additions & 2 deletions src/components/stats/PreviewItemCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ export default {
const data = get.statistics.byItemId(this.itemId)
// filter out stages that have too less samples
.filter(el => el.times > 100)
// only open stages
.filter(el => existUtils.existence(el.stage, true))
// only open stages, and item must still be droppable now
.filter(el => existUtils.existence(el.stage, true) && (el.end === null || el.end > Date.now()))
.sort((a, b) => b.percentage - a.percentage)
Expand Down

0 comments on commit 796ed9d

Please sign in to comment.