import { Project } from "../../types/project.types.js";
import { ResponseWithSession } from "../../middlewares/sessionAuth.middleware.js";
import { FiltersAndPagination } from "./getFiltersAndPaginationFromBody.js";
import * as mongoose93 from "mongoose";
import { RootFilterQuery } from "mongoose";
import { Request } from "express";

//#region src/utils/filtersAndPagination/getProjectFiltersAndPagination.d.ts
type ProjectFiltersParams = {
  ids?: string | string[];
  name?: string;
  search?: string;
  organizationId?: string;
  membersIds?: string[];
  sortBy?: string;
  sortOrder?: string;
  /**
   * For admin users, if true, will fetch all projects without filtering by organization
   */
  fetchAll?: 'true' | 'false';
};
type ProjectFilters = RootFilterQuery<Project>;
/**
 * Extracts filters and pagination information from the request body.
 * @param req - Express request object.
 * @returns Object containing filters, page, pageSize, and getNumberOfPages functions.
 */
declare const getProjectFiltersAndPagination: (req: Request<FiltersAndPagination<ProjectFiltersParams>>, res: ResponseWithSession) => {
  page: number;
  skip: number;
  pageSize: number;
  getNumberOfPages: (totalItems: number) => number;
  filters: mongoose93.FilterQuery<Project>;
  sortOptions: Record<string, 1 | -1>;
};
//#endregion
export { ProjectFilters, ProjectFiltersParams, getProjectFiltersAndPagination };
//# sourceMappingURL=getProjectFiltersAndPagination.d.ts.map