UNPKG

ncrudify

Version:

Configurable CRUD module for NestJS and Mongoose.

151 lines (150 loc) 4.8 kB
import { ICrudify } from "./interface/crudify.interface"; export declare namespace CrudifyRoutes { function routes(options: ICrudify): ({ methodName: "findAll"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: ObjectConstructor; }[]; decorators: MethodDecorator[]; } | { methodName: "count"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: never[]; decorators: MethodDecorator[]; } | { methodName: "restore"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "findOne"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "create"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: import("@nestjs/common").Type<any>; }[]; decorators: MethodDecorator[]; } | { methodName: "createBulk"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: import("@nestjs/common").Type<any>[]; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "updateBulk"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: ObjectConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "restoreBulk"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: ObjectConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "update"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: ({ index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; } | { index: number; decorator: ParameterDecorator; type: import("@nestjs/common").Type<any>; description?: undefined; })[]; decorators: MethodDecorator[]; } | { methodName: "put"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: ({ index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; } | { index: number; decorator: ParameterDecorator; type: import("@nestjs/common").Type<any>; description?: undefined; })[]; decorators: MethodDecorator[]; } | { methodName: "deleteBulk"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: ObjectConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "delete"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; }[]; decorators: MethodDecorator[]; } | { methodName: "deleteSoft"; httpMethod: (path?: string | string[]) => MethodDecorator; path: string; parameters: { index: number; decorator: ParameterDecorator; type: StringConstructor; description: string; }[]; decorators: MethodDecorator[]; })[]; }