Compare commits
10 Commits
v2.1.3
...
126-all-lo
| Author | SHA1 | Date | |
|---|---|---|---|
| 075508413e | |||
| 56b07d64a9 | |||
| 928a4dae43 | |||
| a7a9f01fd9 | |||
| e345898341 | |||
| a6af3c2229 | |||
| a367b517db | |||
| b8f708fd6d | |||
| 1c46f58afc | |||
| fa7a39e48a |
@@ -63,7 +63,7 @@ export class LogInterceptor implements NestInterceptor {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
entities: logs,
|
entities: logs,
|
||||||
total: data.total,
|
total: logs.length,
|
||||||
hasNextPage: false
|
hasNextPage: false
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -413,7 +413,7 @@ const Logbook: React.FC<unknown> = () => {
|
|||||||
setColumnVisibility(columnVisibility)
|
setColumnVisibility(columnVisibility)
|
||||||
dispatch({ type: 'SET_ENTRIES', payload: { entries: entries, totalEntries: response.data.total }});
|
dispatch({ type: 'SET_ENTRIES', payload: { entries: entries, totalEntries: response.data.total }});
|
||||||
|
|
||||||
if (!isUserLoggedIn && response.data.length >= 5) {
|
if (!isUserLoggedIn && response.data.entities.length >= 5) {
|
||||||
dispatch({ type: 'SET_ALERT', payload: { severity: 'info', message: 'A limited number of log entries displayed. Sign in to view all log entries.'}})
|
dispatch({ type: 'SET_ALERT', payload: { severity: 'info', message: 'A limited number of log entries displayed. Sign in to view all log entries.'}})
|
||||||
} else {
|
} else {
|
||||||
dispatch({ type: 'SET_ALERT', payload: undefined})
|
dispatch({ type: 'SET_ALERT', payload: undefined})
|
||||||
@@ -528,8 +528,8 @@ const Logbook: React.FC<unknown> = () => {
|
|||||||
}, [state.totalEntries, state.pagination?.pageSize])
|
}, [state.totalEntries, state.pagination?.pageSize])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
console.log(state.pagination)
|
console.log(state.alert)
|
||||||
}, [state.pagination])
|
}, [state.alert])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@@ -554,7 +554,7 @@ const Logbook: React.FC<unknown> = () => {
|
|||||||
onClose={() =>
|
onClose={() =>
|
||||||
dispatch({ type: 'SET_ALERT', payload: undefined })
|
dispatch({ type: 'SET_ALERT', payload: undefined })
|
||||||
}
|
}
|
||||||
severity={'info'}
|
severity={state.alert.severity}
|
||||||
>
|
>
|
||||||
{state.alert.message}
|
{state.alert.message}
|
||||||
</Alert>
|
</Alert>
|
||||||
|
|||||||
Reference in New Issue
Block a user