Fix ESLint issues
This commit is contained in:
@@ -133,19 +133,19 @@ export function SelectMovementWidget(p: {
|
||||
|
||||
<div style={{ flex: 1 }}>
|
||||
<AsyncWidget
|
||||
loadKey={
|
||||
loadKey.current + "/" + accountId + "/" + JSON.stringify(filters)
|
||||
}
|
||||
loadKey={`${loadKey.current}/${accountId}/${JSON.stringify(
|
||||
filters
|
||||
)}`}
|
||||
load={load}
|
||||
errMsg="Failed to load the list of movements!"
|
||||
build={() => {
|
||||
if (list === null)
|
||||
if (list === undefined)
|
||||
return (
|
||||
<Typography style={{ textAlign: "center", padding: "20px" }}>
|
||||
Select an account to begin research.
|
||||
</Typography>
|
||||
);
|
||||
if (list?.length === 0)
|
||||
if (list.length === 0)
|
||||
return (
|
||||
<Typography style={{ textAlign: "center", padding: "20px" }}>
|
||||
No result.
|
||||
@@ -154,11 +154,13 @@ export function SelectMovementWidget(p: {
|
||||
|
||||
return (
|
||||
<>
|
||||
{list?.map((entry) => (
|
||||
<ListItem>
|
||||
{list.map((entry) => (
|
||||
<ListItem key={entry.id}>
|
||||
<ListItemButton
|
||||
selected={entry.id === p.value}
|
||||
onClick={() => p.onChange(entry)}
|
||||
onClick={() => {
|
||||
p.onChange(entry);
|
||||
}}
|
||||
>
|
||||
<MovementWidget movement={entry} />
|
||||
</ListItemButton>
|
||||
|
Reference in New Issue
Block a user