UNPKG

728 BTypeScriptView Raw
1import { ScopeTableOptions } from './scope-table-options';
2import { ScopeFindOptions } from './scope-find-options';
3import { FindOptions } from 'sequelize';
4export interface ScopeOptions<TCreationAttributes, TModelAttributes> extends ScopeTableOptions<TCreationAttributes, TModelAttributes> {
5 defaultScope?: ScopeFindOptions<TCreationAttributes, TModelAttributes>;
6}
7export interface ScopeOptionsGetters {
8 getDefaultScope?: DefaultScopeGetter;
9 getScopes?: ScopesOptionsGetter;
10}
11export declare type DefaultScopeGetter = () => FindOptions;
12export declare type ScopesOptionsGetter = () => {
13 [sopeName: string]: ScopesOptions;
14};
15export declare type ScopesOptions = FindOptions | ((...args: any[]) => FindOptions);
16
\No newline at end of file