export interface DataSourceType { key: string; displayName: string; status: string; type: string; isDBInstance: boolean; collections: Collection[]; } export declare type ActionsItem = { method: string; path: string; params: { name: string; value: string; }[]; headers: { name: string; value: string; }[]; body: Record; }; export interface Collection { name: string; title: string; tableName: string; timestamps: boolean; autoGenId: boolean; filterTargetKey: string; fields: Field[]; introspected: boolean; unavailableActions: any[]; actions: { get: ActionsItem; update: ActionsItem; create: ActionsItem; delete: ActionsItem; list: ActionsItem; }; } interface Field { name: string; type: string; allowNull: boolean; primaryKey: boolean; unique: boolean; autoIncrement: boolean; description?: (null | string)[]; possibleTypes?: string[]; rawType: string; interface: string; uiSchema: UiSchema; key?: string; collectionName?: string; collectionKey?: any; dataSourceKey?: string; defaultValue?: any; } interface UiSchema { type?: string; 'x-component': string; 'x-component-props'?: Xcomponentprops; 'x-validator'?: string; title: string; default?: any; enum?: any[]; } interface Xcomponentprops { style?: Style; autoSize?: AutoSize; stringMode?: boolean; step?: string; dateFormat?: string; showTime?: boolean; } interface AutoSize { minRows: number; } interface Style { width: string; } /** * 获取nocobase自定义数据源 */ export declare const getNocobaseDataSource: () => Promise; /** * 获取nocobase主数据源 */ export declare const getNocobaseMainDataSource: () => Promise; /** * 获取nocobase数据源设置 */ export declare const getNocobaseDataSourceOptions: () => Promise; /** * 创建nocobase数据 */ export declare const createNocobaseData: (params: { key: string; data: any; headers?: any; }) => Promise; /** * nocobase get数据 */ export declare const getNocobaseData: (params: { key: string; query: Record; headers?: any; }) => Promise; /** * 自定义api接口 */ export declare const customApi: (url: string, data: Record, options: { method: 'GET' | 'POST' | 'PUT' | 'DELETE'; baseUrl?: string | undefined; headers?: { name: string; value: any; }[] | undefined; params?: { name: string; value: any; }[] | undefined; body?: Record | undefined; dataSourceKey?: string | undefined; }) => Promise; /** * 更新nocobase数据 */ export declare const updateNocobaseData: (params: { key: string; data: any; headers?: any; query?: Record | undefined; }) => Promise; /** * 获取nocobase数据列表 */ export declare const getNocobaseDataList: (allParams: { key: string; params: { page: number; pageSize: number; }; headers?: any; }) => Promise; /** * 删除nocobase数据 */ export declare const deleteNocobaseData: (key: string, id: string, headers?: any) => Promise; /** * 获取formSettingMeta数据 * @param params 请求参数 * @param params.sectionCodes 配置段代码数组,如 ['payment'] * @param params.businessCode 业务代码 * @param params.channelCode 渠道代码 * @param params.isBoard 是否包含board_code参数 * @returns Promise 返回设置元数据 */ export declare const getFormSettingMetaData: (params: { sectionCodes: string[]; scope: string; target?: string | undefined; }) => Promise; /** * 更新租户设置数据 * @param params 请求参数 * @param params.businessCode 业务代码 * @param params.channelCode 渠道代码 * @param params.boardCode 板块代码 * @param params.data 要更新的数据对象,如 {"order.prefix":"","order.suffix":"","payment.number":""} * @returns Promise 返回更新结果 */ export declare const updateTenantSetting: (params: { scope: string; target?: string | undefined; data: Record; }) => Promise; export declare type DeviceSettingScene = 'template' | 'profile' | 'instance'; /** * 获取设备设置元数据(POST 类型 GET) * @param params.scene 场景,默认 template * @param params.sceneRequestId URL 中 {id} 占位符的实际取值 * @param params.items 需要获取的字段列表,例如 ['order.name', 'order.id'] */ export declare const getDeviceSettingMetaData: (params: { scene?: DeviceSettingScene | undefined; sceneRequestId: string; items: string[]; }) => Promise; /** * 更新设备设置数据 * @param params.scene 场景,默认 template * @param params.sceneRequestId URL 中 {id} 占位符的实际取值 * @param params.data 需要更新的字段值对象 */ export declare const updateDeviceSetting: (params: { scene?: DeviceSettingScene | undefined; sceneRequestId: string; data: Record; }) => Promise; export {};