mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-07-02 03:02:19 +08:00
fix: register models type error
This commit is contained in:
parent
42294a4ce5
commit
82c8ff766d
@ -110,14 +110,16 @@ export type CreateSubModelOptions = CreateModelOptions | FlowModel;
|
||||
/**
|
||||
* Constructor for model classes.
|
||||
*/
|
||||
export type ModelConstructor<T extends FlowModel = FlowModel> = new (options: {
|
||||
export type ModelConstructor<T extends FlowModel = FlowModel> = new (
|
||||
options: FlowModelOptions & {
|
||||
uid: string;
|
||||
props?: IModelComponentProps;
|
||||
stepParams?: StepParams;
|
||||
meta?: FlowModelMeta;
|
||||
subModels?: Record<string, CreateSubModelOptions | CreateSubModelOptions[]>;
|
||||
[key: string]: any; // Allow additional options
|
||||
}) => T;
|
||||
},
|
||||
) => T;
|
||||
|
||||
/**
|
||||
* Defines a reusable action with generic model type support.
|
||||
@ -292,7 +294,7 @@ export interface FlowModelOptions<Structure extends { parent?: any; subModels?:
|
||||
use?: string;
|
||||
async?: boolean; // 是否异步加载模型
|
||||
props?: IModelComponentProps;
|
||||
stepParams?: Record<string, any>;
|
||||
stepParams?: StepParams;
|
||||
subModels?: Structure['subModels'];
|
||||
flowEngine?: FlowEngine;
|
||||
parentId?: string;
|
||||
|
Loading…
x
Reference in New Issue
Block a user