Skip to content

Commit

Permalink
feat(orga): WIP
Browse files Browse the repository at this point in the history
Co-authored-by: Vincent Hardouin <[email protected]>
  • Loading branch information
Alexandre-Monney and VincentHardouin committed Dec 13, 2024
1 parent 9c35049 commit f73b94d
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions orga/app/components/statistics/index.gjs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,22 @@ export default class Statistics extends Component {
return this.analysisByTubes.slice(start, end);
}

get analysisByDomains() {
return this.analysisByTubes.reduce((acc, line) => {
const domain = line.domaine;
if (acc[domain]) {
acc[domain].push(line);
} else {
acc[domain] = [line];
}
return acc;
}, {});
}

get domainsName() {
return Object.keys(this.analysisByDomains);
}

<template>
<div class="statistics-page__header">
<h1 class="page-title">{{t "pages.statistics.title"}}</h1>
Expand Down

0 comments on commit f73b94d

Please sign in to comment.