This repository has been archived on 2024-02-08. You can view files and clone it, but cannot push or open issues or pull requests.
frontend/src/helpers/savedFilter.ts

10 lines
249 B
TypeScript
Raw Normal View History

2022-09-06 09:36:01 +00:00
import type {IList} from '@/modelTypes/IList'
2022-07-20 22:42:36 +00:00
export function getSavedFilterIdFromListId(listId: IList['id']) {
let filterId = listId * -1 - 1
// FilterIds from listIds are always positive
if (filterId < 0) {
filterId = 0
}
return filterId
}