Skip to content

Commit

Permalink
Stats Dashboard - Set end day time (#533)
Browse files Browse the repository at this point in the history
* end date was not setting time; removing log

* internal ui update
  • Loading branch information
justinorringer authored Sep 17, 2024
1 parent 1852a23 commit 2af7050
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 19 deletions.
7 changes: 3 additions & 4 deletions internal-ui/src/components/DashboardComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,6 @@ export const DashboardComponent = () => {
});
const internal = session.messages.filter(isTypeMessageSlot).filter(msg => msg.data.name === 'is_internal').some(msg => msg.data.value);

if (toggleState.external) {
console.log(internal);
}
if ((toggleState.internal && !internal)
|| (toggleState.external && internal)
|| (toggleState.orgAdmins && !orgAdmin)
Expand Down Expand Up @@ -242,7 +239,9 @@ export const DashboardComponent = () => {
setIsLoading(true);
const fetchMessages = async () => {
const start = Math.floor(new Date(startDate.setHours(0, 0, 0, 0)).getTime() / 1000);
const end = Math.floor(endDate.getTime() / 1000);
const endDateEndOfDay = new Date(endDate);
endDateEndOfDay.setHours(23, 59, 59, 999);
const end = Math.floor(endDateEndOfDay.getTime() / 1000);

const sessionsInRange = await getSessionsInRange(undefined, start, end);
setSessions(sessionsInRange);
Expand Down

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion internal/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Astro internal UI</title>
<script type="module" crossorigin src="./assets/index-BosGIk_9.js"></script>
<script type="module" crossorigin src="./assets/index-CGN9bkrT.js"></script>
<link rel="stylesheet" crossorigin href="./assets/index-BZiFqsU9.css">
</head>
<body>
Expand Down

0 comments on commit 2af7050

Please sign in to comment.