You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

46 lines
942 B

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. import type Item from "./item";
  2. import type { TaskWithProject } from "./task";
  3. export default interface Log {
  4. id: string
  5. taskId: string
  6. itemId: string
  7. itemAmount: number
  8. secondaryItemId?: string
  9. secondaryItemAmount: number
  10. loggedTime: string
  11. description: string
  12. }
  13. export interface LogFilter {
  14. minTime?: Date
  15. maxTime?: Date
  16. itemIds?: string[]
  17. projectIds?: string[]
  18. projectGroupIds?: string[]
  19. }
  20. export interface LogResult extends Log {
  21. task: TaskWithProject
  22. item: Item
  23. secondaryItem?: Item
  24. itemCounted?: boolean
  25. secondaryItemCounted?: boolean
  26. }
  27. export interface LogInput {
  28. taskId: string
  29. loggedTime?: string
  30. description: string
  31. itemAmount: number
  32. secondaryItemId?: string
  33. secondaryItemAmount?: number
  34. }
  35. export interface LogUpdate {
  36. loggedTime?: string
  37. description?: string
  38. itemAmount?: number
  39. secondaryItemId?: string
  40. secondaryItemAmount?: number
  41. clearSecondaryItemId?: boolean
  42. }