我有一个实体
@Table({tableName: 'EducationEntity'})
export class EducationEntity extends Model<EducationEntity> {
}
我正在尝试做:EducationEntity.build(plainObject as any);
从普通对象构建模型。
我遇到了错误:
src/research/research.service.ts:165:51 - error TS2684: The 'this' context of type 'typeof EducationEntity' is not assignable to method's 'this' of type '(new () => EducationEntity) & typeof Model'.
Type 'typeof EducationEntity' is not assignable to type 'typeof Model'.
The types returned by 'init(...)' are incompatible between these types.
Type 'void' is not assignable to type 'Model<any, any>'.
那是什么,EducationEntity是一个模型?
Thakns