P5 7619 refactor products to return list (#11)

This commit is contained in:
Niklas Fondberg
2021-08-20 08:16:01 +02:00
committed by GitHub
parent 234996abfd
commit 964a904f42
15 changed files with 235 additions and 92 deletions
+15 -5
View File
@@ -1,16 +1,26 @@
export type Maybe<T> = T | undefined;
export interface PaginationInput {
limit: number;
offset?: number;
}
export interface DateInput {
from: Date;
to: Date;
}
export interface GeneralInput {
export interface DateFilterInput {
dates: DateInput;
limit: number;
offset: number;
}
export interface FilterInput {
filter: GeneralInput;
export interface GeneralInput {
pagination: PaginationInput;
filter?: DateFilterInput;
}
export interface PaginationResult {
total: Promise<number> | number;
offset: number;
limit: number;
}