Merge remote-tracking branch 'origin/main' into #58-Alle-Pitchbooks-Ansicht

pull/67/head
s8613 2025-06-15 15:20:29 +02:00
commit 4e56cac92e
2 changed files with 68 additions and 54 deletions

View File

@ -17,4 +17,4 @@ COPY . .
ENV PYTHONUNBUFFERED=1 ENV PYTHONUNBUFFERED=1
CMD ["gunicorn", "--timeout", "600", "--workers", "2", "--bind", "0.0.0.0:5000", "app:app"] CMD ["gunicorn", "--timeout", "600", "--workers", "1", "--bind", "0.0.0.0:5000", "app:app"]

View File

@ -228,61 +228,75 @@ export default function KennzahlenTable({
</Box> </Box>
</Tooltip> </Tooltip>
) : ( ) : (
<Box <Tooltip
sx={{ title={hasNoValue ?
border: `2px solid ${borderColor}`, <>
borderRadius: 1, <b>Problem</b>
padding: "4px 8px", <br />
display: "flex", Es wurden keine Kennzahlen gefunden. Bitte ergänzen!
alignItems: "center", </> : ""
justifyContent: "space-between", }
width: "100%", placement="bottom"
cursor: "text", arrow
}}
> >
<Box <span>
sx={{ <Box
display: "flex", sx={{
alignItems: "center", border: `2px solid ${borderColor}`,
gap: 1, borderRadius: 1,
width: "100%", padding: "4px 8px",
}} display: "flex",
> alignItems: "center",
{hasNoValue && ( justifyContent: "space-between",
<ErrorOutlineIcon fontSize="small" color="error" /> width: "100%",
)} cursor: "text",
{editingIndex === row.setting.name ? ( }}
<TextField >
value={editValue} <Box
onChange={(e) => setEditValue(e.target.value)} sx={{
onKeyDown={(e) => display: "flex",
handleKeyPress(e, row.setting.name) alignItems: "center",
} gap: 1,
onBlur={() => handleSave(row.setting.name)} width: "100%",
autoFocus }}
size="small" >
fullWidth {hasNoValue && (
variant="standard" <ErrorOutlineIcon fontSize="small" color="error" />
sx={{ margin: "-8px 0" }} )}
{editingIndex === row.setting.name ? (
<TextField
value={editValue}
onChange={(e) => setEditValue(e.target.value)}
onKeyDown={(e) =>
handleKeyPress(e, row.setting.name)
}
onBlur={() => handleSave(row.setting.name)}
autoFocus
size="small"
fullWidth
variant="standard"
sx={{ margin: "-8px 0" }}
/>
) : (
<span>
{row.extractedValues.at(0)?.entity || "—"}
</span>
)}
</Box>
<EditIcon
fontSize="small"
sx={{ color: "#555", cursor: "pointer" }}
onClick={(e) => {
e.stopPropagation();
startEditing(
row.extractedValues.at(0)?.entity || "",
row.setting.name,
);
}}
/> />
) : ( </Box>
<span> </span>
{row.extractedValues.at(0)?.entity || "—"} </Tooltip>
</span>
)}
</Box>
<EditIcon
fontSize="small"
sx={{ color: "#555", cursor: "pointer" }}
onClick={(e) => {
e.stopPropagation();
startEditing(
row.extractedValues.at(0)?.entity || "",
row.setting.name,
);
}}
/>
</Box>
)} )}
</TableCell> </TableCell>
<TableCell align="center"> <TableCell align="center">