@nocobase/client 2.2.0-alpha.1 → 2.2.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,36 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import type { IResource } from '@nocobase/sdk';
10
+ import { type ParseFilterOptions } from '@nocobase/utils/client';
11
+ type LocalVariable = {
12
+ name: string;
13
+ ctx: any;
14
+ };
15
+ export declare function parseFilterParam(filter: any, scope?: ParseFilterOptions): Promise<any>;
16
+ export declare function collectRuntimeVariables(globalVars?: Record<string, any>, localVariables?: LocalVariable[]): {
17
+ [x: string]: any;
18
+ };
19
+ export declare function createParseFilterScope(options: {
20
+ vars: Record<string, any>;
21
+ currentRole?: string;
22
+ timezone?: string;
23
+ now?: string;
24
+ getField: (path: string) => any;
25
+ }): ParseFilterOptions;
26
+ export declare function createParsedResource(resource: IResource, options: {
27
+ resourceName?: string;
28
+ getScope: () => ParseFilterOptions | Promise<ParseFilterOptions>;
29
+ }): IResource;
30
+ export declare function createParsedRequestService(options: {
31
+ request?: any;
32
+ resourceName?: string;
33
+ getScope: () => ParseFilterOptions | Promise<ParseFilterOptions>;
34
+ execute: (request: any) => Promise<any>;
35
+ }): (params?: Record<string, any>) => Promise<any>;
36
+ export {};