/* eslint-disable*/ 'use strict'; module.exports = dc => { const DataTypes = dc.ORM; const sequelize = dc.orm; const PlagiarismCheckTasks = sequelize.define('plagiarismCheckTasks', { id: { type: DataTypes.BIGINT, allowNull: false, primaryKey: true, autoIncrement: true, field: 'id' }, threshold: { type: DataTypes.INTEGER, allowNull: false, field: 'threshold' }, status: { type: DataTypes.STRING(32), allowNull: false, defaultValue: 'created', field: 'status' }, statusText: { type: DataTypes.STRING(64), allowNull: false, defaultValue: '待解析', field: 'status_text' }, fileCount: { type: DataTypes.INTEGER, allowNull: false, defaultValue: 0, field: 'file_count' }, parsedFileCount: { type: DataTypes.INTEGER, allowNull: false, defaultValue: 0, field: 'parsed_file_count' }, failedFileCount: { type: DataTypes.INTEGER, allowNull: false, defaultValue: 0, field: 'failed_file_count' }, creator: { type: DataTypes.STRING(128), allowNull: true, field: 'creator' }, userId: { type: DataTypes.BIGINT, allowNull: true, field: 'user_id' }, analyticsUserId: { type: DataTypes.STRING(64), allowNull: true, field: 'analytics_user_id' }, errorMessage: { type: DataTypes.TEXT, allowNull: true, field: 'error_message' }, startedAt: { type: DataTypes.DATE, allowNull: true, field: 'started_at' }, finishedAt: { type: DataTypes.DATE, allowNull: true, field: 'finished_at' }, extra: { type: DataTypes.JSONB, allowNull: true, field: 'extra' }, createdAt: { type: DataTypes.DATE, allowNull: false, defaultValue: sequelize.literal('CURRENT_TIMESTAMP'), field: 'created_at' }, updatedAt: { type: DataTypes.DATE, allowNull: false, defaultValue: sequelize.literal('CURRENT_TIMESTAMP'), field: 'updated_at' } }, { tableName: 'plagiarism_check_tasks', comment: '文档查重任务表', timestamps: false, indexes: [] }); dc.models.PlagiarismCheckTasks = PlagiarismCheckTasks; return PlagiarismCheckTasks; };