diff --git a/node_api/eslint.config.js b/node_api/eslint.config.js index 10b1a6b..e7176e1 100644 --- a/node_api/eslint.config.js +++ b/node_api/eslint.config.js @@ -72,6 +72,8 @@ export default defineConfig( '@typescript-eslint/consistent-type-imports': 'off', // 允许未使用的变量 (MikroORM 的特殊属性) '@typescript-eslint/no-unused-vars': 'off', + // 允许类型构成排序 + '@typescript-eslint/sort-type-constituents': 'off', }, }, { diff --git a/node_api/src/entities/IcrBookarticle.ts b/node_api/src/entities/IcrBookarticle.ts new file mode 100644 index 0000000..8c60c98 --- /dev/null +++ b/node_api/src/entities/IcrBookarticle.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookarticle { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + Name?: string; + Type!: number; + WordCount!: number; + Conclusion?: any; + Guide?: string; + Tutelage?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrBookarticleSchema = defineEntity({ + class: IcrBookarticle, + comment: '书籍文章', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id'), + Name: p.string().name('Name').nullable().comment('文章名称'), + Type: p.integer().name('Type').comment('文章类型'), + WordCount: p.integer().name('WordCount').comment('字数'), + Conclusion: p.json().name('Conclusion').nullable().comment('结论Json'), + Guide: p.string().name('Guide').nullable().comment('导读'), + Tutelage: p.string().name('Tutelage').nullable().comment('指导'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrBookassigntask.ts b/node_api/src/entities/IcrBookassigntask.ts new file mode 100644 index 0000000..d5934c1 --- /dev/null +++ b/node_api/src/entities/IcrBookassigntask.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookassigntask { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + BookPageId!: IType; + BookPageQuestionId!: IType; + OperatorId?: IType; + OperatorType!: number; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrBookassigntaskSchema = defineEntity({ + class: IcrBookassigntask, + comment: '录入/审查', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').comment('书页id'), + BookPageQuestionId: p.bigint().name('BookPageQuestionId').columnType('bigint').comment('书页id'), + OperatorId: p.bigint().name('OperatorId').columnType('bigint').nullable().comment('操作人Id'), + OperatorType: p.integer().name('OperatorType').comment('操作人类型(1-录入 2-审核 3-补充)'), + Status: p.integer().name('Status').comment('状态(0-未完成 1完成)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrBookcatalog.ts b/node_api/src/entities/IcrBookcatalog.ts new file mode 100644 index 0000000..b00e857 --- /dev/null +++ b/node_api/src/entities/IcrBookcatalog.ts @@ -0,0 +1,37 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookcatalog { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + Name?: string; + Type!: number; + ParentId!: IType; + Level!: number; + Sort!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrBookcatalogSchema = defineEntity({ + class: IcrBookcatalog, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_BookCatalog_01'), + Name: p.string().name('Name').nullable().comment('目录名称'), + Type: p.integer().name('Type').comment('类别:0-单元 1-页'), + ParentId: p.bigint().name('ParentId').columnType('bigint').comment('父Id;无限级别'), + Level: p.integer().name('Level').comment('等级'), + Sort: p.integer().name('Sort').comment('排序'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrBookcategory.ts b/node_api/src/entities/IcrBookcategory.ts new file mode 100644 index 0000000..1b5f87b --- /dev/null +++ b/node_api/src/entities/IcrBookcategory.ts @@ -0,0 +1,31 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookcategory { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Enable!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Count: Opt & number = 0; +} + +export const IcrBookcategorySchema = defineEntity({ + class: IcrBookcategory, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('类别名称'), + Enable: p.array().name('Enable').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Count: p.integer().name('Count').comment('数量'), + }, +}); diff --git a/node_api/src/entities/IcrBookpage.ts b/node_api/src/entities/IcrBookpage.ts new file mode 100644 index 0000000..3ac7d79 --- /dev/null +++ b/node_api/src/entities/IcrBookpage.ts @@ -0,0 +1,46 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookpage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + BookCatalogId!: IType; + DotMatrixPageId!: IType; + PageNo?: string; + Layout?: string; + PageNum!: number; + Status!: number; + Url?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Sort!: number; + BookArticleId?: IType; +} + +export const IcrBookpageSchema = defineEntity({ + class: IcrBookpage, + comment: '书页;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_BookPage_01'), + BookCatalogId: p.bigint().name('BookCatalogId').columnType('bigint').comment('书目录id').index('idx_ICR_BookPage_02'), + DotMatrixPageId: p.bigint().name('DotMatrixPageId').columnType('bigint').comment('点阵页id'), + PageNo: p.string().name('PageNo').nullable().comment('点阵码'), + Layout: p.text().name('Layout').length(65535).nullable().comment('页布局(预留字段)'), + PageNum: p.integer().name('PageNum').comment('页码'), + Status: p.integer().name('Status').comment('校验状态(0-未校验 1校验成功 -1校验失败)'), + Url: p.string().name('Url').nullable().comment('页图片'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Sort: p.integer().name('Sort').comment('排序'), + BookArticleId: p.bigint().name('BookArticleId').columnType('bigint').nullable().comment('书文章Id').index('idx_ICR_BookPage_03'), + }, +}); diff --git a/node_api/src/entities/IcrBookpagearea.ts b/node_api/src/entities/IcrBookpagearea.ts new file mode 100644 index 0000000..0df787e --- /dev/null +++ b/node_api/src/entities/IcrBookpagearea.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookpagearea { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + BookPageId!: IType; + No?: string; + Type!: number; + GroupId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrBookpageareaSchema = defineEntity({ + class: IcrBookpagearea, + comment: '书页问题;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_BookPageArea_01'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').comment('书页id').index('idx_ICR_BookPageArea_02'), + No: p.string().name('No').nullable().comment('题号'), + Type: p.integer().name('Type').comment('题型'), + GroupId: p.bigint().name('GroupId').columnType('bigint').comment('分组'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrBookpagequestion.ts b/node_api/src/entities/IcrBookpagequestion.ts new file mode 100644 index 0000000..14a0820 --- /dev/null +++ b/node_api/src/entities/IcrBookpagequestion.ts @@ -0,0 +1,76 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBookpagequestion { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + BookId!: IType; + BookPageId!: IType; + No?: string; + Type!: number; + SubjectId!: IType; + Question?: string; + Options?: string; + Answer?: string; + Analysis?: string; + AnalysisUrl?: string; + Score!: number; + AnswerTime!: number; + Status!: number; + ImageUrl?: string; + VideoUrl?: string; + GroupId!: IType; + AudioStartTime!: IType; + AudioEndTime!: IType; + AudioUrl?: string; + PointsUrl?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + KnowledgepointIds?: unknown; + QuestionUrl?: string; + Case: number & Opt = 0; + AnswerUrl?: string; + KeywordAnalysis?: string; +} + +export const IcrBookpagequestionSchema = defineEntity({ + class: IcrBookpagequestion, + comment: '书页问题;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_BookPageQuestion_01'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').comment('书页id').index('idx_ICR_BookPageQuestion_02'), + No: p.string().name('No').nullable().comment('题号'), + Type: p.integer().name('Type').comment('题型'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科id'), + Question: p.text().name('Question').length(65535).nullable().comment('问题'), + Options: p.string().name('Options').nullable().comment('选项'), + Answer: p.text().name('Answer').length(65535).nullable().comment('答案'), + Analysis: p.text().name('Analysis').length(65535).nullable().comment('解析'), + AnalysisUrl: p.string().name('AnalysisUrl').nullable().comment('解析图片地址'), + Score: p.float().name('Score').comment('问题分数'), + AnswerTime: p.integer().name('AnswerTime').comment('回答时间(秒)'), + Status: p.integer().name('Status').comment('校验状态(0-未校验 1校验成功 -1校验失败)'), + ImageUrl: p.string().name('ImageUrl').nullable().comment('图片地址'), + VideoUrl: p.string().name('VideoUrl').nullable().comment('视频地址'), + GroupId: p.bigint().name('GroupId').columnType('bigint').comment('分组'), + AudioStartTime: p.bigint().name('AudioStartTime').columnType('bigint').comment('音频开始时间'), + AudioEndTime: p.bigint().name('AudioEndTime').columnType('bigint').comment('音频结束时间'), + AudioUrl: p.string().name('AudioUrl').nullable().comment('音频地址'), + PointsUrl: p.string().name('PointsUrl').nullable().comment('点位数据地址'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + KnowledgepointIds: p.array().name('KnowledgepointIds').length(4294967295).nullable().comment('关联的知识点ids'), + QuestionUrl: p.string().name('QuestionUrl').nullable().comment('问题图片地址'), + Case: p.integer().name('Case').comment('1-原问题图片 2-回答图片'), + AnswerUrl: p.string().name('AnswerUrl').nullable().comment('答案图片地址'), + KeywordAnalysis: p.string().name('KeywordAnalysis').nullable().comment('关键解析json'), + }, +}); diff --git a/node_api/src/entities/IcrBooks.ts b/node_api/src/entities/IcrBooks.ts new file mode 100644 index 0000000..146bf0f --- /dev/null +++ b/node_api/src/entities/IcrBooks.ts @@ -0,0 +1,62 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrBooks { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + BookCategoryId!: IType; + GradeLevel!: number; + GradeNum!: number; + SubjectId!: IType; + TotalPage!: number; + VerifyPage!: number; + Status!: number; + PdfUrl?: string; + Width!: number; + Height!: number; + BookType!: number; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Result!: number; + Cover?: string; + BackCover?: string; + PdfPreviewUrl?: string; + Conclusion?: any; +} + +export const IcrBooksSchema = defineEntity({ + class: IcrBooks, + comment: '书籍', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('书籍名称'), + BookCategoryId: p.bigint().name('BookCategoryId').columnType('bigint').comment('类别Id').index('idx_ICR_Books_01'), + GradeLevel: p.integer().name('GradeLevel').comment('适用年级(小 初 高)'), + GradeNum: p.integer().name('GradeNum').comment('适用年级'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('适用学科(和类别相关)'), + TotalPage: p.integer().name('TotalPage').comment('总页数'), + VerifyPage: p.integer().name('VerifyPage').comment('校验页数'), + Status: p.integer().name('Status').comment('状态'), + PdfUrl: p.string().name('PdfUrl').nullable().comment('pdf地址'), + Width: p.float().name('Width').comment('宽度'), + Height: p.float().name('Height').comment('高度'), + BookType: p.integer().name('BookType').comment('1书籍/2卷子'), + Type: p.integer().name('Type').comment('默认/作业'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Result: p.integer().name('Result').comment('审查结果(默认0 1通过 -1驳回)'), + Cover: p.string().name('Cover').nullable().comment('封面'), + BackCover: p.string().name('BackCover').nullable().comment('封底'), + PdfPreviewUrl: p.string().name('PdfPreviewUrl').nullable().comment('pdf预览地址'), + Conclusion: p.json().name('Conclusion').nullable().comment('结论Json'), + }, +}); diff --git a/node_api/src/entities/IcrClasscourse.ts b/node_api/src/entities/IcrClasscourse.ts new file mode 100644 index 0000000..1a5e772 --- /dev/null +++ b/node_api/src/entities/IcrClasscourse.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClasscourse { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRoomCourseId!: IType; + SchoolId?: IType; + GradeId?: IType; + ClassId!: IType; + Type!: number; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClasscourseSchema = defineEntity({ + class: IcrClasscourse, + comment: '课程班级关系(云班)', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课程课程Id').index('idx_ICR_ClassCourse_01'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').nullable().comment('授课学校id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').nullable().comment('授课年级id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级'), + Type: p.integer().name('Type').comment('班级类型;1 本班 2 云班'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassdatacollect.ts b/node_api/src/entities/IcrClassdatacollect.ts new file mode 100644 index 0000000..31bebf6 --- /dev/null +++ b/node_api/src/entities/IcrClassdatacollect.ts @@ -0,0 +1,41 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassdatacollect { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SchoolId!: IType; + GradeId!: IType; + ClassId!: IType; + ObjectivenNum!: number; + SubjectiveNum!: number; + YesNoNum!: number; + PKNum!: number; + CollectNum!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassdatacollectSchema = defineEntity({ + class: IcrClassdatacollect, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('年级id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + ObjectivenNum: p.integer().name('ObjectivenNum').comment('客观题互动次数'), + SubjectiveNum: p.integer().name('SubjectiveNum').comment('主观题互动次数'), + YesNoNum: p.integer().name('YesNoNum').comment('Y/N互动次数'), + PKNum: p.integer().name('PKNum').comment('PK互动次数'), + CollectNum: p.integer().name('CollectNum').comment('采集次数'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassrelationtemplate.ts b/node_api/src/entities/IcrClassrelationtemplate.ts new file mode 100644 index 0000000..cdb5c6f --- /dev/null +++ b/node_api/src/entities/IcrClassrelationtemplate.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassrelationtemplate { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + SchoolId!: IType; + GradeId!: IType; + ClassId!: IType; + TeacherId?: IType; + SubjectId?: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassrelationtemplateSchema = defineEntity({ + class: IcrClassrelationtemplate, + comment: '班级关联模板', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('模板名称'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校Id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('年级Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').nullable().comment('教师Id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').nullable().comment('学科Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassrelationtemplatedetail.ts b/node_api/src/entities/IcrClassrelationtemplatedetail.ts new file mode 100644 index 0000000..20e445d --- /dev/null +++ b/node_api/src/entities/IcrClassrelationtemplatedetail.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassrelationtemplatedetail { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRelationTemplateId!: IType; + SchoolId!: IType; + GradeId!: IType; + ClassId!: IType; + CloudClassId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassrelationtemplatedetailSchema = defineEntity({ + class: IcrClassrelationtemplatedetail, + comment: '班级关联关系绑定', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRelationTemplateId: p.bigint().name('ClassRelationTemplateId').columnType('bigint').comment('模板id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校Id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('年级Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级Id'), + CloudClassId: p.bigint().name('CloudClassId').columnType('bigint').comment('云班ID'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassroomansweringresult.ts b/node_api/src/entities/IcrClassroomansweringresult.ts new file mode 100644 index 0000000..2a2361c --- /dev/null +++ b/node_api/src/entities/IcrClassroomansweringresult.ts @@ -0,0 +1,70 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomansweringresult { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassId!: IType; + ClassType!: number; + ClassRoomCourseId!: IType; + ClassRoomQuestionId!: IType; + StudentId!: IType; + PenIds?: string; + AnsweringResultTraceId?: string; + Results?: string; + Status!: number; + Judgment!: number; + AnsweringStartTime?: Date; + AnsweringEndTime?: Date; + AnsweringSeconds?: number; + ThumbnaiImageWidth?: number; + ThumbnaiImageHeight?: number; + ThumbnaiImagePath?: string; + HighdefinitionImagePath?: string; + PenTraceId?: IType; + DotMatrixNotebookId?: IType; + DotMatrixPageId?: IType; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + SchoolId!: IType & Opt; +} + +export const IcrClassroomansweringresultSchema = defineEntity({ + class: IcrClassroomansweringresult, + comment: '课堂问题答题结果', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级编号'), + ClassType: p.integer().name('ClassType').comment('班级类型'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课堂课程Id'), + ClassRoomQuestionId: p.bigint().name('ClassRoomQuestionId').columnType('bigint').comment('课堂问题Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + PenIds: p.string().name('PenIds').nullable().comment('笔Id(逗号分割)'), + AnsweringResultTraceId: p.string().name('AnsweringResultTraceId').nullable().comment('回答笔迹Id'), + Results: p.string().name('Results').nullable().comment('答题结果内容;["",""]'), + Status: p.integer().name('Status').comment('答题结果状态'), + Judgment: p.integer().name('Judgment').comment('答题结果状态判定'), + AnsweringStartTime: p.datetime().name('AnsweringStartTime').length(3).nullable().comment('答题开始时间'), + AnsweringEndTime: p.datetime().name('AnsweringEndTime').length(3).nullable().comment('答题结束时间'), + AnsweringSeconds: p.integer().name('AnsweringSeconds').nullable().comment('答题耗时'), + ThumbnaiImageWidth: p.float().name('ThumbnaiImageWidth').nullable().comment('缩略图图像宽度(毫米)'), + ThumbnaiImageHeight: p.float().name('ThumbnaiImageHeight').nullable().comment('缩略图图像高度(毫米)'), + ThumbnaiImagePath: p.string().name('ThumbnaiImagePath').nullable().comment('缩略图图像路径;答题过程中不断生成新的缩略图,但是地址不变'), + HighdefinitionImagePath: p.string().name('HighdefinitionImagePath').nullable().comment('高清图图像路径;只有图片完成后才有高清图路径'), + PenTraceId: p.bigint().name('PenTraceId').columnType('bigint').nullable().comment('笔轨迹Id;此Id关联时序数据库'), + DotMatrixNotebookId: p.bigint().name('DotMatrixNotebookId').columnType('bigint').nullable().comment('答题的点阵本Id'), + DotMatrixPageId: p.bigint().name('DotMatrixPageId').columnType('bigint').nullable().comment('答题的点阵页Id'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校Id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/IcrClassroomcourse.ts b/node_api/src/entities/IcrClassroomcourse.ts new file mode 100644 index 0000000..dcac033 --- /dev/null +++ b/node_api/src/entities/IcrClassroomcourse.ts @@ -0,0 +1,58 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomcourse { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SchoolId?: IType; + GradeId?: IType; + ClassId!: IType; + TeacherId!: IType; + SubjectId!: IType; + Title?: string; + ActiveDate!: Date; + ActiveWeekNum!: number; + ActiveTimeStart?: Date; + ActiveTimeEnd?: Date; + Status!: number; + HandsUpStatus!: number; + BulletScreenStatus!: number; + StartPointTimes?: unknown; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + HomeworkId!: IType & Opt; +} + +export const IcrClassroomcourseSchema = defineEntity({ + class: IcrClassroomcourse, + comment: '课堂课程(本班)', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').nullable().comment('授课学校id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').nullable().comment('授课年级id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('授课本班编号'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师编号'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科编号'), + Title: p.string().name('Title').nullable().comment('课程标题(可选)'), + ActiveDate: p.datetime().name('ActiveDate').length(3).comment('授课时间(天)'), + ActiveWeekNum: p.integer().name('ActiveWeekNum').comment('周几'), + ActiveTimeStart: p.datetime().name('ActiveTimeStart').length(3).nullable().comment('授课开始时间'), + ActiveTimeEnd: p.datetime().name('ActiveTimeEnd').length(3).nullable().comment('授课结束时间;若为主动结束课程,系统自动处理'), + Status: p.integer().name('Status').comment('授课状态;0 未开始 1 已开始 200 授课正常结束 201 系统关闭课程'), + HandsUpStatus: p.integer().name('HandsUpStatus').comment('举手状态'), + BulletScreenStatus: p.integer().name('BulletScreenStatus').comment('弹幕状态'), + StartPointTimes: p.array().name('StartPointTimes').length(16777215).nullable().comment('开始点'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/IcrClassroomcourseplan.ts b/node_api/src/entities/IcrClassroomcourseplan.ts new file mode 100644 index 0000000..c740060 --- /dev/null +++ b/node_api/src/entities/IcrClassroomcourseplan.ts @@ -0,0 +1,46 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomcourseplan { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRelationTemplateId!: IType; + SchoolId!: IType; + GradeId!: IType; + ClassId!: IType; + TeacherId!: IType; + SubjectId!: IType; + Name?: string; + ClassRoomCourseId?: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + ExecutionTime!: Date & Opt; + ExpireTime!: Date & Opt; +} + +export const IcrClassroomcourseplanSchema = defineEntity({ + class: IcrClassroomcourseplan, + comment: '课程计划;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRelationTemplateId: p.bigint().name('ClassRelationTemplateId').columnType('bigint').comment('引用的模板Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校Id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('年级Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师Id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('关联学科'), + Name: p.string().name('Name').nullable().comment('名课程称'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').nullable().comment('课程id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + ExecutionTime: p.datetime().name('ExecutionTime').length(3).comment('执行时间').defaultRaw(`2025-12-11 14:18:48.727`), + ExpireTime: p.datetime().name('ExpireTime').length(3).comment('过期时间').defaultRaw(`0001-01-01 00:00:00.000`), + }, +}); diff --git a/node_api/src/entities/IcrClassroomcoursequestion.ts b/node_api/src/entities/IcrClassroomcoursequestion.ts new file mode 100644 index 0000000..072416b --- /dev/null +++ b/node_api/src/entities/IcrClassroomcoursequestion.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomcoursequestion { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRoomCourseId!: IType; + Name?: string; + KnowledgepointIds?: any; + Use!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassroomcoursequestionSchema = defineEntity({ + class: IcrClassroomcoursequestion, + comment: '课堂问题', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课堂课程Id'), + Name: p.string().name('Name').nullable().comment('课堂课程问题名称'), + KnowledgepointIds: p.json().name('KnowledgepointIds').nullable().comment('关联的知识点ids'), + Use: p.integer().name('Use').comment('0-未使用 1-使用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassroomquestion.ts b/node_api/src/entities/IcrClassroomquestion.ts new file mode 100644 index 0000000..940c20e --- /dev/null +++ b/node_api/src/entities/IcrClassroomquestion.ts @@ -0,0 +1,54 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomquestion { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRoomCourseId!: IType; + ClassId!: IType; + Type!: number; + UseType!: number; + OptionalItems?: string; + RightOptions?: string; + StartTime?: Date; + EndTime?: Date; + Status!: number; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + QuestionPackageId?: IType; + QuestionPackageItemId?: IType; + QuestionPackageNo?: IType; + QuestionPackageSort?: number; +} + +export const IcrClassroomquestionSchema = defineEntity({ + class: IcrClassroomquestion, + comment: '课堂问题', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课堂课程Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('问题属于的本班Id'), + Type: p.integer().name('Type').comment('试题类型;1 单选题 2 多选题 3 主观题 4 问题包)'), + UseType: p.integer().name('UseType').comment('使用类型0-普通题 1实时主观题 2.竞赛主观题 3.自定义竞赛题'), + OptionalItems: p.string().name('OptionalItems').nullable().comment('可选项;'), + RightOptions: p.string().name('RightOptions').nullable().comment('正确选项;'), + StartTime: p.datetime().name('StartTime').length(3).nullable().comment('试题开始时间'), + EndTime: p.datetime().name('EndTime').length(3).nullable().comment('试题结束时间'), + Status: p.integer().name('Status').comment('状态;1. 答题开始 2 答题结束 255 已废弃'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + QuestionPackageId: p.bigint().name('QuestionPackageId').columnType('bigint').nullable().comment('问题包Id'), + QuestionPackageItemId: p.bigint().name('QuestionPackageItemId').columnType('bigint').nullable().comment('问题包项Id'), + QuestionPackageNo: p.bigint().name('QuestionPackageNo').columnType('bigint').nullable().comment('问题包序号'), + QuestionPackageSort: p.integer().name('QuestionPackageSort').nullable().comment('问题包排序序号'), + }, +}); diff --git a/node_api/src/entities/IcrClassroomquestionpackage.ts b/node_api/src/entities/IcrClassroomquestionpackage.ts new file mode 100644 index 0000000..48299ec --- /dev/null +++ b/node_api/src/entities/IcrClassroomquestionpackage.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomquestionpackage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + BookId!: IType; + ClassRoomCourseId!: IType; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassroomquestionpackageSchema = defineEntity({ + class: IcrClassroomquestionpackage, + comment: '课堂问题包', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('问题包名称'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书籍Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课程Id'), + Type: p.integer().name('Type').comment('问题包类型'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassroomquestionpackageitem.ts b/node_api/src/entities/IcrClassroomquestionpackageitem.ts new file mode 100644 index 0000000..dad57a2 --- /dev/null +++ b/node_api/src/entities/IcrClassroomquestionpackageitem.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassroomquestionpackageitem { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRoomQuestionPackageId!: IType; + BookId!: IType; + ClassRoomCourseId!: IType; + Type!: number; + BookPageId?: IType; + BookQuestionId?: IType; + QestionUrl?: string; + RightOptions?: string; + Sort!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassroomquestionpackageitemSchema = defineEntity({ + class: IcrClassroomquestionpackageitem, + comment: '课堂问题项', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRoomQuestionPackageId: p.bigint().name('ClassRoomQuestionPackageId').columnType('bigint').comment('问题包Id'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书籍Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课程Id'), + Type: p.integer().name('Type').comment('问题包类型'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').nullable().comment('书籍页Id'), + BookQuestionId: p.bigint().name('BookQuestionId').columnType('bigint').nullable().comment('书籍问题Id'), + QestionUrl: p.string().name('QestionUrl').nullable().comment('问题路径'), + RightOptions: p.string().name('RightOptions').nullable().comment('正确选项'), + Sort: p.integer().name('Sort').comment('排序字段'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassservermap.ts b/node_api/src/entities/IcrClassservermap.ts new file mode 100644 index 0000000..bc7e902 --- /dev/null +++ b/node_api/src/entities/IcrClassservermap.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassservermap { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassId!: IType; + ServerId!: IType; + ExpireDate?: Date; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassservermapSchema = defineEntity({ + class: IcrClassservermap, + comment: '班级和服务器的关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + ServerId: p.bigint().name('ServerId').columnType('bigint').comment('服务器id'), + ExpireDate: p.datetime().name('ExpireDate').length(3).nullable().comment('过期时间(天)'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrClassservermapCopy1.ts b/node_api/src/entities/IcrClassservermapCopy1.ts new file mode 100644 index 0000000..cddaf49 --- /dev/null +++ b/node_api/src/entities/IcrClassservermapCopy1.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrClassservermapCopy1 { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassId!: IType; + ServerId!: IType; + ExpireDate?: Date; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrClassservermapCopy1Schema = defineEntity({ + class: IcrClassservermapCopy1, + comment: '班级和服务器的关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + ServerId: p.bigint().name('ServerId').columnType('bigint').comment('服务器id'), + ExpireDate: p.datetime().name('ExpireDate').length(3).nullable().comment('过期时间(天)'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrDotfile.ts b/node_api/src/entities/IcrDotfile.ts new file mode 100644 index 0000000..7d16a37 --- /dev/null +++ b/node_api/src/entities/IcrDotfile.ts @@ -0,0 +1,43 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotfile { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + FileName?: string; + FileAddress?: string; + PageStart?: string; + PageEnd?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Width: number & Opt = 0; + Hight: number & Opt = 0; + Total: number & Opt = 0; + TotalUse: number & Opt = 0; +} + +export const IcrDotfileSchema = defineEntity({ + class: IcrDotfile, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('名称'), + FileName: p.string().name('FileName').nullable().comment('文件名称'), + FileAddress: p.string().name('FileAddress').nullable().comment('文件网络地址'), + PageStart: p.string().name('PageStart').nullable().comment('开始页码'), + PageEnd: p.string().name('PageEnd').nullable().comment('结束页码'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Width: p.float().name('Width').comment('宽毫米'), + Hight: p.float().name('Hight').comment('高毫米'), + Total: p.integer().name('Total').comment('总数量'), + TotalUse: p.integer().name('TotalUse').comment('已使用数量'), + }, +}); diff --git a/node_api/src/entities/IcrDotfiledetail.ts b/node_api/src/entities/IcrDotfiledetail.ts new file mode 100644 index 0000000..1ccd4f4 --- /dev/null +++ b/node_api/src/entities/IcrDotfiledetail.ts @@ -0,0 +1,33 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotfiledetail { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + DotId!: IType; + PageName?: string; + PageUseName?: string; + IsUse!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrDotfiledetailSchema = defineEntity({ + class: IcrDotfiledetail, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + DotId: p.bigint().name('DotId').columnType('bigint').comment('主表id').index('idx_ICR_DotFileDetail_01'), + PageName: p.string().name('PageName').nullable().comment('页名').index('idx_ICR_DotFileDetail_02'), + PageUseName: p.string().name('PageUseName').nullable().comment('使用名'), + IsUse: p.array().name('IsUse').comment('是否使用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixnotebook.ts b/node_api/src/entities/IcrDotmatrixnotebook.ts new file mode 100644 index 0000000..6c0a9a2 --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixnotebook.ts @@ -0,0 +1,58 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixnotebook { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Type!: number; + WidthDotMatrix!: number; + HightDotMatrix!: number; + WidthMillimeter!: number; + HightMillimeter!: number; + PreviewUrl?: string; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + PdfUrl?: string; + Cover?: string; + BackCover?: string; + BackgroundImage?: string; + TotalPage: number & Opt = 0; + Status: number & Opt = 0; + Extend?: string; + DotMatrixPdfUrl?: string; +} + +export const IcrDotmatrixnotebookSchema = defineEntity({ + class: IcrDotmatrixnotebook, + comment: '点阵本', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('名称'), + Type: p.integer().name('Type').comment('类型;1 课堂答题卡 2 课堂答题本 3. 作业 4. 书籍 5.学生名单卡 6.草稿'), + WidthDotMatrix: p.integer().name('WidthDotMatrix').comment('点阵宽'), + HightDotMatrix: p.integer().name('HightDotMatrix').comment('点阵高'), + WidthMillimeter: p.float().name('WidthMillimeter').comment('宽毫米'), + HightMillimeter: p.float().name('HightMillimeter').comment('高毫米'), + PreviewUrl: p.string().name('PreviewUrl').nullable().comment('预览地址'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + PdfUrl: p.string().name('PdfUrl').nullable().comment('原始pdf地址'), + Cover: p.string().name('Cover').nullable().comment('封面'), + BackCover: p.string().name('BackCover').nullable().comment('封底'), + BackgroundImage: p.string().name('BackgroundImage').nullable().comment('背景图'), + TotalPage: p.integer().name('TotalPage').comment('总页数'), + Status: p.integer().name('Status').comment('状态(0-草稿 1-生成中 2生成成功 -1生成失败 9-归档)'), + Extend: p.text().name('Extend').length(65535).nullable().comment('扩展字段'), + DotMatrixPdfUrl: p.string().name('DotMatrixPdfUrl').nullable().comment('点阵pdf地址'), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixpage.ts b/node_api/src/entities/IcrDotmatrixpage.ts new file mode 100644 index 0000000..71fd26f --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixpage.ts @@ -0,0 +1,52 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixpage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + PageNo?: string; + DotMatrixNotebookId!: IType; + AreaPoints?: string; + WidthDotMatrix!: number; + HightDotMatrix!: number; + WidthMillimeter!: number; + HightMillimeter!: number; + PreviewUrl?: string; + AbsoluteLocation?: string; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Area?: string; + DotId?: IType; + PageNum: number & Opt = 0; +} + +export const IcrDotmatrixpageSchema = defineEntity({ + class: IcrDotmatrixpage, + comment: '点阵页', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + PageNo: p.string().name('PageNo').nullable().comment('页点阵码'), + DotMatrixNotebookId: p.bigint().name('DotMatrixNotebookId').columnType('bigint').comment('点阵本Id'), + AreaPoints: p.text().name('AreaPoints').length(65535).nullable().comment('答题区域(文本Json)'), + WidthDotMatrix: p.integer().name('WidthDotMatrix').comment('点阵宽'), + HightDotMatrix: p.integer().name('HightDotMatrix').comment('点阵高'), + WidthMillimeter: p.float().name('WidthMillimeter').comment('宽毫米'), + HightMillimeter: p.float().name('HightMillimeter').comment('高毫米'), + PreviewUrl: p.string().name('PreviewUrl').nullable().comment('预览地址(页背景图)'), + AbsoluteLocation: p.string().name('AbsoluteLocation').nullable().comment('点阵区域在当前页的绝对坐标'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Area: p.text().name('Area').length(65535).nullable().comment('区域'), + DotId: p.bigint().name('DotId').columnType('bigint').nullable().comment('点阵id').defaultRaw(`0`), + PageNum: p.integer().name('PageNum').comment('点阵页页码'), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixpagecollectrecord.ts b/node_api/src/entities/IcrDotmatrixpagecollectrecord.ts new file mode 100644 index 0000000..b5ff648 --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixpagecollectrecord.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixpagecollectrecord { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + PageNo?: string; + LastCollectTime!: Date; + TriggerTime?: Date; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrDotmatrixpagecollectrecordSchema = defineEntity({ + class: IcrDotmatrixpagecollectrecord, + comment: '点阵页采集记录', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户编号'), + PageNo: p.string().name('PageNo').nullable().comment('点阵页码'), + LastCollectTime: p.datetime().name('LastCollectTime').length(3).comment('上次采集时间'), + TriggerTime: p.datetime().name('TriggerTime').length(3).nullable().comment('触发时间'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixpen.ts b/node_api/src/entities/IcrDotmatrixpen.ts new file mode 100644 index 0000000..99497fa --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixpen.ts @@ -0,0 +1,40 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixpen { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SerialNo?: string; + Status!: number; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + ClassId!: IType & Opt; + Power: number & Opt = 0; + OnlineStatus!: unknown & Opt; + OnlineTime!: Date & Opt; +} + +export const IcrDotmatrixpenSchema = defineEntity({ + class: IcrDotmatrixpen, + comment: '笔', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SerialNo: p.string().name('SerialNo').nullable().comment('唯一序列号').unique('idx_ICR_DotMatrixPen_01'), + Status: p.integer().name('Status').comment('状态;1 启用 0 禁用'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级Id').defaultRaw(`0`).index('idx_ICR_DotMatrixPen_02'), + Power: p.integer().name('Power').comment('电量'), + OnlineStatus: p.array().name('OnlineStatus').comment('在线状态').defaultRaw(`b'0'`), + OnlineTime: p.datetime().name('OnlineTime').length(3).comment('在线时间').defaultRaw(`0001-01-01 00:00:00.000`), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixtemplate.ts b/node_api/src/entities/IcrDotmatrixtemplate.ts new file mode 100644 index 0000000..bc4fde8 --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixtemplate.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixtemplate { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Width!: number; + Height!: number; + DesignWidth!: number; + DesignHeight!: number; + OriginalImageUrl?: string; + Elements?: any; + Type!: number; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrDotmatrixtemplateSchema = defineEntity({ + class: IcrDotmatrixtemplate, + comment: '点阵模板', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').length(30).nullable().comment('答题板名称'), + Width: p.float().name('Width').comment('宽毫米'), + Height: p.float().name('Height').comment('高毫米'), + DesignWidth: p.float().name('DesignWidth').comment('设计宽px'), + DesignHeight: p.float().name('DesignHeight').comment('设计高px'), + OriginalImageUrl: p.string().name('OriginalImageUrl').nullable().comment('原图(画板背景)'), + Elements: p.json().name('Elements').nullable().comment('答题板元素'), + Type: p.integer().name('Type').comment('类型'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrDotmatrixtermianltask.ts b/node_api/src/entities/IcrDotmatrixtermianltask.ts new file mode 100644 index 0000000..cd68d75 --- /dev/null +++ b/node_api/src/entities/IcrDotmatrixtermianltask.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrDotmatrixtermianltask { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + PageNo?: string; + StartTime?: Date; + EndTime?: Date; + QuestionTaskId!: IType; + TaskType!: number; + Status!: number; + TerminalId?: string; + Content?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrDotmatrixtermianltaskSchema = defineEntity({ + class: IcrDotmatrixtermianltask, + comment: '点阵页任务', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户编号'), + PageNo: p.string().name('PageNo').nullable().comment('点阵页码'), + StartTime: p.datetime().name('StartTime').length(3).nullable().comment('任务采集开始时间'), + EndTime: p.datetime().name('EndTime').length(3).nullable().comment('任务采集结束时间'), + QuestionTaskId: p.bigint().name('QuestionTaskId').columnType('bigint').comment('问题任务编号'), + TaskType: p.integer().name('TaskType').comment('任务类型'), + Status: p.integer().name('Status').comment('状态'), + TerminalId: p.string().name('TerminalId').nullable().comment('终端编号'), + Content: p.string().name('Content').length(4000).nullable().comment('内容'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrFeedback.ts b/node_api/src/entities/IcrFeedback.ts new file mode 100644 index 0000000..5df4943 --- /dev/null +++ b/node_api/src/entities/IcrFeedback.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrFeedback { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassRoomCourseId!: IType; + ClassId!: IType; + IsAnonymity!: unknown; + Status!: number; + EndTime?: Date; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrFeedbackSchema = defineEntity({ + class: IcrFeedback, + comment: '反馈', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课堂课程Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('问题属于的本班Id'), + IsAnonymity: p.array().name('IsAnonymity').comment('是否匿名'), + Status: p.integer().name('Status').comment('状态;1. 答题开始 2 答题结束 255 已废弃'), + EndTime: p.datetime().name('EndTime').length(3).nullable().comment('结束时间'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrFeedbackresult.ts b/node_api/src/entities/IcrFeedbackresult.ts new file mode 100644 index 0000000..b97e14c --- /dev/null +++ b/node_api/src/entities/IcrFeedbackresult.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrFeedbackresult { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + FeedBackId!: IType; + ClassId!: IType; + ClassRoomCourseId!: IType; + StudentId!: IType; + SelectedOptions?: string; + Status!: number; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrFeedbackresultSchema = defineEntity({ + class: IcrFeedbackresult, + comment: '反馈结果', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + FeedBackId: p.bigint().name('FeedBackId').columnType('bigint').comment('反馈Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级编号'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').comment('课堂课程Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + SelectedOptions: p.string().name('SelectedOptions').nullable().comment('选中的选项'), + Status: p.integer().name('Status').comment('状态(0-未选择 1-已选择)'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomework.ts b/node_api/src/entities/IcrHomework.ts new file mode 100644 index 0000000..cfd6249 --- /dev/null +++ b/node_api/src/entities/IcrHomework.ts @@ -0,0 +1,60 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomework { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + SubjectIds?: unknown; + BookId!: IType; + StudentGroupId!: IType; + StartTime!: Date; + EndTime!: Date; + Status!: number; + Type!: number; + PdfUrl?: string; + TriggerTime?: Date; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + ReviewIds?: unknown; + DraftTemplateId?: IType; + ExamRoomId!: IType & Opt; + TutorRoomId?: IType; + MeetingStatus: number & Opt = 0; + ReviewTime?: Date; + ClassRoomCourseId?: IType; +} + +export const IcrHomeworkSchema = defineEntity({ + class: IcrHomework, + comment: '作业', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('名称'), + SubjectIds: p.array().name('SubjectIds').length(4294967295).nullable().comment('学科Ids'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('引用书籍Id').index('idx_ICR_Homework_01'), + StudentGroupId: p.bigint().name('StudentGroupId').columnType('bigint').comment('引用学生模板Id').index('idx_ICR_Homework_02'), + StartTime: p.datetime().name('StartTime').length(3).comment('发布时间'), + EndTime: p.datetime().name('EndTime').length(3).comment('结束时间'), + Status: p.integer().name('Status').comment('状态'), + Type: p.integer().name('Type').comment('作业类型'), + PdfUrl: p.string().name('PdfUrl').nullable().comment('pdf预览地址'), + TriggerTime: p.datetime().name('TriggerTime').length(3).nullable().comment('触发时间'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + ReviewIds: p.array().name('ReviewIds').length(4294967295).nullable().comment('批阅人ids'), + DraftTemplateId: p.bigint().name('DraftTemplateId').columnType('bigint').nullable().comment('草稿纸模板id'), + ExamRoomId: p.bigint().name('ExamRoomId').columnType('bigint').comment('考场Id').defaultRaw(`0`), + TutorRoomId: p.bigint().name('TutorRoomId').columnType('bigint').nullable().comment('辅导室Id'), + MeetingStatus: p.integer().name('MeetingStatus').comment('会议状态(0-待开课 1-上课中 -1-结束)'), + ReviewTime: p.datetime().name('ReviewTime').length(3).nullable().comment('批阅时间'), + ClassRoomCourseId: p.bigint().name('ClassRoomCourseId').columnType('bigint').nullable().comment('互动课程Id'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswer.ts b/node_api/src/entities/IcrHomeworkanswer.ts new file mode 100644 index 0000000..ddd9bfa --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswer.ts @@ -0,0 +1,76 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswer { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + BooksPageQuestionId!: IType; + BooksPageQuestionGroupId!: IType; + StudentId!: IType; + Result?: string; + Score!: number; + QuestioAnswerUrl?: string; + AnswerUrl?: string; + PageAnswerUrl?: string; + ReviewId?: IType; + ReviewUrl?: string; + PointsUrl?: string; + AnswerStatus!: number; + Status!: number; + AsnwerStartTime?: Date; + AsnwerEndTime?: Date; + AnswerSeconds!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + BookPageId!: IType & Opt; + BookPageNum: number & Opt = 0; + ReviewPageUrl?: string; + ImageRecognition: number & Opt = 0; + Modify: number & Opt = 0; + LastTag!: IType & Opt; + DotPageNo?: string; + PageAnswerDotUrl?: string; +} + +export const IcrHomeworkanswerSchema = defineEntity({ + class: IcrHomeworkanswer, + comment: '作业回答', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业id').index('idx_ICR_HomeworkAnswer_01'), + BooksPageQuestionId: p.bigint().name('BooksPageQuestionId').columnType('bigint').comment('作业问题id').index('idx_ICR_HomeworkAnswer_03'), + BooksPageQuestionGroupId: p.bigint().name('BooksPageQuestionGroupId').columnType('bigint').comment('作业问题grouipId').index('idx_ICR_HomeworkAnswer_04'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('答题人id').index('idx_ICR_HomeworkAnswer_05'), + Result: p.string().name('Result').nullable().comment('答题结果'), + Score: p.integer().name('Score').comment('答题得分'), + QuestioAnswerUrl: p.string().name('QuestioAnswerUrl').nullable().comment('答题结果图片地址(包含答题内容)'), + AnswerUrl: p.string().name('AnswerUrl').nullable().comment('答题结果图片地址(只包含答题内容框)'), + PageAnswerUrl: p.string().name('PageAnswerUrl').nullable().comment('答题结果图片地址'), + ReviewId: p.bigint().name('ReviewId').columnType('bigint').nullable().comment('批阅人id'), + ReviewUrl: p.string().name('ReviewUrl').nullable().comment('批阅人图片地址(问题)'), + PointsUrl: p.string().name('PointsUrl').nullable().comment('点位数据地址'), + AnswerStatus: p.integer().name('AnswerStatus').comment('答题状态'), + Status: p.integer().name('Status').comment('批阅状态 0-未批阅 1-已批阅'), + AsnwerStartTime: p.datetime().name('AsnwerStartTime').length(3).nullable().comment('开始答题时间'), + AsnwerEndTime: p.datetime().name('AsnwerEndTime').length(3).nullable().comment('开始结束时间'), + AnswerSeconds: p.integer().name('AnswerSeconds').comment('答题时间(秒)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').comment('作业页id').defaultRaw(`0`).index('idx_ICR_HomeworkAnswer_02'), + BookPageNum: p.integer().name('BookPageNum').comment('作业页页码'), + ReviewPageUrl: p.string().name('ReviewPageUrl').nullable().comment('批阅人图片地址(整页)'), + ImageRecognition: p.integer().name('ImageRecognition').comment('识别状态'), + Modify: p.integer().name('Modify').comment('修改次数累加'), + LastTag: p.bigint().name('LastTag').columnType('bigint').comment('最后修改标记').defaultRaw(`0`), + DotPageNo: p.string().name('DotPageNo').nullable().comment('点阵页码'), + PageAnswerDotUrl: p.string().name('PageAnswerDotUrl').nullable().comment('答题结果点阵图片地址'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswercoordinate.ts b/node_api/src/entities/IcrHomeworkanswercoordinate.ts new file mode 100644 index 0000000..f1025da --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswercoordinate.ts @@ -0,0 +1,24 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswercoordinate { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkAnswerId!: IType; + Content?: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; +} + +export const IcrHomeworkanswercoordinateSchema = defineEntity({ + class: IcrHomeworkanswercoordinate, + comment: '作业回答', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkAnswerId: p.bigint().name('HomeworkAnswerId').columnType('bigint'), + Content: p.array().name('Content').length(4294967295).nullable(), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswerdraftcoordinate.ts b/node_api/src/entities/IcrHomeworkanswerdraftcoordinate.ts new file mode 100644 index 0000000..da68d34 --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswerdraftcoordinate.ts @@ -0,0 +1,24 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswerdraftcoordinate { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkAnswerDraftId!: IType; + Content?: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; +} + +export const IcrHomeworkanswerdraftcoordinateSchema = defineEntity({ + class: IcrHomeworkanswerdraftcoordinate, + comment: '作业草稿纸', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkAnswerDraftId: p.bigint().name('HomeworkAnswerDraftId').columnType('bigint'), + Content: p.array().name('Content').length(4294967295).nullable(), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswerexplain.ts b/node_api/src/entities/IcrHomeworkanswerexplain.ts new file mode 100644 index 0000000..c9b4448 --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswerexplain.ts @@ -0,0 +1,46 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswerexplain { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + StudentId!: IType; + QuestionId!: IType; + AudioStartTime!: IType; + AudioEndTime!: IType; + AudioUrl?: string; + PointsUrl?: string; + OperatorId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Case: number & Opt = 0; + Status: number & Opt = 0; +} + +export const IcrHomeworkanswerexplainSchema = defineEntity({ + class: IcrHomeworkanswerexplain, + comment: '书页问题;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + QuestionId: p.bigint().name('QuestionId').columnType('bigint').comment('问题Id'), + AudioStartTime: p.bigint().name('AudioStartTime').columnType('bigint').comment('音频开始时间'), + AudioEndTime: p.bigint().name('AudioEndTime').columnType('bigint').comment('音频结束时间'), + AudioUrl: p.string().name('AudioUrl').nullable().comment('音频地址'), + PointsUrl: p.string().name('PointsUrl').nullable().comment('点位数据地址'), + OperatorId: p.bigint().name('OperatorId').columnType('bigint').comment('操作人Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Case: p.integer().name('Case').comment('0-无图 1-原问题图片 2-回答图片'), + Status: p.integer().name('Status').comment('0-正常 1-过时(之前的)'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswerpage.ts b/node_api/src/entities/IcrHomeworkanswerpage.ts new file mode 100644 index 0000000..002cc7d --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswerpage.ts @@ -0,0 +1,42 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswerpage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + StudentId!: IType; + PageId!: IType; + DotPageNum!: number; + PageResultUrl?: string; + Type!: number; + LastTag!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + PageDotResultUrl?: string; +} + +export const IcrHomeworkanswerpageSchema = defineEntity({ + class: IcrHomeworkanswerpage, + comment: '作业回答', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业id').index('idx_ICR_HomeworkAnswerPage_01'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('答题人id').index('idx_ICR_HomeworkAnswerPage_02'), + PageId: p.bigint().name('PageId').columnType('bigint').comment('页Id和联动'), + DotPageNum: p.integer().name('DotPageNum').comment('点阵页序号'), + PageResultUrl: p.string().name('PageResultUrl').nullable().comment('页结果图片地址'), + Type: p.integer().name('Type').comment('1:回答 2:草稿'), + LastTag: p.bigint().name('LastTag').columnType('bigint').comment('最后修改标记'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + PageDotResultUrl: p.string().name('PageDotResultUrl').nullable().comment('页结果点阵图片地址'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkanswersnapshoot.ts b/node_api/src/entities/IcrHomeworkanswersnapshoot.ts new file mode 100644 index 0000000..8efc6d1 --- /dev/null +++ b/node_api/src/entities/IcrHomeworkanswersnapshoot.ts @@ -0,0 +1,76 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkanswersnapshoot { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + BookPageId!: IType; + BookPageNum!: number; + BooksPageQuestionId!: IType; + BooksPageQuestionGroupId!: IType; + StudentId!: IType; + Result?: string; + Score!: number; + QuestioAnswerUrl?: string; + AnswerUrl?: string; + PageAnswerUrl?: string; + ReviewId!: IType; + ReviewUrl?: string; + AudioStartTime!: IType; + AudioEndTime!: IType; + AudioUrl?: string; + PointsUrl?: string; + AnswerStatus!: number; + Status!: number; + Date!: IType; + AsnwerStartTime?: Date; + AsnwerEndTime?: Date; + AnswerSeconds!: number; + ImageRecognition!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + HomeworkAnswerId!: IType & Opt; +} + +export const IcrHomeworkanswersnapshootSchema = defineEntity({ + class: IcrHomeworkanswersnapshoot, + comment: '作业回答', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业id'), + BookPageId: p.bigint().name('BookPageId').columnType('bigint').comment('作业页id'), + BookPageNum: p.integer().name('BookPageNum').comment('作业页页码'), + BooksPageQuestionId: p.bigint().name('BooksPageQuestionId').columnType('bigint').comment('作业问题id').index('idx_ICR_HomeworkAnswerSnapshoot_01'), + BooksPageQuestionGroupId: p.bigint().name('BooksPageQuestionGroupId').columnType('bigint').comment('作业问题grouipId'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('答题人id'), + Result: p.string().name('Result').nullable().comment('答题结果'), + Score: p.integer().name('Score').comment('答题得分'), + QuestioAnswerUrl: p.string().name('QuestioAnswerUrl').nullable().comment('答题结果图片地址(包含答题内容)'), + AnswerUrl: p.string().name('AnswerUrl').nullable().comment('答题结果图片地址(只包含答题内容框)'), + PageAnswerUrl: p.string().name('PageAnswerUrl').nullable().comment('答题结果图片地址'), + ReviewId: p.bigint().name('ReviewId').columnType('bigint').comment('批阅人id'), + ReviewUrl: p.string().name('ReviewUrl').nullable().comment('批阅人url'), + AudioStartTime: p.bigint().name('AudioStartTime').columnType('bigint').comment('音频开始时间'), + AudioEndTime: p.bigint().name('AudioEndTime').columnType('bigint').comment('音频结束时间'), + AudioUrl: p.string().name('AudioUrl').nullable().comment('音频地址'), + PointsUrl: p.string().name('PointsUrl').nullable().comment('点位数据地址'), + AnswerStatus: p.integer().name('AnswerStatus').comment('答题状态'), + Status: p.integer().name('Status').comment('批阅状态 0-未批阅 1-已批阅'), + Date: p.bigint().name('Date').columnType('bigint').comment('日期 yyyyMMdd'), + AsnwerStartTime: p.datetime().name('AsnwerStartTime').length(3).nullable().comment('开始答题时间'), + AsnwerEndTime: p.datetime().name('AsnwerEndTime').length(3).nullable().comment('开始结束时间'), + AnswerSeconds: p.integer().name('AnswerSeconds').comment('答题时间(秒)'), + ImageRecognition: p.integer().name('ImageRecognition').comment('识别状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + HomeworkAnswerId: p.bigint().name('HomeworkAnswerId').columnType('bigint').comment('回答id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkarticlesnapshoot.ts b/node_api/src/entities/IcrHomeworkarticlesnapshoot.ts new file mode 100644 index 0000000..b028d7b --- /dev/null +++ b/node_api/src/entities/IcrHomeworkarticlesnapshoot.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkarticlesnapshoot { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + BookId!: IType; + StudentId!: IType; + BookArticleId!: IType; + ReadingTime!: IType; + WordCount!: number; + Content?: unknown; + AnswerPage?: unknown; + Date!: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrHomeworkarticlesnapshootSchema = defineEntity({ + class: IcrHomeworkarticlesnapshoot, + comment: '作业回答', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业id').index('idx_ICR_HomeworkArticleSnapshoot_01'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('答题人id').index('idx_ICR_HomeworkArticleSnapshoot_02'), + BookArticleId: p.bigint().name('BookArticleId').columnType('bigint').comment('文章Id').index('idx_ICR_HomeworkArticleSnapshoot_03'), + ReadingTime: p.bigint().name('ReadingTime').columnType('bigint').comment('阅读时间(秒)'), + WordCount: p.integer().name('WordCount').comment('字数'), + Content: p.array().name('Content').length(4294967295).nullable().comment('内容(json)'), + AnswerPage: p.array().name('AnswerPage').length(4294967295).nullable().comment('文章下所有回答页'), + Date: p.date().name('Date').comment('日期'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkevaluation.ts b/node_api/src/entities/IcrHomeworkevaluation.ts new file mode 100644 index 0000000..e3ad6c2 --- /dev/null +++ b/node_api/src/entities/IcrHomeworkevaluation.ts @@ -0,0 +1,43 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkevaluation { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + StudentId!: IType; + HomeworkId!: IType; + BookId!: IType; + ArticleCount!: number; + AccuracyRate!: number; + AnswerTime!: IType; + Detail?: unknown; + AiInterpret?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrHomeworkevaluationSchema = defineEntity({ + class: IcrHomeworkevaluation, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('名称'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id').index('idx_ICR_HomeworkEvaluation_01'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id').index('idx_ICR_HomeworkEvaluation_02'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_HomeworkEvaluation_03'), + ArticleCount: p.integer().name('ArticleCount').comment('文章数量'), + AccuracyRate: p.float().name('AccuracyRate').comment('正确率'), + AnswerTime: p.bigint().name('AnswerTime').columnType('bigint').comment('作答时间'), + Detail: p.array().name('Detail').length(4294967295).nullable().comment('详情'), + AiInterpret: p.string().name('AiInterpret').nullable().comment('AI解读'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkextracurricular.ts b/node_api/src/entities/IcrHomeworkextracurricular.ts new file mode 100644 index 0000000..c29041a --- /dev/null +++ b/node_api/src/entities/IcrHomeworkextracurricular.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkextracurricular { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Content?: string; + StartTime!: Date; + EndTime!: Date; + StudentTemplateId!: IType; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + ReviewIds?: string; +} + +export const IcrHomeworkextracurricularSchema = defineEntity({ + class: IcrHomeworkextracurricular, + comment: '课外作业', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('活动名称'), + Content: p.string().name('Content').nullable().comment('活动内容'), + StartTime: p.datetime().name('StartTime').length(3).comment('发布时间'), + EndTime: p.datetime().name('EndTime').length(3).comment('结束时间'), + StudentTemplateId: p.bigint().name('StudentTemplateId').columnType('bigint').comment('引用学生模板Id'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + ReviewIds: p.string().name('ReviewIds').length(5000).nullable().comment('批阅人ids'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkextracurricularanswer.ts b/node_api/src/entities/IcrHomeworkextracurricularanswer.ts new file mode 100644 index 0000000..6da1876 --- /dev/null +++ b/node_api/src/entities/IcrHomeworkextracurricularanswer.ts @@ -0,0 +1,48 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkextracurricularanswer { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkExtracurricularId!: IType; + Name?: string; + Time!: Date; + Place?: string; + Participant?: string; + Thoughts?: string; + Images?: unknown; + VideoUrl?: string; + StudentId!: IType; + Score!: number; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrHomeworkextracurricularanswerSchema = defineEntity({ + class: IcrHomeworkextracurricularanswer, + comment: '课外作业-学生表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkExtracurricularId: p.bigint().name('HomeworkExtracurricularId').columnType('bigint').comment('课外活动Id'), + Name: p.string().name('Name').nullable().comment('活动名称'), + Time: p.datetime().name('Time').length(3).comment('活动时间'), + Place: p.string().name('Place').nullable().comment('活动地点'), + Participant: p.string().name('Participant').nullable().comment('活动人员'), + Thoughts: p.string().name('Thoughts').nullable().comment('活动感想'), + Images: p.array().name('Images').length(4294967295).nullable().comment('活动图片'), + VideoUrl: p.string().name('VideoUrl').nullable().comment('视频地址'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('回答学生'), + Score: p.integer().name('Score').comment('活动评价'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkmeeting.ts b/node_api/src/entities/IcrHomeworkmeeting.ts new file mode 100644 index 0000000..aa212fa --- /dev/null +++ b/node_api/src/entities/IcrHomeworkmeeting.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkmeeting { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + MeetingStatus!: number; + StartTime?: Date; + EndTime?: Date; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrHomeworkmeetingSchema = defineEntity({ + class: IcrHomeworkmeeting, + comment: '作业', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id').index('idx_ICR_HomeworkMeeting_01'), + MeetingStatus: p.integer().name('MeetingStatus').comment('会议状态(0-待开课 1-上课中 -1-结束)'), + StartTime: p.datetime().name('StartTime').length(3).nullable().comment('开始时间'), + EndTime: p.datetime().name('EndTime').length(3).nullable().comment('结束时间'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkperusal.ts b/node_api/src/entities/IcrHomeworkperusal.ts new file mode 100644 index 0000000..9d0017f --- /dev/null +++ b/node_api/src/entities/IcrHomeworkperusal.ts @@ -0,0 +1,45 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkperusal { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + StartDate!: string; + EndDate!: string; + BookCount!: number; + ArticleCount!: number; + ReadingTime!: IType; + WordCount!: number; + Detail?: any; + AiInterpret?: string; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrHomeworkperusalSchema = defineEntity({ + class: IcrHomeworkperusal, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id').index('idx_ICR_HomeworkPerusal_03'), + StartDate: p.date().name('StartDate').comment('开始日期').index('idx_ICR_HomeworkPerusal_01'), + EndDate: p.date().name('EndDate').comment('结束日期').index('idx_ICR_HomeworkPerusal_02'), + BookCount: p.integer().name('BookCount').comment('书数量'), + ArticleCount: p.integer().name('ArticleCount').comment('文章数量'), + ReadingTime: p.bigint().name('ReadingTime').columnType('bigint').comment('阅读时间'), + WordCount: p.integer().name('WordCount').comment('阅读字数'), + Detail: p.json().name('Detail').nullable().comment('详情'), + AiInterpret: p.string().name('AiInterpret').nullable().comment('AI解读'), + Type: p.integer().name('Type').comment('类型(1-周报,2-周报 3-月报 4-期报)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkprocessingtask.ts b/node_api/src/entities/IcrHomeworkprocessingtask.ts new file mode 100644 index 0000000..098cccc --- /dev/null +++ b/node_api/src/entities/IcrHomeworkprocessingtask.ts @@ -0,0 +1,41 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkprocessingtask { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + HomeworkId!: IType; + TaskType!: number; + Status!: number; + Priority!: IType; + Error?: string; + LastScanTime!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Date?: Date; +} + +export const IcrHomeworkprocessingtaskSchema = defineEntity({ + class: IcrHomeworkprocessingtask, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生编号'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id'), + TaskType: p.integer().name('TaskType'), + Status: p.integer().name('Status').comment('状态'), + Priority: p.bigint().name('Priority').columnType('bigint').comment('优先级'), + Error: p.string().name('Error').nullable().comment('异常信息'), + LastScanTime: p.bigint().name('LastScanTime').columnType('bigint').comment('上次扫描时间'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Date: p.datetime().name('Date').length(3).nullable().comment('时间'), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkquestion.ts b/node_api/src/entities/IcrHomeworkquestion.ts new file mode 100644 index 0000000..261811f --- /dev/null +++ b/node_api/src/entities/IcrHomeworkquestion.ts @@ -0,0 +1,40 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkquestion { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + BookId!: IType; + PageId!: IType; + QuestionId!: IType; + QuestionNo?: string; + Score!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + QuestionGroupId!: IType & Opt; +} + +export const IcrHomeworkquestionSchema = defineEntity({ + class: IcrHomeworkquestion, + comment: '作业', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业Id').index('idx_ICR_HomeworkQuestion_01'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书Id').index('idx_ICR_HomeworkQuestion_02'), + PageId: p.bigint().name('PageId').columnType('bigint').comment('页Id').index('idx_ICR_HomeworkQuestion_03'), + QuestionId: p.bigint().name('QuestionId').columnType('bigint').comment('问题Id').index('idx_ICR_HomeworkQuestion_04'), + QuestionNo: p.string().name('QuestionNo').nullable().comment('题号'), + Score: p.float().name('Score').comment('问题分数'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + QuestionGroupId: p.bigint().name('QuestionGroupId').columnType('bigint').comment('问题组Id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/IcrHomeworkstudent.ts b/node_api/src/entities/IcrHomeworkstudent.ts new file mode 100644 index 0000000..128161e --- /dev/null +++ b/node_api/src/entities/IcrHomeworkstudent.ts @@ -0,0 +1,40 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrHomeworkstudent { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + HomeworkId!: IType; + StudentId!: IType; + ReviewId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + PenId?: IType; + MapStudentId?: IType; + ReadingDurationSeconds?: IType; + Status: number & Opt = 0; +} + +export const IcrHomeworkstudentSchema = defineEntity({ + class: IcrHomeworkstudent, + comment: '学生作业', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + HomeworkId: p.bigint().name('HomeworkId').columnType('bigint').comment('作业id').index('idx_ICR_HomeworkStudent_01'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id').index('idx_ICR_HomeworkStudent_02'), + ReviewId: p.bigint().name('ReviewId').columnType('bigint').comment('批阅人Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + PenId: p.bigint().name('PenId').columnType('bigint').nullable().comment('笔Id'), + MapStudentId: p.bigint().name('MapStudentId').columnType('bigint').nullable().comment('映射学生Id'), + ReadingDurationSeconds: p.bigint().name('ReadingDurationSeconds').columnType('bigint').nullable().comment('阅读时间'), + Status: p.integer().name('Status').comment('状态(0:默认 1:已校验)'), + }, +}); diff --git a/node_api/src/entities/IcrKnowledgepoint.ts b/node_api/src/entities/IcrKnowledgepoint.ts new file mode 100644 index 0000000..8681229 --- /dev/null +++ b/node_api/src/entities/IcrKnowledgepoint.ts @@ -0,0 +1,42 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrKnowledgepoint { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + GradeLevel!: IType; + SubjectId!: IType; + Name?: string; + Color?: string; + ParentId!: IType; + Level!: number; + Sort!: number; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrKnowledgepointSchema = defineEntity({ + class: IcrKnowledgepoint, + comment: '知识点;', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + GradeLevel: p.bigint().name('GradeLevel').columnType('bigint').comment('年级'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科Id').index('idx_ICR_KnowledgePoint_01'), + Name: p.string().name('Name').nullable().comment('名称').index('idx_ICR_KnowledgePoint_03'), + Color: p.string().name('Color').nullable().comment('颜色'), + ParentId: p.bigint().name('ParentId').columnType('bigint').comment('父Id').index('idx_ICR_KnowledgePoint_02'), + Level: p.integer().name('Level').comment('级别'), + Sort: p.integer().name('Sort').comment('排序'), + Type: p.integer().name('Type').comment('分类(1-知识点 2-方法)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrLearnreport.ts b/node_api/src/entities/IcrLearnreport.ts new file mode 100644 index 0000000..29466ef --- /dev/null +++ b/node_api/src/entities/IcrLearnreport.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrLearnreport { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + StartDate!: string; + EndDate!: string; + HomeworkIds?: unknown; + PreLearnTimeRate!: number; + PreAccuracyRate!: number; + AccuracyRate!: number; + Type!: number; + Detail?: any; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrLearnreportSchema = defineEntity({ + class: IcrLearnreport, + comment: '学情报告', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + StartDate: p.date().name('StartDate').comment('开始时间'), + EndDate: p.date().name('EndDate').comment('结束时间'), + HomeworkIds: p.array().name('HomeworkIds').length(4294967295).nullable().comment('作业Ids'), + PreLearnTimeRate: p.float().name('PreLearnTimeRate').comment('作答时长率(较上次百分比 -为降低)'), + PreAccuracyRate: p.float().name('PreAccuracyRate').comment('正确率(较上次百分比 -为降低)'), + AccuracyRate: p.float().name('AccuracyRate').comment('正确率(较上次 -为降低)'), + Type: p.integer().name('Type').comment('类型 1:天 2:周'), + Detail: p.json().name('Detail').nullable().comment('详情'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrQuestionbank.ts b/node_api/src/entities/IcrQuestionbank.ts new file mode 100644 index 0000000..8844972 --- /dev/null +++ b/node_api/src/entities/IcrQuestionbank.ts @@ -0,0 +1,56 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrQuestionbank { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SubjectId!: IType; + Type!: number; + Source!: number; + Difficulty!: number; + GradeLevel!: number; + GradeNum!: number; + Image?: string; + Question?: string; + Answer?: string; + Analysis?: string; + VideoUrl?: string; + KnowledgepointIds?: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + QuestionUrl?: string; + Options?: unknown; + AnalysisUrl?: string; +} + +export const IcrQuestionbankSchema = defineEntity({ + class: IcrQuestionbank, + comment: '题库', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科'), + Type: p.integer().name('Type').comment('题型'), + Source: p.integer().name('Source').comment('来源'), + Difficulty: p.integer().name('Difficulty').comment('难度'), + GradeLevel: p.integer().name('GradeLevel').comment('学级(0-小 1-初 2-高)'), + GradeNum: p.integer().name('GradeNum').comment('年级'), + Image: p.string().name('Image').nullable().comment('原图'), + Question: p.text().name('Question').length(65535).nullable().comment('问题'), + Answer: p.string().name('Answer').nullable().comment('答案'), + Analysis: p.text().name('Analysis').length(65535).nullable().comment('解析'), + VideoUrl: p.string().name('VideoUrl').nullable().comment('视频讲解地址'), + KnowledgepointIds: p.array().name('KnowledgepointIds').length(4294967295).nullable().comment('关联的知识点ids'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + QuestionUrl: p.string().name('QuestionUrl').nullable().comment('问题图'), + Options: p.array().name('Options').length(4294967295).nullable().comment('选项'), + AnalysisUrl: p.string().name('AnalysisUrl').nullable().comment('解析图片'), + }, +}); diff --git a/node_api/src/entities/IcrServer.ts b/node_api/src/entities/IcrServer.ts new file mode 100644 index 0000000..b9c44e8 --- /dev/null +++ b/node_api/src/entities/IcrServer.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrServer { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Address?: string; + Port!: number; + Size!: number; + Status!: number; + ExpireDate?: Date; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrServerSchema = defineEntity({ + class: IcrServer, + comment: '服务器', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('姓名'), + Address: p.string().name('Address').nullable().comment('地址'), + Port: p.integer().name('Port').comment('端口'), + Size: p.integer().name('Size').comment('容量'), + Status: p.integer().name('Status').comment('状态'), + ExpireDate: p.datetime().name('ExpireDate').length(3).nullable().comment('过期时间(天)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrServerconfig.ts b/node_api/src/entities/IcrServerconfig.ts new file mode 100644 index 0000000..3035b53 --- /dev/null +++ b/node_api/src/entities/IcrServerconfig.ts @@ -0,0 +1,30 @@ +import { type IType, defineEntity, p } from '@mikro-orm/core'; + +export class IcrServerconfig { + Id!: IType; + Name?: string; + Hour!: number; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime?: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted?: unknown; +} + +export const IcrServerconfigSchema = defineEntity({ + class: IcrServerconfig, + properties: { + Id: p.bigint().name('Id').columnType('bigint'), + Name: p.string().name('Name').nullable(), + Hour: p.integer().name('Hour'), + Status: p.integer().name('Status'), + Revision: p.integer().name('Revision'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable(), + CreatedTime: p.datetime().name('CreatedTime').length(3).nullable(), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable(), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable(), + IsDeleted: p.array().name('IsDeleted').nullable(), + }, +}); diff --git a/node_api/src/entities/IcrService.ts b/node_api/src/entities/IcrService.ts new file mode 100644 index 0000000..1e1ad19 --- /dev/null +++ b/node_api/src/entities/IcrService.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrService { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + ServerId!: IType; + Address?: string; + Port!: number; + Domain?: string; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrServiceSchema = defineEntity({ + class: IcrService, + comment: '服务', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('姓名'), + ServerId: p.bigint().name('ServerId').columnType('bigint').comment('服务器id'), + Address: p.string().name('Address').nullable().comment('地址'), + Port: p.integer().name('Port').comment('端口'), + Domain: p.string().name('Domain').nullable().comment('域名'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrTeacherclassroomscheduling.ts b/node_api/src/entities/IcrTeacherclassroomscheduling.ts new file mode 100644 index 0000000..b1133e4 --- /dev/null +++ b/node_api/src/entities/IcrTeacherclassroomscheduling.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrTeacherclassroomscheduling { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TeacherId!: IType; + ClassId!: IType; + WeekNum!: number; + SubjectId!: IType; + Remark?: string; + NextTriggerTime?: Date; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrTeacherclassroomschedulingSchema = defineEntity({ + class: IcrTeacherclassroomscheduling, + comment: '教师课堂排班', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级Id'), + WeekNum: p.integer().name('WeekNum').comment('周几'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('科目'), + Remark: p.string().name('Remark').nullable().comment('备注'), + NextTriggerTime: p.datetime().name('NextTriggerTime').length(3).nullable().comment('下次的触发时间'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrTerminalmessage.ts b/node_api/src/entities/IcrTerminalmessage.ts new file mode 100644 index 0000000..b17e9ec --- /dev/null +++ b/node_api/src/entities/IcrTerminalmessage.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrTerminalmessage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TerminalId!: IType; + TerminalCode?: string; + MessageType!: number; + Status!: number; + Content?: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrTerminalmessageSchema = defineEntity({ + class: IcrTerminalmessage, + comment: '终端消息', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TerminalId: p.bigint().name('TerminalId').columnType('bigint').comment('终端编号'), + TerminalCode: p.string().name('TerminalCode').nullable().comment('终端编码'), + MessageType: p.integer().name('MessageType').comment('消息内容'), + Status: p.integer().name('Status').comment('终端消息状态'), + Content: p.array().name('Content').length(16777215).nullable().comment('消息内容'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrTerminalmonitor.ts b/node_api/src/entities/IcrTerminalmonitor.ts new file mode 100644 index 0000000..7bba425 --- /dev/null +++ b/node_api/src/entities/IcrTerminalmonitor.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrTerminalmonitor { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TerminalCode?: string; + TerminalName?: string; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrTerminalmonitorSchema = defineEntity({ + class: IcrTerminalmonitor, + comment: '终端监控', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TerminalCode: p.string().name('TerminalCode').nullable().comment('终端编码'), + TerminalName: p.string().name('TerminalName').nullable().comment('终端名称'), + Status: p.integer().name('Status').comment('终端状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrTerminalsubscribedclass.ts b/node_api/src/entities/IcrTerminalsubscribedclass.ts new file mode 100644 index 0000000..c71880e --- /dev/null +++ b/node_api/src/entities/IcrTerminalsubscribedclass.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrTerminalsubscribedclass { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TerminalId!: IType; + TerminalCode?: string; + ClassId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrTerminalsubscribedclassSchema = defineEntity({ + class: IcrTerminalsubscribedclass, + comment: '终端订阅的班级', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TerminalId: p.bigint().name('TerminalId').columnType('bigint').comment('终端Id'), + TerminalCode: p.string().name('TerminalCode').nullable().comment('终端Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrTutorroom.ts b/node_api/src/entities/IcrTutorroom.ts new file mode 100644 index 0000000..cd0bd49 --- /dev/null +++ b/node_api/src/entities/IcrTutorroom.ts @@ -0,0 +1,36 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrTutorroom { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + TotalPen!: number; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + TeacherId!: IType & Opt; + TotalStudent: number & Opt = 0; +} + +export const IcrTutorroomSchema = defineEntity({ + class: IcrTutorroom, + comment: '辅导班', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('考场名称'), + TotalPen: p.integer().name('TotalPen').comment('笔的数量'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('管理教师').defaultRaw(`0`), + TotalStudent: p.integer().name('TotalStudent').comment('学生的数量'), + }, +}); diff --git a/node_api/src/entities/IcrUserdotmatrixpen.ts b/node_api/src/entities/IcrUserdotmatrixpen.ts new file mode 100644 index 0000000..728bf95 --- /dev/null +++ b/node_api/src/entities/IcrUserdotmatrixpen.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrUserdotmatrixpen { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + PenId!: IType; + PenSerialNo?: string; + PenType!: number; + UserType!: number; + Remark?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrUserdotmatrixpenSchema = defineEntity({ + class: IcrUserdotmatrixpen, + comment: '学生和点阵笔的关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户Id'), + PenId: p.bigint().name('PenId').columnType('bigint').comment('笔Id'), + PenSerialNo: p.string().name('PenSerialNo').nullable().comment('笔序列号'), + PenType: p.integer().name('PenType').comment('笔用途类型;1. 写 2. 修改'), + UserType: p.integer().name('UserType').comment('用户类型;1 学生 2 教师'), + Remark: p.string().name('Remark').nullable().comment('备注'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrUserservermap.ts b/node_api/src/entities/IcrUserservermap.ts new file mode 100644 index 0000000..3fe3819 --- /dev/null +++ b/node_api/src/entities/IcrUserservermap.ts @@ -0,0 +1,38 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrUserservermap { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserName?: string; + UserId!: IType; + ServerId!: IType; + ExpireDate?: Date; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + ClassId!: IType & Opt; +} + +export const IcrUserservermapSchema = defineEntity({ + class: IcrUserservermap, + comment: '学生和服务器的关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserName: p.string().name('UserName').nullable().comment('姓名'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id'), + ServerId: p.bigint().name('ServerId').columnType('bigint').comment('服务器id'), + ExpireDate: p.datetime().name('ExpireDate').length(3).nullable().comment('过期时间(天)'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/IcrWords.ts b/node_api/src/entities/IcrWords.ts new file mode 100644 index 0000000..028293a --- /dev/null +++ b/node_api/src/entities/IcrWords.ts @@ -0,0 +1,39 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrWords { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + CategoryId!: IType; + BookId!: IType; + ArticleId!: IType; + Content?: string; + RecordTime!: Date; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrWordsSchema = defineEntity({ + class: IcrWords, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + CategoryId: p.bigint().name('CategoryId').columnType('bigint').comment('分类ID'), + BookId: p.bigint().name('BookId').columnType('bigint').comment('书籍Id'), + ArticleId: p.bigint().name('ArticleId').columnType('bigint').comment('文章Id'), + Content: p.string().name('Content').nullable().comment('内容'), + RecordTime: p.datetime().name('RecordTime').length(3).comment('记录时间'), + Type: p.integer().name('Type').comment('类型(1-批注 2-积累)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/IcrWordscategory.ts b/node_api/src/entities/IcrWordscategory.ts new file mode 100644 index 0000000..6249789 --- /dev/null +++ b/node_api/src/entities/IcrWordscategory.ts @@ -0,0 +1,37 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class IcrWordscategory { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + Name?: string; + ParentId?: IType; + Path?: string; + Level!: number; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const IcrWordscategorySchema = defineEntity({ + class: IcrWordscategory, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + Name: p.string().name('Name').nullable().comment('名称'), + ParentId: p.bigint().name('ParentId').columnType('bigint').nullable().comment('父分类ID(用于构建无限层级结构,根分类的ParentId为null)'), + Path: p.string().name('Path').nullable().comment('分类层级路径,使用分隔符分隔的ID路径,如 "1/5/23",便于快速查询和排序'), + Level: p.integer().name('Level').comment('分类层级深度'), + Type: p.integer().name('Type').comment('类型(0:默认 1:普通)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/MeetingUser.ts b/node_api/src/entities/MeetingUser.ts new file mode 100644 index 0000000..5eb85ea --- /dev/null +++ b/node_api/src/entities/MeetingUser.ts @@ -0,0 +1,17 @@ +import { type IType, defineEntity, p } from '@mikro-orm/core'; + +export class MeetingUser { + id!: IType; + longUserId!: IType; + createdAt?: Date; +} + +export const MeetingUserSchema = defineEntity({ + class: MeetingUser, + uniques: [{ name: 'idx_hostUserId', properties: ['longUserId'] }], + properties: { + id: p.bigint().primary().columnType('bigint').unsigned(false).comment('短id'), + longUserId: p.bigint().name('long_user_Id').columnType('bigint').comment('用户的uid').unique('hostUserId'), + createdAt: p.datetime().length(3).nullable().comment('创建时间').defaultRaw(`current_timestamp(3)`), + }, +}); diff --git a/node_api/src/entities/Meetinglog.ts b/node_api/src/entities/Meetinglog.ts new file mode 100644 index 0000000..6255dba --- /dev/null +++ b/node_api/src/entities/Meetinglog.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class Meetinglog { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + MeetingId!: IType; + Speaker?: string; + Content?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const MeetinglogSchema = defineEntity({ + class: Meetinglog, + comment: '会议记录', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + MeetingId: p.bigint().name('MeetingId').columnType('bigint').comment('会议Id'), + Speaker: p.string().name('Speaker').nullable().comment('说话人名称'), + Content: p.string().name('Content').length(1000).nullable().comment('内容'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/OssResource.ts b/node_api/src/entities/OssResource.ts new file mode 100644 index 0000000..e5b3bac --- /dev/null +++ b/node_api/src/entities/OssResource.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class OssResource { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + MainId?: IType; + SoucePath?: string; + Path?: string; + Status!: number; + Type!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const OssResourceSchema = defineEntity({ + class: OssResource, + comment: 'OSS资源表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + MainId: p.bigint().name('MainId').columnType('bigint').nullable().comment('主id'), + SoucePath: p.string().name('SoucePath').length(3000).nullable().comment('原路径'), + Path: p.string().name('Path').length(5000).nullable().comment('路径'), + Status: p.integer().name('Status').comment('状态:0默认 1有效 -1失效'), + Type: p.integer().name('Type').comment('共用桶情况类型(0-测试资源 1-正式资源)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/PrismaMigrations.ts b/node_api/src/entities/PrismaMigrations.ts new file mode 100644 index 0000000..1968a5a --- /dev/null +++ b/node_api/src/entities/PrismaMigrations.ts @@ -0,0 +1,27 @@ +import { type Opt, defineEntity, p } from '@mikro-orm/core'; + +export class PrismaMigrations { + id!: string; + checksum!: string; + finishedAt?: Date; + migrationName!: string; + logs?: string; + rolledBackAt?: Date; + startedAt!: Date & Opt; + appliedStepsCount: number & Opt = 0; +} + +export const PrismaMigrationsSchema = defineEntity({ + class: PrismaMigrations, + tableName: '_prisma_migrations', + properties: { + id: p.string().primary().length(36), + checksum: p.string().length(64), + finishedAt: p.datetime().length(3).nullable(), + migrationName: p.string(), + logs: p.text().length(65535).nullable(), + rolledBackAt: p.datetime().length(3).nullable(), + startedAt: p.datetime().length(3).defaultRaw(`current_timestamp(3)`), + appliedStepsCount: p.integer().unsigned(), + }, +}); diff --git a/node_api/src/entities/ScsAppupdate.ts b/node_api/src/entities/ScsAppupdate.ts new file mode 100644 index 0000000..aa8ace7 --- /dev/null +++ b/node_api/src/entities/ScsAppupdate.ts @@ -0,0 +1,37 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsAppupdate { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Version?: string; + BuildId!: number; + DownloadUrl?: string; + IsMandatory!: unknown; + Description?: string; + Platform!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsAppupdateSchema = defineEntity({ + class: ScsAppupdate, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Version: p.string().name('Version').nullable().comment('版本号'), + BuildId: p.integer().name('BuildId').comment('打包号'), + DownloadUrl: p.string().name('DownloadUrl').nullable().comment('下载链接'), + IsMandatory: p.array().name('IsMandatory').comment('强制更新'), + Description: p.string().name('Description').nullable().comment('更新描述'), + Platform: p.integer().name('Platform').comment('平台信息 1-iOS 2-Android'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsCarousel.ts b/node_api/src/entities/ScsCarousel.ts new file mode 100644 index 0000000..5f68790 --- /dev/null +++ b/node_api/src/entities/ScsCarousel.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCarousel { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Url?: string; + JumpId?: IType; + JumpType?: number; + Platform!: number; + Type!: number; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCarouselSchema = defineEntity({ + class: ScsCarousel, + comment: '轮播图', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Url: p.string().name('Url').length(200).nullable().comment('图片地址'), + JumpId: p.bigint().name('JumpId').columnType('bigint').nullable().comment('关联id'), + JumpType: p.integer().name('JumpType').nullable().comment('跳转类型(0-消息 1课程 2资源)'), + Platform: p.integer().name('Platform').comment('平台类型(0-手机端 1-PC端)'), + Type: p.integer().name('Type').comment('类型(0-轮播图 1-中间轮播图)'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsClass.ts b/node_api/src/entities/ScsClass.ts new file mode 100644 index 0000000..87dd5bd --- /dev/null +++ b/node_api/src/entities/ScsClass.ts @@ -0,0 +1,44 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsClass { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SchoolId!: IType; + GradeId!: IType; + TeacherId!: IType; + Name?: string; + Grid?: string; + Camera?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Description?: string; + Code?: string; + Type: number & Opt = 0; +} + +export const ScsClassSchema = defineEntity({ + class: ScsClass, + comment: '班级表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('届id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('班主任id'), + Name: p.string().name('Name').length(10).nullable().comment('班级名称'), + Grid: p.string().name('Grid').length(10).nullable().comment('班级座次网格'), + Camera: p.string().name('Camera').nullable().comment('摄像头参数'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Description: p.string().name('Description').nullable().comment('描述'), + Code: p.string().name('Code').nullable().comment('班级编码(两位01-99)').unique('idx_SCS_Class_01'), + Type: p.integer().name('Type').comment('0-普通教室 1-辅导教室'), + }, +}); diff --git a/node_api/src/entities/ScsClasssubject.ts b/node_api/src/entities/ScsClasssubject.ts new file mode 100644 index 0000000..5f3e36a --- /dev/null +++ b/node_api/src/entities/ScsClasssubject.ts @@ -0,0 +1,36 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsClasssubject { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + GradeId!: IType; + ClassId!: IType; + SubjectId!: IType; + SubjectName?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + SchoolId!: IType & Opt; +} + +export const ScsClasssubjectSchema = defineEntity({ + class: ScsClasssubject, + comment: '班-学科关联表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('科目id'), + SubjectName: p.string().name('SubjectName').nullable().comment('科目名称'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id').defaultRaw(`0`), + }, +}); diff --git a/node_api/src/entities/ScsCourse.ts b/node_api/src/entities/ScsCourse.ts new file mode 100644 index 0000000..6bf0a7b --- /dev/null +++ b/node_api/src/entities/ScsCourse.ts @@ -0,0 +1,58 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCourse { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SchoolId!: IType; + SubjectId!: IType; + GradeId!: IType; + GradeLevel!: number; + CourseStatus!: number; + GradeLevelNum!: number; + Cover?: string; + Name?: string; + TeacherId!: IType; + WeekNum!: number; + WeekDay!: number; + CoursewareCount!: number; + KnowledgeCount!: number; + OtherCount!: number; + ViewCount!: number; + DurationSeconds!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCourseSchema = defineEntity({ + class: ScsCourse, + comment: '课程', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届id'), + GradeLevel: p.integer().name('GradeLevel').comment('届比如高(冗余字段)'), + CourseStatus: p.integer().name('CourseStatus').comment('课程状态'), + GradeLevelNum: p.integer().name('GradeLevelNum').comment('届级别编号(高1的1)(冗余字段)'), + Cover: p.string().name('Cover').length(1000).nullable().comment('封面'), + Name: p.string().name('Name').nullable().comment('课程名称'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('讲师id'), + WeekNum: p.integer().name('WeekNum').comment('学习周'), + WeekDay: p.integer().name('WeekDay').comment('星期(星期一)'), + CoursewareCount: p.integer().name('CoursewareCount').comment('课件数量'), + KnowledgeCount: p.integer().name('KnowledgeCount').comment('知识点数量'), + OtherCount: p.integer().name('OtherCount').comment('其他数量'), + ViewCount: p.integer().name('ViewCount').comment('查看量'), + DurationSeconds: p.integer().name('DurationSeconds').comment('课程时长秒'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsCoursepoint.ts b/node_api/src/entities/ScsCoursepoint.ts new file mode 100644 index 0000000..e301577 --- /dev/null +++ b/node_api/src/entities/ScsCoursepoint.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCoursepoint { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + CourseId!: IType; + Content?: string; + TimePoint!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCoursepointSchema = defineEntity({ + class: ScsCoursepoint, + comment: '课程知识点', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + CourseId: p.bigint().name('CourseId').columnType('bigint').comment('课程id'), + Content: p.string().name('Content').length(500).nullable().comment('内容'), + TimePoint: p.integer().name('TimePoint').comment('时间点'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsCourseschedule.ts b/node_api/src/entities/ScsCourseschedule.ts new file mode 100644 index 0000000..f0d7cdd --- /dev/null +++ b/node_api/src/entities/ScsCourseschedule.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCourseschedule { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + AreaName?: string; + GradeName?: string; + ClassGroup?: string; + TimeStart!: string; + TimeEnd!: string; + WeekDay!: number; + SubjectName?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCoursescheduleSchema = defineEntity({ + class: ScsCourseschedule, + comment: '课表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + AreaName: p.string().name('AreaName').nullable().comment('区域名称'), + GradeName: p.string().name('GradeName').nullable().comment('届'), + ClassGroup: p.string().name('ClassGroup').nullable().comment('班级分组'), + TimeStart: p.time().name('TimeStart').comment('开始时间'), + TimeEnd: p.time().name('TimeEnd').comment('结束时间'), + WeekDay: p.integer().name('WeekDay').comment('周几'), + SubjectName: p.string().name('SubjectName').nullable().comment('学科'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsCoursesource.ts b/node_api/src/entities/ScsCoursesource.ts new file mode 100644 index 0000000..2a4d282 --- /dev/null +++ b/node_api/src/entities/ScsCoursesource.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCoursesource { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + CourseId!: IType; + Name?: string; + Type!: number; + Extension?: string; + Url?: string; + ExpireTime?: Date; + VideoId?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCoursesourceSchema = defineEntity({ + class: ScsCoursesource, + comment: '课程资源', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + CourseId: p.bigint().name('CourseId').columnType('bigint').comment('课程id'), + Name: p.string().name('Name').nullable().comment('名称'), + Type: p.integer().name('Type').comment('类型'), + Extension: p.string().name('Extension').nullable().comment('文件扩展名称'), + Url: p.string().name('Url').length(1000).nullable().comment('文件地址'), + ExpireTime: p.datetime().name('ExpireTime').length(3).nullable().comment('失效时间'), + VideoId: p.string().name('VideoId').nullable().comment('视频Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsCoursesourceconvert.ts b/node_api/src/entities/ScsCoursesourceconvert.ts new file mode 100644 index 0000000..27c03c4 --- /dev/null +++ b/node_api/src/entities/ScsCoursesourceconvert.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsCoursesourceconvert { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + CourseId!: IType; + CourseSouceId!: IType; + FileType!: number; + Order!: number; + Extension?: string; + Urls?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsCoursesourceconvertSchema = defineEntity({ + class: ScsCoursesourceconvert, + comment: '课程资源', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + CourseId: p.bigint().name('CourseId').columnType('bigint').comment('课程id'), + CourseSouceId: p.bigint().name('CourseSouceId').columnType('bigint').comment('课程资源id'), + FileType: p.integer().name('FileType').comment('文件类型'), + Order: p.integer().name('Order').comment('排序'), + Extension: p.string().name('Extension').nullable().comment('文件扩展名'), + Urls: p.string().name('Urls').length(6000).nullable().comment('文件地址列表'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsDictionary.ts b/node_api/src/entities/ScsDictionary.ts new file mode 100644 index 0000000..e0da529 --- /dev/null +++ b/node_api/src/entities/ScsDictionary.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsDictionary { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + CategoryId!: IType; + Code?: string; + Name?: string; + Value?: string; + Description?: string; + Enabled!: unknown; + Sort!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsDictionarySchema = defineEntity({ + class: ScsDictionary, + comment: '数据字典', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + CategoryId: p.bigint().name('CategoryId').columnType('bigint').comment('分类id'), + Code: p.string().name('Code').length(20).nullable().comment('编码'), + Name: p.string().name('Name').length(20).nullable().comment('名称'), + Value: p.string().name('Value').nullable().comment('值'), + Description: p.string().name('Description').length(100).nullable().comment('说明'), + Enabled: p.array().name('Enabled').comment('启用'), + Sort: p.integer().name('Sort').comment('排序'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsDictionarycategory.ts b/node_api/src/entities/ScsDictionarycategory.ts new file mode 100644 index 0000000..3b0526e --- /dev/null +++ b/node_api/src/entities/ScsDictionarycategory.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsDictionarycategory { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Code?: string; + Description?: string; + Enabled!: unknown; + Sort!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsDictionarycategorySchema = defineEntity({ + class: ScsDictionarycategory, + comment: '数据字典分类', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').length(20).nullable().comment('名称'), + Code: p.string().name('Code').length(20).nullable().comment('编码'), + Description: p.string().name('Description').length(100).nullable().comment('描述'), + Enabled: p.array().name('Enabled').comment('启用'), + Sort: p.integer().name('Sort').comment('排序'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsFeature.ts b/node_api/src/entities/ScsFeature.ts new file mode 100644 index 0000000..0e52979 --- /dev/null +++ b/node_api/src/entities/ScsFeature.ts @@ -0,0 +1,40 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsFeature { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Title?: string; + Subtitle?: string; + Icon?: string; + Sort!: number; + Enable!: unknown; + Type!: number; + MessageId?: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsFeatureSchema = defineEntity({ + class: ScsFeature, + comment: '云校特色', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Title: p.string().name('Title').nullable().comment('标题'), + Subtitle: p.string().name('Subtitle').nullable().comment('副标题'), + Icon: p.string().name('Icon').nullable().comment('图标'), + Sort: p.integer().name('Sort').comment('序号'), + Enable: p.array().name('Enable').comment('启用'), + Type: p.integer().name('Type').comment('类型(0-特色 1-纯图片 2-板块)'), + MessageId: p.bigint().name('MessageId').columnType('bigint').nullable().comment('消息Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsGrade.ts b/node_api/src/entities/ScsGrade.ts new file mode 100644 index 0000000..0314740 --- /dev/null +++ b/node_api/src/entities/ScsGrade.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsGrade { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SchoolId!: IType; + Year!: number; + Name?: string; + Level!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Code?: string; +} + +export const ScsGradeSchema = defineEntity({ + class: ScsGrade, + comment: '届表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id'), + Year: p.integer().name('Year').comment('届'), + Name: p.string().name('Name').length(20).nullable().comment('届名称'), + Level: p.integer().name('Level').comment('届级别'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Code: p.string().name('Code').nullable().comment('届编码(01-99)'), + }, +}); diff --git a/node_api/src/entities/ScsManager.ts b/node_api/src/entities/ScsManager.ts new file mode 100644 index 0000000..62629a4 --- /dev/null +++ b/node_api/src/entities/ScsManager.ts @@ -0,0 +1,42 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsManager { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Account?: string; + Name?: string; + Pwd?: string; + Phone?: string; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + UnionId?: string; + MpOpenId?: string; + ServiceOpenId?: string; +} + +export const ScsManagerSchema = defineEntity({ + class: ScsManager, + comment: '管理员表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Account: p.string().name('Account').length(30).nullable().comment('编号'), + Name: p.string().name('Name').length(30).nullable().comment('用户名'), + Pwd: p.string().name('Pwd').length(20).nullable().comment('用户密码'), + Phone: p.string().name('Phone').length(20).nullable().comment('用户电话'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + UnionId: p.string().name('UnionId').length(100).nullable().comment('UnionId'), + MpOpenId: p.string().name('MpOpenId').length(100).nullable().comment('小程序OpenId'), + ServiceOpenId: p.string().name('ServiceOpenId').length(100).nullable().comment('服务号OpenId'), + }, +}); diff --git a/node_api/src/entities/ScsManagerrole.ts b/node_api/src/entities/ScsManagerrole.ts new file mode 100644 index 0000000..fe21001 --- /dev/null +++ b/node_api/src/entities/ScsManagerrole.ts @@ -0,0 +1,30 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsManagerrole { + [PrimaryKeyProp]?: ['Id', 'ManagerId', 'RoleId']; + Id!: IType; + ManagerId!: IType; + RoleId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsManagerroleSchema = defineEntity({ + class: ScsManagerrole, + comment: '管理角色表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).comment('主键Id'), + ManagerId: p.bigint().primary().name('ManagerId').columnType('bigint').unsigned(false).comment('管理员id'), + RoleId: p.bigint().primary().name('RoleId').columnType('bigint').unsigned(false).comment('角色id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsNetdisk.ts b/node_api/src/entities/ScsNetdisk.ts new file mode 100644 index 0000000..41ff866 --- /dev/null +++ b/node_api/src/entities/ScsNetdisk.ts @@ -0,0 +1,44 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsNetdisk { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ParentId!: IType; + UserId!: IType; + Name?: string; + Size!: IType; + Type?: string; + Hash?: string; + Folder!: unknown; + Path?: string; + Sort!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsNetdiskSchema = defineEntity({ + class: ScsNetdisk, + comment: '文件收藏', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ParentId: p.bigint().name('ParentId').columnType('bigint').comment('父ID').index('idx_SCS_NetDisk_01'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id').index('idx_SCS_NetDisk_02'), + Name: p.string().name('Name').nullable().comment('文件/文件夹名称').index('idx_SCS_NetDisk_03'), + Size: p.bigint().name('Size').columnType('bigint').comment('文件/文件夹大小'), + Type: p.string().name('Type').nullable().comment('文件类型'), + Hash: p.string().name('Hash').nullable().comment('文件哈希值'), + Folder: p.array().name('Folder').comment('是否文件夹'), + Path: p.string().name('Path').nullable().comment('路径'), + Sort: p.integer().name('Sort').comment('排序'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsPermissions.ts b/node_api/src/entities/ScsPermissions.ts new file mode 100644 index 0000000..8933660 --- /dev/null +++ b/node_api/src/entities/ScsPermissions.ts @@ -0,0 +1,49 @@ +import { type IType, type Opt, defineEntity, p } from '@mikro-orm/core'; + +export class ScsPermissions { + id!: IType; + parentid!: IType; + name?: string; + label?: string; + code?: string; + Path?: string; + identification?: string; + icon?: string; + sort!: number; + description?: string; + enabled!: unknown; + revision!: number; + createdby?: IType; + createdtime!: Date; + updatedby?: IType; + updatedtime?: Date; + isdeleted!: unknown; + Type!: number; + Hide!: unknown & Opt; +} + +export const ScsPermissionsSchema = defineEntity({ + class: ScsPermissions, + comment: '权限表', + properties: { + id: p.bigint().primary().columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + parentid: p.bigint().columnType('bigint').comment('父id').index('idx_SCS_Permissions_03'), + name: p.string().length(20).nullable().comment('菜单名称'), + label: p.string().length(50).nullable().comment('路由名称').index('idx_SCS_Permissions_01'), + code: p.string().length(50).nullable().comment('路由路径').index('idx_SCS_Permissions_02'), + Path: p.string().name('Path').length(100).nullable().comment('组件路径'), + identification: p.string().length(20).nullable().comment('权限标识'), + icon: p.string().nullable().comment('图标'), + sort: p.integer().comment('排序'), + description: p.string().nullable().comment('描述'), + enabled: p.array().comment('启用'), + revision: p.integer().comment('乐观锁'), + createdby: p.bigint().columnType('bigint').nullable().comment('创建者用户Id'), + createdtime: p.datetime().length(3).comment('创建时间'), + updatedby: p.bigint().columnType('bigint').nullable().comment('修改者用户Id'), + updatedtime: p.datetime().length(3).nullable().comment('修改时间'), + isdeleted: p.array().comment('是否删除'), + Type: p.integer().name('Type').comment('类型'), + Hide: p.array().name('Hide').comment('隐藏').defaultRaw(`b'0'`), + }, +}); diff --git a/node_api/src/entities/ScsResourceconvert.ts b/node_api/src/entities/ScsResourceconvert.ts new file mode 100644 index 0000000..ac2048c --- /dev/null +++ b/node_api/src/entities/ScsResourceconvert.ts @@ -0,0 +1,42 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsResourceconvert { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + SourceResourceId!: IType; + ResourcePath?: string; + ConvertStatus!: number; + ResourceType!: number; + TargetType!: number; + ConvertedResourcePathPrefix?: string; + Number!: number; + FailMessage?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsResourceconvertSchema = defineEntity({ + class: ScsResourceconvert, + comment: '资源转换', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + SourceResourceId: p.bigint().name('SourceResourceId').columnType('bigint').comment('原资源id'), + ResourcePath: p.string().name('ResourcePath').length(1000).nullable().comment('资源路径'), + ConvertStatus: p.integer().name('ConvertStatus').comment('转换状态;1默认 2转换任务成功 -2转换任务失败 3转换成功 -3转换失败'), + ResourceType: p.integer().name('ResourceType').comment('资源类型'), + TargetType: p.integer().name('TargetType').comment('目标类型;目前是1-png'), + ConvertedResourcePathPrefix: p.string().name('ConvertedResourcePathPrefix').nullable().comment('转换后的路径前缀,假设是目录 尾缀带有/'), + Number: p.integer().name('Number').comment('转换之后文件夹文件数量'), + FailMessage: p.string().name('FailMessage').nullable().comment('转换失败信息'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsRole.ts b/node_api/src/entities/ScsRole.ts new file mode 100644 index 0000000..3c0b581 --- /dev/null +++ b/node_api/src/entities/ScsRole.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsRole { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Code?: string; + Name?: string; + Description?: string; + Nick?: string; + Sort!: number; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsRoleSchema = defineEntity({ + class: ScsRole, + comment: '角色表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Code: p.string().name('Code').length(20).nullable().comment('角色编码').index('idx_SCS_Role_01'), + Name: p.string().name('Name').length(20).nullable().comment('角色名称').index('idx_SCS_Role_02'), + Description: p.string().name('Description').nullable().comment('注释'), + Nick: p.string().name('Nick').nullable().comment('角色别称'), + Sort: p.integer().name('Sort').comment('排序'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsRolepermissions.ts b/node_api/src/entities/ScsRolepermissions.ts new file mode 100644 index 0000000..12d4c9a --- /dev/null +++ b/node_api/src/entities/ScsRolepermissions.ts @@ -0,0 +1,30 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsRolepermissions { + [PrimaryKeyProp]?: ['id', 'roleid', 'permissionsid']; + id!: IType; + roleid!: IType; + permissionsid!: IType; + revision!: number; + createdby?: IType; + createdtime!: Date; + updatedby?: IType; + updatedtime?: Date; + isdeleted!: unknown; +} + +export const ScsRolepermissionsSchema = defineEntity({ + class: ScsRolepermissions, + comment: '角色权限表', + properties: { + id: p.bigint().primary().columnType('bigint').unsigned(false).comment('主键Id'), + roleid: p.bigint().primary().columnType('bigint').unsigned(false).comment('角色id'), + permissionsid: p.bigint().primary().columnType('bigint').unsigned(false).comment('权限id'), + revision: p.integer().comment('乐观锁'), + createdby: p.bigint().columnType('bigint').nullable().comment('创建者用户Id'), + createdtime: p.datetime().length(3).comment('创建时间'), + updatedby: p.bigint().columnType('bigint').nullable().comment('修改者用户Id'), + updatedtime: p.datetime().length(3).nullable().comment('修改时间'), + isdeleted: p.array().comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsSchool.ts b/node_api/src/entities/ScsSchool.ts new file mode 100644 index 0000000..af49b50 --- /dev/null +++ b/node_api/src/entities/ScsSchool.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsSchool { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + Code?: string; + ShortName?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsSchoolSchema = defineEntity({ + class: ScsSchool, + comment: '学校表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').length(50).nullable().comment('学校名称'), + Code: p.string().name('Code').nullable().comment('学校编码(01-99)').unique('idx_SCS_School_01'), + ShortName: p.string().name('ShortName').length(20).nullable().comment('学校简称'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsSitemessage.ts b/node_api/src/entities/ScsSitemessage.ts new file mode 100644 index 0000000..13ff78c --- /dev/null +++ b/node_api/src/entities/ScsSitemessage.ts @@ -0,0 +1,38 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsSitemessage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Title?: string; + Description?: string; + Content?: string; + IsImportant!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Status: number & Opt = 0; + Type: number & Opt = 0; +} + +export const ScsSitemessageSchema = defineEntity({ + class: ScsSitemessage, + comment: '系统消息', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Title: p.string().name('Title').length(100).nullable().comment('消息标题'), + Description: p.string().name('Description').length(500).nullable().comment('描述'), + Content: p.string().name('Content').length(20000).nullable().comment('消息内容'), + IsImportant: p.array().name('IsImportant').comment('是否重要'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Status: p.integer().name('Status').comment('发布状态(0未发布 1已发布 -1已撤回)'), + Type: p.integer().name('Type').comment('类型0-富文本消息 1-url消息'), + }, +}); diff --git a/node_api/src/entities/ScsSource.ts b/node_api/src/entities/ScsSource.ts new file mode 100644 index 0000000..f009da9 --- /dev/null +++ b/node_api/src/entities/ScsSource.ts @@ -0,0 +1,44 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsSource { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + No!: IType; + PublisherId!: IType; + GradeId!: IType; + SubjectId!: IType; + Name?: string; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + SchoolId!: IType; + ViewNum: number & Opt = 0; + DownNum: number & Opt = 0; +} + +export const ScsSourceSchema = defineEntity({ + class: ScsSource, + comment: '资源包', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + No: p.bigint().name('No').columnType('bigint').comment('作品id'), + PublisherId: p.bigint().name('PublisherId').columnType('bigint').comment('上传用户id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('学科id'), + Name: p.string().name('Name').nullable().comment('文件包名称').index('idx_SCS_Source_01'), + Status: p.integer().name('Status').comment('状态'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id(如果学校id)'), + ViewNum: p.integer().name('ViewNum').comment('浏览量'), + DownNum: p.integer().name('DownNum').comment('下载量'), + }, +}); diff --git a/node_api/src/entities/ScsSourcefile.ts b/node_api/src/entities/ScsSourcefile.ts new file mode 100644 index 0000000..960f25c --- /dev/null +++ b/node_api/src/entities/ScsSourcefile.ts @@ -0,0 +1,48 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsSourcefile { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + PublisherId!: IType; + SourceId!: IType; + Name?: string; + DocType?: string; + SourceType!: number; + SubType!: number; + Status!: number; + Url?: string; + ViewNum!: number; + DownNum!: number; + QuestionNum!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsSourcefileSchema = defineEntity({ + class: ScsSourcefile, + comment: '资源文件', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + PublisherId: p.bigint().name('PublisherId').columnType('bigint').comment('上传用户id'), + SourceId: p.bigint().name('SourceId').columnType('bigint').comment('文件包id'), + Name: p.string().name('Name').nullable().comment('文件名称').index('idx_SCS_SourceFile_01'), + DocType: p.string().name('DocType').nullable().comment('文件类型()'), + SourceType: p.integer().name('SourceType').comment('资源类型(试卷 课件 作业)'), + SubType: p.integer().name('SubType').comment('按不同的SourceType类型对应'), + Status: p.integer().name('Status').comment('状态'), + Url: p.string().name('Url').length(1000).nullable().comment('资源地址'), + ViewNum: p.integer().name('ViewNum').comment('浏览量'), + DownNum: p.integer().name('DownNum').comment('下载量'), + QuestionNum: p.integer().name('QuestionNum').comment('题量'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsStudentclass.ts b/node_api/src/entities/ScsStudentclass.ts new file mode 100644 index 0000000..7e0070e --- /dev/null +++ b/node_api/src/entities/ScsStudentclass.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsStudentclass { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassId!: IType; + SchoolId!: IType; + GradeId!: IType; + StudentId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + SubjectIds?: unknown; +} + +export const ScsStudentclassSchema = defineEntity({ + class: ScsStudentclass, + comment: '学生班级关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + SubjectIds: p.array().name('SubjectIds').length(4294967295).nullable().comment('学科ids'), + }, +}); diff --git a/node_api/src/entities/ScsStudenterrorbank.ts b/node_api/src/entities/ScsStudenterrorbank.ts new file mode 100644 index 0000000..5aaa030 --- /dev/null +++ b/node_api/src/entities/ScsStudenterrorbank.ts @@ -0,0 +1,35 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsStudenterrorbank { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentId!: IType; + QuestionId!: IType; + AnswerUrl?: string; + Type!: number; + Status!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsStudenterrorbankSchema = defineEntity({ + class: ScsStudenterrorbank, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生id'), + QuestionId: p.bigint().name('QuestionId').columnType('bigint').comment('问题id'), + AnswerUrl: p.string().name('AnswerUrl').nullable().comment('回答图片地址'), + Type: p.integer().name('Type').comment('问题来源(1-互动课堂 2-作业)'), + Status: p.integer().name('Status').comment('状态 0:未学会 1:已学会'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsStudentgroup.ts b/node_api/src/entities/ScsStudentgroup.ts new file mode 100644 index 0000000..c58d089 --- /dev/null +++ b/node_api/src/entities/ScsStudentgroup.ts @@ -0,0 +1,36 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsStudentgroup { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Name?: string; + TotalStudent!: number; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + TeacherId!: IType & Opt; + Type: number & Opt = 0; +} + +export const ScsStudentgroupSchema = defineEntity({ + class: ScsStudentgroup, + comment: '学生分组', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Name: p.string().name('Name').nullable().comment('模板名称'), + TotalStudent: p.integer().name('TotalStudent').comment('学生人数'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('管理教师Id').defaultRaw(`0`).index('idx_SCS_StudentGroup_01'), + Type: p.integer().name('Type').comment('0:普通分组 1:辅导班分组'), + }, +}); diff --git a/node_api/src/entities/ScsStudentgroupdetail.ts b/node_api/src/entities/ScsStudentgroupdetail.ts new file mode 100644 index 0000000..bb05e33 --- /dev/null +++ b/node_api/src/entities/ScsStudentgroupdetail.ts @@ -0,0 +1,30 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsStudentgroupdetail { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + StudentGroupId!: IType; + StudentId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsStudentgroupdetailSchema = defineEntity({ + class: ScsStudentgroupdetail, + comment: '学生分组详情', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + StudentGroupId: p.bigint().name('StudentGroupId').columnType('bigint').comment('模板id').index('idx_SCS_StudentGroupDetail_01'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生Id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsStudentparent.ts b/node_api/src/entities/ScsStudentparent.ts new file mode 100644 index 0000000..30defc1 --- /dev/null +++ b/node_api/src/entities/ScsStudentparent.ts @@ -0,0 +1,31 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsStudentparent { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ParentId!: IType; + StudentId!: IType; + Default!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsStudentparentSchema = defineEntity({ + class: ScsStudentparent, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ParentId: p.bigint().name('ParentId').columnType('bigint').comment('家长id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生id'), + Default: p.array().name('Default').comment('默认'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsSubject.ts b/node_api/src/entities/ScsSubject.ts new file mode 100644 index 0000000..7497c6c --- /dev/null +++ b/node_api/src/entities/ScsSubject.ts @@ -0,0 +1,34 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsSubject { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + Code?: string; + Name?: string; + ShortName?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + Type: number & Opt = 1; +} + +export const ScsSubjectSchema = defineEntity({ + class: ScsSubject, + comment: '学科', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + Code: p.string().name('Code').nullable().comment('学科编码'), + Name: p.string().name('Name').nullable().comment('学科名称(来源字典)'), + ShortName: p.string().name('ShortName').nullable().comment('学科简称(来源字典)'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + Type: p.integer().name('Type').comment('学科类型'), + }, +}); diff --git a/node_api/src/entities/ScsTeacherclass.ts b/node_api/src/entities/ScsTeacherclass.ts new file mode 100644 index 0000000..72fede5 --- /dev/null +++ b/node_api/src/entities/ScsTeacherclass.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsTeacherclass { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + ClassId!: IType; + SchoolId!: IType; + GradeId!: IType; + SubjectId!: IType; + TeacherId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsTeacherclassSchema = defineEntity({ + class: ScsTeacherclass, + comment: '教师班级关系', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + ClassId: p.bigint().name('ClassId').columnType('bigint').comment('班级id'), + SchoolId: p.bigint().name('SchoolId').columnType('bigint').comment('学校id'), + GradeId: p.bigint().name('GradeId').columnType('bigint').comment('届id'), + SubjectId: p.bigint().name('SubjectId').columnType('bigint').comment('科目id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsTeacherinfo.ts b/node_api/src/entities/ScsTeacherinfo.ts new file mode 100644 index 0000000..2cff8d7 --- /dev/null +++ b/node_api/src/entities/ScsTeacherinfo.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsTeacherinfo { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TeacherId!: IType; + TeacherName?: string; + TeacherLevel!: number; + Tag?: string; + Profile?: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsTeacherinfoSchema = defineEntity({ + class: ScsTeacherinfo, + comment: '教师信息', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师id').unique('idx_SCS_TeacherInfo_01'), + TeacherName: p.string().name('TeacherName').nullable().comment('教师姓名'), + TeacherLevel: p.integer().name('TeacherLevel').comment('名师级别'), + Tag: p.string().name('Tag').nullable().comment('教师标签'), + Profile: p.array().name('Profile').length(16777215).nullable().comment('教师简介'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsTeacherstudentinfo.ts b/node_api/src/entities/ScsTeacherstudentinfo.ts new file mode 100644 index 0000000..c804277 --- /dev/null +++ b/node_api/src/entities/ScsTeacherstudentinfo.ts @@ -0,0 +1,30 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsTeacherstudentinfo { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + TeacherId!: IType; + StudentId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsTeacherstudentinfoSchema = defineEntity({ + class: ScsTeacherstudentinfo, + comment: '师生关系表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + TeacherId: p.bigint().name('TeacherId').columnType('bigint').comment('教师id'), + StudentId: p.bigint().name('StudentId').columnType('bigint').comment('学生id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUser.ts b/node_api/src/entities/ScsUser.ts new file mode 100644 index 0000000..dbf611b --- /dev/null +++ b/node_api/src/entities/ScsUser.ts @@ -0,0 +1,57 @@ +import { type IType, type Opt, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUser { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + RoleType!: number; + No?: string; + SchoolUserNo?: string; + Name?: string; + Pwd?: string; + Avatar?: string; + Sex!: number; + Phone?: string; + Photo?: string; + Motto?: string; + Remark?: string; + Enabled!: unknown; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; + DotMatrixOnlineStatus: number & Opt = 0; + DotMatrixOnlineTime?: Date; + LastLoginTime?: Date; + ExpireTime!: Date & Opt; +} + +export const ScsUserSchema = defineEntity({ + class: ScsUser, + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + RoleType: p.integer().name('RoleType').comment('角色(学生 普通教师 名师)'), + No: p.string().name('No').length(30).nullable().comment('编号').unique('idx_SCS_User_02'), + SchoolUserNo: p.string().name('SchoolUserNo').nullable().comment('学校内的的工号(学号)'), + Name: p.string().name('Name').length(30).nullable().comment('用户名').index('idx_SCS_User_03'), + Pwd: p.string().name('Pwd').length(20).nullable().comment('用户密码'), + Avatar: p.string().name('Avatar').length(500).nullable().comment('头像'), + Sex: p.integer().name('Sex').comment('性别'), + Phone: p.string().name('Phone').length(20).nullable().comment('电话').index('idx_SCS_User_01'), + Photo: p.string().name('Photo').nullable().comment('照片'), + Motto: p.string().name('Motto').length(100).nullable().comment('座右铭'), + Remark: p.string().name('Remark').length(2000).nullable().comment('备注'), + Enabled: p.array().name('Enabled').comment('启用'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + DotMatrixOnlineStatus: p.integer().name('DotMatrixOnlineStatus').comment('点阵在线状态'), + DotMatrixOnlineTime: p.datetime().name('DotMatrixOnlineTime').length(3).nullable().comment('点阵在线时间'), + LastLoginTime: p.datetime().name('LastLoginTime').length(3).nullable().comment('最后登录时间'), + ExpireTime: p.datetime().name('ExpireTime').length(3).comment('账号过期时间').defaultRaw(`9999-12-31 23:59:59.999`), + }, +}); diff --git a/node_api/src/entities/ScsUsercenter.ts b/node_api/src/entities/ScsUsercenter.ts new file mode 100644 index 0000000..b1006c4 --- /dev/null +++ b/node_api/src/entities/ScsUsercenter.ts @@ -0,0 +1,38 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUsercenter { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + DownCount!: number; + ContributionCount!: number; + UploadCount!: number; + PassCount!: number; + FailCount!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUsercenterSchema = defineEntity({ + class: ScsUsercenter, + comment: '个人中心', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id'), + DownCount: p.integer().name('DownCount').comment('下载量'), + ContributionCount: p.integer().name('ContributionCount').comment('贡献值'), + UploadCount: p.integer().name('UploadCount').comment('上传量'), + PassCount: p.integer().name('PassCount').comment('通过量'), + FailCount: p.integer().name('FailCount').comment('驳回量'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUsercollect.ts b/node_api/src/entities/ScsUsercollect.ts new file mode 100644 index 0000000..f0b763b --- /dev/null +++ b/node_api/src/entities/ScsUsercollect.ts @@ -0,0 +1,32 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUsercollect { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + CollectType!: number; + FCId!: IType; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUsercollectSchema = defineEntity({ + class: ScsUsercollect, + comment: '用户收藏', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id'), + CollectType: p.integer().name('CollectType').comment('收藏类型'), + FCId: p.bigint().name('FCId').columnType('bigint').comment('文件或课程id'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUsercourserecord.ts b/node_api/src/entities/ScsUsercourserecord.ts new file mode 100644 index 0000000..bb7f543 --- /dev/null +++ b/node_api/src/entities/ScsUsercourserecord.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUsercourserecord { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + CourseId!: IType; + ViewTime!: number; + ViewTotal!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUsercourserecordSchema = defineEntity({ + class: ScsUsercourserecord, + comment: '课程观看记录', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id'), + CourseId: p.bigint().name('CourseId').columnType('bigint').comment('课程id'), + ViewTime: p.integer().name('ViewTime').comment('观看时间'), + ViewTotal: p.integer().name('ViewTotal').comment('观看次数'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUsermessage.ts b/node_api/src/entities/ScsUsermessage.ts new file mode 100644 index 0000000..500bd01 --- /dev/null +++ b/node_api/src/entities/ScsUsermessage.ts @@ -0,0 +1,36 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUsermessage { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId!: IType; + Title?: string; + IsRead!: number; + ReadTime!: Date; + IsImportant!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUsermessageSchema = defineEntity({ + class: ScsUsermessage, + comment: '用户消息表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').comment('用户id'), + Title: p.string().name('Title').nullable().comment('消息'), + IsRead: p.integer().name('IsRead').comment('是否已读'), + ReadTime: p.datetime().name('ReadTime').length(3).comment('已读时间'), + IsImportant: p.integer().name('IsImportant').comment('是否重要'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUsernopool.ts b/node_api/src/entities/ScsUsernopool.ts new file mode 100644 index 0000000..c3089e8 --- /dev/null +++ b/node_api/src/entities/ScsUsernopool.ts @@ -0,0 +1,28 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUsernopool { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + CurrentNumber!: number; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUsernopoolSchema = defineEntity({ + class: ScsUsernopool, + comment: '用户编码池', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + CurrentNumber: p.integer().name('CurrentNumber').comment('当前数字'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +}); diff --git a/node_api/src/entities/ScsUserwechat.ts b/node_api/src/entities/ScsUserwechat.ts new file mode 100644 index 0000000..74974b3 --- /dev/null +++ b/node_api/src/entities/ScsUserwechat.ts @@ -0,0 +1,34 @@ +import { type IType, PrimaryKeyProp, defineEntity, p } from '@mikro-orm/core'; + +export class ScsUserwechat { + [PrimaryKeyProp]?: 'Id'; + Id!: IType; + UserId?: IType; + UnionId?: string; + MpOpenId?: string; + ServiceOpenId?: string; + Revision!: number; + CreatedBy?: IType; + CreatedTime!: Date; + UpdatedBy?: IType; + UpdatedTime?: Date; + IsDeleted!: unknown; +} + +export const ScsUserwechatSchema = defineEntity({ + class: ScsUserwechat, + comment: '用户微信信息表', + properties: { + Id: p.bigint().primary().name('Id').columnType('bigint').unsigned(false).autoincrement(false).comment('主键Id'), + UserId: p.bigint().name('UserId').columnType('bigint').nullable().comment('用Id'), + UnionId: p.string().name('UnionId').nullable().comment('UnionId'), + MpOpenId: p.string().name('MpOpenId').nullable().comment('小程序OpenId'), + ServiceOpenId: p.string().name('ServiceOpenId').nullable().comment('服务号OpenId'), + Revision: p.integer().name('Revision').comment('乐观锁'), + CreatedBy: p.bigint().name('CreatedBy').columnType('bigint').nullable().comment('创建者用户Id'), + CreatedTime: p.datetime().name('CreatedTime').length(3).comment('创建时间'), + UpdatedBy: p.bigint().name('UpdatedBy').columnType('bigint').nullable().comment('修改者用户Id'), + UpdatedTime: p.datetime().name('UpdatedTime').length(3).nullable().comment('修改时间'), + IsDeleted: p.array().name('IsDeleted').comment('是否删除'), + }, +});