4 changed files with 304 additions and 93 deletions
@ -0,0 +1,143 @@ |
|||||
|
/* eslint-disable*/ |
||||
|
|
||||
|
'use strict'; |
||||
|
|
||||
|
module.exports = dc => { |
||||
|
const DataTypes = dc.ORM; |
||||
|
const sequelize = dc.orm; |
||||
|
const PatrolRecordIssueHandle = sequelize.define("patrolRecordIssueHandle", { |
||||
|
id: { |
||||
|
type: DataTypes.INTEGER, |
||||
|
allowNull: false, |
||||
|
defaultValue: null, |
||||
|
comment: null, |
||||
|
primaryKey: true, |
||||
|
field: "id", |
||||
|
autoIncrement: true, |
||||
|
unique: "patrol_record_issue_handle_id_uindex" |
||||
|
}, |
||||
|
patrolRecordId: { |
||||
|
type: DataTypes.INTEGER, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "巡检记录id", |
||||
|
primaryKey: false, |
||||
|
field: "patrol_record_id", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
repairPerson: { |
||||
|
type: DataTypes.JSONB, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "维修人", |
||||
|
primaryKey: false, |
||||
|
field: "repair_person", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
repairUnit: { |
||||
|
type: DataTypes.STRING, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "维修单位", |
||||
|
primaryKey: false, |
||||
|
field: "repair_unit", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
startTime: { |
||||
|
type: DataTypes.DATE, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: null, |
||||
|
primaryKey: false, |
||||
|
field: "start_time", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
endTime: { |
||||
|
type: DataTypes.DATE, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: null, |
||||
|
primaryKey: false, |
||||
|
field: "end_time", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
repairAsk: { |
||||
|
type: DataTypes.INTEGER, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "维修要求", |
||||
|
primaryKey: false, |
||||
|
field: "repair_ask", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
checkPerson: { |
||||
|
type: DataTypes.JSONB, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "质检验收人", |
||||
|
primaryKey: false, |
||||
|
field: "check_person", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
state: { |
||||
|
type: DataTypes.INTEGER, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "流程状态 \n1 制定计划 待审核\n2 \n3\n4\n5\n6\n7", |
||||
|
primaryKey: false, |
||||
|
field: "state", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
approvePerson: { |
||||
|
type: DataTypes.JSONB, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "审批人", |
||||
|
primaryKey: false, |
||||
|
field: "approve_person", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
approveDate: { |
||||
|
type: DataTypes.DATE, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "审批日期", |
||||
|
primaryKey: false, |
||||
|
field: "approve_date", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
approveOpinion: { |
||||
|
type: DataTypes.STRING, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "审批意见", |
||||
|
primaryKey: false, |
||||
|
field: "approve_opinion", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
repairDesc: { |
||||
|
type: DataTypes.STRING, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: "维修情况描述", |
||||
|
primaryKey: false, |
||||
|
field: "repair_desc", |
||||
|
autoIncrement: false |
||||
|
}, |
||||
|
repairImage: { |
||||
|
type: DataTypes.JSONB, |
||||
|
allowNull: true, |
||||
|
defaultValue: null, |
||||
|
comment: null, |
||||
|
primaryKey: false, |
||||
|
field: "repair_image", |
||||
|
autoIncrement: false |
||||
|
} |
||||
|
}, { |
||||
|
tableName: "patrol_record_issue_handle", |
||||
|
comment: "", |
||||
|
indexes: [] |
||||
|
}); |
||||
|
dc.models.PatrolRecordIssueHandle = PatrolRecordIssueHandle; |
||||
|
return PatrolRecordIssueHandle; |
||||
|
}; |
Loading…
Reference in new issue