Added first round of analytics and event tracking BOD-190

This commit is contained in:
Patrick Fic
2020-07-17 08:27:28 -07:00
parent 3f0394760a
commit a54a85b96c
73 changed files with 433 additions and 208 deletions

View File

@@ -1,6 +1,7 @@
import { Button, Col, Collapse, Result, Row, Space } from "antd";
import React from "react";
import { withTranslation } from "react-i18next";
import { Result, Button, Collapse, Row, Col, Space } from "antd";
import { logImEXEvent } from "../../firebase/firebase.utils";
class ErrorBoundary extends React.Component {
constructor() {
@@ -24,28 +25,29 @@ class ErrorBoundary extends React.Component {
render() {
const { t } = this.props;
const { error, info } = this.state;
if (this.state.hasErrored === true) {
logImEXEvent("error_boundary_rendered", { error, info });
return (
<div>
<Result
status="500"
status='500'
title={t("general.labels.exceptiontitle")}
subTitle={t("general.messages.exception")}
extra={
<Space>
<Button
type="primary"
type='primary'
onClick={() => {
window.location.reload();
}}
>
}}>
{t("general.actions.refresh")}
</Button>
<Button
onClick={() => {
alert("Not implemented yet.");
}}
>
}}>
{t("general.actions.submitticket")}
</Button>
</Space>