All files / app/src/entities/change-log/lib constants.ts

100% Statements 15/15
100% Branches 0/0
100% Functions 0/0
100% Lines 15/15

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23      1x 1x   1x 1x   1x   1x 1x   1x 1x 1x 1x 1x 1x 1x 1x  
import { BaseFilter } from '@/shared/@types'
import { Nullable } from '@tmk/ui-kit'
 
export const CHANGE_LOG_SINGLE_TARGET = '/parameter_histories'
export const CHANGE_LOG_SINGLE_PRIMARY_KEY = [CHANGE_LOG_SINGLE_TARGET, 'get-change-log']
 
export const CHANGE_LOG_FILE_TARGET = '/files/:id'
export const CHANGE_LOG_FILE_PRIMARY_KEY = [CHANGE_LOG_FILE_TARGET, 'get-change-log-file']
 
export const CHANGE_LOG_EXPORT_TARGET = '/parameter_histories_xlsx'
 
export const DEFAULT_CHANGELOG_COLLECTION_ORDER = '{"order[loggedAt]":"desc"}'
export const ASC_CHANGELOG_COLLECTION_ORDER = '{"order[loggedAt]":"asc"}'
 
export const CHANGE_LOG_COLLECTION_FILTERS = {
  page: 1,
  objectId: null as Nullable<string>,
  sort: DEFAULT_CHANGELOG_COLLECTION_ORDER as Nullable<string>,
  username: null as Nullable<BaseFilter[]>,
  action: null as null as Nullable<BaseFilter[]>,
  date: null as Nullable<string[]>,
}