bin card, no svg yet
This commit is contained in:
parent
a0eabf50c6
commit
7edba7e25b
4 changed files with 848 additions and 153 deletions
|
|
@ -45,7 +45,7 @@ import {
|
|||
// import AddBinFab from "bin/AddBinFab";
|
||||
// import BinsFansStatusTable from "bin/BinFansStatusTable";
|
||||
// import BinSettings from "bin/BinSettings";
|
||||
// import BinsList from "bin/BinsList";
|
||||
import BinsList from "bin/BinsList";
|
||||
// import BinYard from "bin/BinYard";
|
||||
import BinInventoryChart, { GrainAmount } from "charts/BinInventoryChart";
|
||||
import BinUtilizationChart from "charts/BinUtilizationChart";
|
||||
|
|
@ -72,7 +72,7 @@ import React, { SetStateAction, useCallback, useEffect, useState } from "react";
|
|||
import { getGrainUnit, stringToMaterialColour } from "utils";
|
||||
//import InfiniteScroll from "react-infinite-scroller";
|
||||
import PageContainer from "./PageContainer";
|
||||
// import ObjectTable from "objects/ObjectTable";
|
||||
import ObjectTable from "objects/ObjectTable";
|
||||
import ResponsiveDialog from "common/ResponsiveDialog";
|
||||
import { describeMeasurement } from "pbHelpers/MeasurementDescriber";
|
||||
import { green, yellow } from "@mui/material/colors";
|
||||
|
|
@ -584,25 +584,24 @@ export default function Bins(props: Props) {
|
|||
|
||||
if (binView === "list") {
|
||||
return (
|
||||
// <ObjectTable
|
||||
// startingObject={pond.ObjectType.OBJECT_TYPE_BIN}
|
||||
// preLoadedData={paginatedBins.bins}
|
||||
// rowClickFunction={data => {
|
||||
// let bin = data as Bin;
|
||||
// let path = "/bins/" + bin.key();
|
||||
// navigate(path, { state: { bin: bin }});
|
||||
// }}
|
||||
// customButtons={[
|
||||
// {
|
||||
// label: "Set High Temp Notifications",
|
||||
// function: objects => {
|
||||
// setAlertBins(objects as Bin[]);
|
||||
// setOpenAddAlerts(true);
|
||||
// }
|
||||
// }
|
||||
// ]}
|
||||
// />
|
||||
null
|
||||
<ObjectTable
|
||||
startingObject={pond.ObjectType.OBJECT_TYPE_BIN}
|
||||
preLoadedData={paginatedBins.bins}
|
||||
rowClickFunction={data => {
|
||||
let bin = data as Bin;
|
||||
let path = "/bins/" + bin.key();
|
||||
navigate(path, { state: { bin: bin }});
|
||||
}}
|
||||
customButtons={[
|
||||
{
|
||||
label: "Set High Temp Notifications",
|
||||
function: objects => {
|
||||
setAlertBins(objects as Bin[]);
|
||||
setOpenAddAlerts(true);
|
||||
}
|
||||
}
|
||||
]}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -615,7 +614,7 @@ export default function Bins(props: Props) {
|
|||
<Divider />
|
||||
</Grid>
|
||||
<Grid item xs={12}>
|
||||
{/*<BinsList
|
||||
<BinsList
|
||||
valDisplay={cardValDisplay}
|
||||
gridView={binView === "grid"}
|
||||
bins={grainBins}
|
||||
|
|
@ -628,7 +627,7 @@ export default function Bins(props: Props) {
|
|||
setScrollTranslations({ ...scrollTranslations, bins: newTranslation });
|
||||
}
|
||||
}}
|
||||
/>*/}
|
||||
/>
|
||||
</Grid>
|
||||
</React.Fragment>
|
||||
)}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue