added error user feedback to grouptree, removed console logs
This commit is contained in:
parent
1cb78f7a05
commit
ac8a2e6489
|
@ -42,7 +42,6 @@ const App = () => {
|
||||||
if (token && getCurrentUser()?.mustResetPassword) {
|
if (token && getCurrentUser()?.mustResetPassword) {
|
||||||
return <ResetPassword />;
|
return <ResetPassword />;
|
||||||
}
|
}
|
||||||
console.log("lang", language);
|
|
||||||
return (
|
return (
|
||||||
<BrowserRouter>
|
<BrowserRouter>
|
||||||
<IntlProvider
|
<IntlProvider
|
||||||
|
|
|
@ -55,7 +55,6 @@ const S3CredentialsContextProvider = ({
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
console.log("catch", e);
|
|
||||||
return Promise.resolve(FetchResult.tryLater);
|
return Promise.resolve(FetchResult.tryLater);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,8 +22,6 @@ const GroupTabs = () => {
|
||||||
|
|
||||||
const id = routeMatch?.params?.id;
|
const id = routeMatch?.params?.id;
|
||||||
|
|
||||||
console.log("fuck", routeMatch?.pattern?.path, currentType);
|
|
||||||
|
|
||||||
if (id) {
|
if (id) {
|
||||||
return (
|
return (
|
||||||
<Box sx={{ width: "100%" }}>
|
<Box sx={{ width: "100%" }}>
|
||||||
|
|
|
@ -58,7 +58,6 @@ const GroupTree = () => {
|
||||||
</>
|
</>
|
||||||
}
|
}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
console.log("fuck", element.type);
|
|
||||||
setCurrentType(element.type);
|
setCurrentType(element.type);
|
||||||
}}
|
}}
|
||||||
sx={{ ".MuiTreeItem-label": { display: "flex" } }}
|
sx={{ ".MuiTreeItem-label": { display: "flex" } }}
|
||||||
|
@ -77,6 +76,9 @@ const GroupTree = () => {
|
||||||
</Grid>
|
</Grid>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
if (getError) {
|
||||||
|
return <Alert severity="error">{getError.message} </Alert>;
|
||||||
|
}
|
||||||
if (data) {
|
if (data) {
|
||||||
return (
|
return (
|
||||||
<TreeView
|
<TreeView
|
||||||
|
@ -105,8 +107,6 @@ const GroupTree = () => {
|
||||||
{renderTree(data)}
|
{renderTree(data)}
|
||||||
</TreeView>
|
</TreeView>
|
||||||
);
|
);
|
||||||
} else if (getError) {
|
|
||||||
return <Alert severity="error">{getError.message} </Alert>;
|
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
};
|
};
|
||||||
|
|
|
@ -67,7 +67,6 @@ const InstallationForm = (props: I_InstallationFormProps) => {
|
||||||
handleSubmit(values, formikValues)
|
handleSubmit(values, formikValues)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
setOpen(true);
|
setOpen(true);
|
||||||
console.log(additionalButtons, "addbuttons");
|
|
||||||
additionalButtons && additionalButtons.length > 0
|
additionalButtons && additionalButtons.length > 0
|
||||||
? fetchGroups()
|
? fetchGroups()
|
||||||
: fetchInstallations();
|
: fetchInstallations();
|
||||||
|
|
|
@ -152,7 +152,6 @@ const ScalarGraph = () => {
|
||||||
</LocalizationProvider>
|
</LocalizationProvider>
|
||||||
{visibleGraphs.map((path) => {
|
{visibleGraphs.map((path) => {
|
||||||
const isScalar = isNumeric(coordinateTimeSeries[path].y[0]);
|
const isScalar = isNumeric(coordinateTimeSeries[path].y[0]);
|
||||||
console.log("graphdata", timeSeries, coordinateTimeSeries);
|
|
||||||
|
|
||||||
const data = isScalar
|
const data = isScalar
|
||||||
? [
|
? [
|
||||||
|
|
|
@ -207,7 +207,6 @@ export interface I_CsvEntry {
|
||||||
}
|
}
|
||||||
|
|
||||||
export const parseCsv = (text: string): DataRecord => {
|
export const parseCsv = (text: string): DataRecord => {
|
||||||
console.log("parseText", text);
|
|
||||||
const y = text
|
const y = text
|
||||||
.split(/\r?\n/)
|
.split(/\r?\n/)
|
||||||
.filter((split) => split.length > 0)
|
.filter((split) => split.length > 0)
|
||||||
|
|
Loading…
Reference in New Issue