Skip to content

Commit

Permalink
Merge pull request #28 from gapitio/report
Browse files Browse the repository at this point in the history
feat: add export of top n offenders, flapping and standing
  • Loading branch information
sbgap committed Aug 28, 2024
2 parents b6abab7 + a27bfd0 commit 8656c17
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/views/Reports.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,14 @@
/>
</v-flex>

<v-btn
flat
:href="export_reports()"
download
>
Export
</v-btn>

<v-btn
flat
icon
Expand Down Expand Up @@ -72,6 +80,13 @@ export default {
this.$store.dispatch('reports/setPageSize', value)
}
},
},
methods: {
export_reports () {
const pagination = this.$store.state.reports.pagination
return `${this.$config.endpoint}/alerts/reports/download?page-size=${pagination.rowsPerPage}`
}
}
}
</script>

0 comments on commit 8656c17

Please sign in to comment.