mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-03 17:55:21 +03:00
Fix errors
This commit is contained in:
parent
67fd039b95
commit
3b3382d6d0
@ -82,12 +82,17 @@ export default function System() {
|
|||||||
const response = axios.get('vainfo');
|
const response = axios.get('vainfo');
|
||||||
|
|
||||||
if (response.status === 200) {
|
if (response.status === 200) {
|
||||||
setState({ ...state, showVainfo: true, vainfo: JSON.stringify(resonse.data, null, 2) });
|
setState({ ...state, showVainfo: true, vainfo: JSON.stringify(response.data, null, 2) });
|
||||||
} else {
|
} else {
|
||||||
setState({ ...state, showVainfo: true, vainfo: 'There was an error getting the vainfo output.' });
|
setState({ ...state, showVainfo: true, vainfo: 'There was an error getting the vainfo output.' });
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const onCopyVainfo = async () => {
|
||||||
|
await window.navigator.clipboard.writeText(JSON.stringify(state.vaifp, null, 2));
|
||||||
|
setState({ ...state, vainfo: '', showVainfo: false });
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="space-y-4 p-2 px-4">
|
<div className="space-y-4 p-2 px-4">
|
||||||
<Heading>
|
<Heading>
|
||||||
@ -179,8 +184,8 @@ export default function System() {
|
|||||||
) : (
|
) : (
|
||||||
<div data-testid="gpus" className="grid grid-cols-1 3xl:grid-cols-3 md:grid-cols-2 gap-4">
|
<div data-testid="gpus" className="grid grid-cols-1 3xl:grid-cols-3 md:grid-cols-2 gap-4">
|
||||||
{gpuNames.map((gpu) => (
|
{gpuNames.map((gpu) => (
|
||||||
<div key={detector} className="dark:bg-gray-800 shadow-md hover:shadow-lg rounded-lg transition-shadow">
|
<div key={gpu} className="dark:bg-gray-800 shadow-md hover:shadow-lg rounded-lg transition-shadow">
|
||||||
<div className="text-lg flex justify-between p-4">{detector}</div>
|
<div className="text-lg flex justify-between p-4">{gpu}</div>
|
||||||
<div className="p-2">
|
<div className="p-2">
|
||||||
<Table className="w-full">
|
<Table className="w-full">
|
||||||
<Thead>
|
<Thead>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user