明树Git Lab

Commit d17ecf91 authored by zfp1's avatar zfp1

!

parent cbf980ce
Pipeline #108289 passed with stage
in 3 seconds
......@@ -251,7 +251,7 @@ const workbook = new ExcelJS.Workbook();
workbook.creator = 'Me';
workbook.lastModifiedBy = 'Her';
workbook.created = new Date(1985, 8, 30);
workbook.modified = new Date();
workbook.modified = Date.now;
workbook.lastPrinted = new Date(2016, 9, 27);
```
......@@ -740,7 +740,7 @@ expect(worksheet.getRow(5).collapsed).to.equal(true);
row.getCell(1).value = 5; // A5 的值设置为5
row.getCell('name').value = 'Zeb'; // B5 的值设置为 “Zeb” - 假设第2列仍按名称键入
row.getCell('C').value = new Date(); // C5 的值设置为当前时间
row.getCell('C').value = Date.now; // C5 的值设置为当前时间
// 获取行并作为稀疏数组返回
// 注意:接口更改:worksheet.getRow(4) ==> worksheet.getRow(4).values
......@@ -766,7 +766,7 @@ expect(row.getCell(10).value).toEqual('Hello, World!');
row.values = {
id: 13,
name: 'Thing 1',
dob: new Date()
dob: Date.now
};
// 在该行下方插入一个分页符
......@@ -808,13 +808,13 @@ worksheet.addRow({id: 1, name: 'John Doe', dob: new Date(1970,1,1)});
worksheet.addRow({id: 2, name: 'Jane Doe', dob: new Date(1965,1,7)});
// Add a row by contiguous Array (assign to columns A, B & C)
worksheet.addRow([3, 'Sam', new Date()]);
worksheet.addRow([3, 'Sam', Date.now]);
// Add a row by sparse Array (assign to columns A, E & I)
const rowValues = [];
rowValues[1] = 4;
rowValues[5] = 'Kyle';
rowValues[9] = new Date();
rowValues[9] = Date.now;
worksheet.addRow(rowValues);
// Add a row with inherited style
......@@ -824,8 +824,8 @@ const newRow = worksheet.addRow(rowValues, 'i');
// Add an array of rows
const rows = [
[5,'Bob',new Date()], // row by array
{id:6, name: 'Barbara', dob: new Date()}
[5,'Bob',Date.now], // row by array
{id:6, name: 'Barbara', dob: Date.now}
];
// add new rows and return them as array of row objects
const newRows = worksheet.addRows(rows);
......@@ -898,13 +898,13 @@ worksheet.insertRow(1, {id: 1, name: 'John Doe', dob: new Date(1970,1,1)});
worksheet.insertRow(1, {id: 2, name: 'Jane Doe', dob: new Date(1965,1,7)});
// Insert a row by contiguous Array (assign to columns A, B & C)
worksheet.insertRow(1, [3, 'Sam', new Date()]);
worksheet.insertRow(1, [3, 'Sam', Date.now]);
// Insert a row by sparse Array (assign to columns A, E & I)
var rowValues = [];
rowValues[1] = 4;
rowValues[5] = 'Kyle';
rowValues[9] = new Date();
rowValues[9] = Date.now;
// insert new row and return as row object
const insertedRow = worksheet.insertRow(1, rowValues);
......@@ -920,8 +920,8 @@ const insertedRowOriginal = worksheet.insertRow(1, rowValues, 'o');
// Insert an array of rows, in position 1, shifting down current position 1 and later rows by 2 rows
var rows = [
[5,'Bob',new Date()], // row by array
{id:6, name: 'Barbara', dob: new Date()}
[5,'Bob',Date.now], // row by array
{id:6, name: 'Barbara', dob: Date.now}
];
// insert new rows and return them as array of row objects
const insertedRows = worksheet.insertRows(1, rows);
......
......@@ -304,7 +304,7 @@ const Project = sequelize.define('Project', {
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -312,7 +312,7 @@ const Project = sequelize.define('Project', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -86,7 +86,7 @@ const projectBjtj = sequelize.define('projectBjtj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -94,7 +94,7 @@ const projectBjtj = sequelize.define('projectBjtj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -31,7 +31,7 @@ const projectCwpjbjtj = sequelize.define('projectCwpjbjtj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -39,7 +39,7 @@ const projectCwpjbjtj = sequelize.define('projectCwpjbjtj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -34,7 +34,7 @@ const projectCwpjzb = sequelize.define('projectCwpjzb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -42,7 +42,7 @@ const projectCwpjzb = sequelize.define('projectCwpjzb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -22,7 +22,7 @@ const ProjectExcelData = sequelize.define('ProjectExcelData', {
},
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -30,7 +30,7 @@ const ProjectExcelData = sequelize.define('ProjectExcelData', {
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -24,7 +24,7 @@ const ProjectFile = sequelize.define('ProjectFile', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -32,7 +32,7 @@ const ProjectFile = sequelize.define('ProjectFile', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -31,7 +31,7 @@ const ProjectFxgl = sequelize.define('ProjectFxgl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -39,7 +39,7 @@ const ProjectFxgl = sequelize.define('ProjectFxgl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -69,7 +69,7 @@ const ProjectGdxx = sequelize.define('ProjectGdxx', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -77,7 +77,7 @@ const ProjectGdxx = sequelize.define('ProjectGdxx', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -35,7 +35,7 @@ const ProjectJczt = sequelize.define('ProjectJczt', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -43,7 +43,7 @@ const ProjectJczt = sequelize.define('ProjectJczt', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -35,7 +35,7 @@ const ProjectJsgm = sequelize.define('ProjectJsgm', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -43,7 +43,7 @@ const ProjectJsgm = sequelize.define('ProjectJsgm', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -34,7 +34,7 @@ const ProjectLcbjd = sequelize.define('ProjectLcbjd', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -42,7 +42,7 @@ const ProjectLcbjd = sequelize.define('ProjectLcbjd', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -46,7 +46,7 @@ const ProjectSpyj = sequelize.define('ProjectSpyj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -54,7 +54,7 @@ const ProjectSpyj = sequelize.define('ProjectSpyj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -45,7 +45,7 @@ const ProjectSpyjjc = sequelize.define('ProjectSpyjjc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -53,7 +53,7 @@ const ProjectSpyjjc = sequelize.define('ProjectSpyjjc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -23,7 +23,7 @@ const ProjectTzsyzb = sequelize.define('ProjectTzsyzb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -31,7 +31,7 @@ const ProjectTzsyzb = sequelize.define('ProjectTzsyzb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -25,7 +25,7 @@ const ProjectTzzjll = sequelize.define('ProjectTzzjll', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -33,7 +33,7 @@ const ProjectTzzjll = sequelize.define('ProjectTzzjll', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -31,7 +31,7 @@ const ProjectTzzt = sequelize.define('ProjectTzzt', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -39,7 +39,7 @@ const ProjectTzzt = sequelize.define('ProjectTzzt', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -50,7 +50,7 @@ const ProjectXmtzze = sequelize.define('ProjectXmtzze', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -58,7 +58,7 @@ const ProjectXmtzze = sequelize.define('ProjectXmtzze', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -35,7 +35,7 @@ const QtCbgl = sequelize.define('QtCbgl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -43,7 +43,7 @@ const QtCbgl = sequelize.define('QtCbgl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -43,7 +43,7 @@ const QtCbglzb = sequelize.define('QtCbglzb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -51,7 +51,7 @@ const QtCbglzb = sequelize.define('QtCbglzb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -147,7 +147,7 @@ const RcCgqygl = sequelize.define('RcCgqygl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -155,7 +155,7 @@ const RcCgqygl = sequelize.define('RcCgqygl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -12,7 +12,7 @@ const RcCgqyglTzfh = sequelize.define('RcCgqyglTzfh', {
fhsj: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('fhsj');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -39,7 +39,7 @@ const RcCgqyglTzfh = sequelize.define('RcCgqyglTzfh', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -47,7 +47,7 @@ const RcCgqyglTzfh = sequelize.define('RcCgqyglTzfh', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -16,7 +16,7 @@ const RcCgqyglWtyy = sequelize.define('RcCgqyglWtyy', {
},
fwsj: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('fwsj');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -45,7 +45,7 @@ const RcCgqyglWtyy = sequelize.define('RcCgqyglWtyy', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -53,7 +53,7 @@ const RcCgqyglWtyy = sequelize.define('RcCgqyglWtyy', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -24,7 +24,7 @@ const RcTwhgl = sequelize.define('RcTwhgl', {
type: DataTypes.DATE,
allowNull: false,
comment: '会议时间',
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('meetingDate');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -75,7 +75,7 @@ const RcTwhgl = sequelize.define('RcTwhgl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -83,7 +83,7 @@ const RcTwhgl = sequelize.define('RcTwhgl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -50,7 +50,7 @@ const RcTxjs = sequelize.define('RcTxjs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -58,7 +58,7 @@ const RcTxjs = sequelize.define('RcTxjs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -59,7 +59,7 @@ const RcTzdagl = sequelize.define('RcTzdagl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -67,7 +67,7 @@ const RcTzdagl = sequelize.define('RcTzdagl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -81,7 +81,7 @@ const RcTzgh = sequelize.define('RcTzgh', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -89,7 +89,7 @@ const RcTzgh = sequelize.define('RcTzgh', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -218,7 +218,7 @@ const RcTzjh = sequelize.define('RcTzjh', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -226,7 +226,7 @@ const RcTzjh = sequelize.define('RcTzjh', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -57,7 +57,7 @@ const RcXxbs = sequelize.define('RcXxbs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -65,7 +65,7 @@ const RcXxbs = sequelize.define('RcXxbs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -49,7 +49,7 @@ const RcXxhjs = sequelize.define('RcXxhjs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -57,7 +57,7 @@ const RcXxhjs = sequelize.define('RcXxhjs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -38,7 +38,7 @@ const Resources = sequelize.define('Resources', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -46,7 +46,7 @@ const Resources = sequelize.define('Resources', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -82,7 +82,7 @@ const ThTzhpj = sequelize.define('ThTzhpj', {
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -90,7 +90,7 @@ const ThTzhpj = sequelize.define('ThTzhpj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -60,7 +60,7 @@ const ThTzhpjwtzg = sequelize.define('ThTzhpjwtzg', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -68,7 +68,7 @@ const ThTzhpjwtzg = sequelize.define('ThTzhpjwtzg', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -42,7 +42,7 @@ const ThYjgl = sequelize.define('ThYjgl', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -50,7 +50,7 @@ const ThYjgl = sequelize.define('ThYjgl', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -117,7 +117,7 @@ const ThYyqtzhs = sequelize.define('ThYyqtzhs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -125,7 +125,7 @@ const ThYyqtzhs = sequelize.define('ThYyqtzhs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -64,7 +64,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -72,7 +72,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -52,7 +52,7 @@ const ThYyqtzjc = sequelize.define('ThYyqtzjc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -60,7 +60,7 @@ const ThYyqtzjc = sequelize.define('ThYyqtzjc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -46,7 +46,7 @@ const ThYyqtzjcTzfx = sequelize.define('ThYyqtzjcTzfx', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -54,7 +54,7 @@ const ThYyqtzjcTzfx = sequelize.define('ThYyqtzjcTzfx', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -61,7 +61,7 @@ const ThYyqtzjcZxjc = sequelize.define('ThYyqtzjcZxjc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -69,7 +69,7 @@ const ThYyqtzjcZxjc = sequelize.define('ThYyqtzjcZxjc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -49,7 +49,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -57,7 +57,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -117,7 +117,7 @@ const TzJsqtzhs = sequelize.define('TzJsqtzhs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -125,7 +125,7 @@ const TzJsqtzhs = sequelize.define('TzJsqtzhs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -63,7 +63,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -71,7 +71,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -50,7 +50,7 @@ const TzJsqtzjc = sequelize.define('TzJsqtzjc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -58,7 +58,7 @@ const TzJsqtzjc = sequelize.define('TzJsqtzjc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -43,7 +43,7 @@ const TzJsqtzjcTzfx = sequelize.define('TzJsqtzjcTzfx', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -51,7 +51,7 @@ const TzJsqtzjcTzfx = sequelize.define('TzJsqtzjcTzfx', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -60,7 +60,7 @@ const TzJsqtzjcZxjc = sequelize.define('TzJsqtzjcZxjc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -68,7 +68,7 @@ const TzJsqtzjcZxjc = sequelize.define('TzJsqtzjcZxjc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -49,7 +49,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -57,7 +57,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -23,7 +23,7 @@ const TzTzkz = sequelize.define('TzTzkz', {
},
xdpfsj: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('xdpfsj');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -53,7 +53,7 @@ const TzTzkz = sequelize.define('TzTzkz', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -61,7 +61,7 @@ const TzTzkz = sequelize.define('TzTzkz', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -42,7 +42,7 @@ const TzTzkzAqzlhb = sequelize.define('TzTzkzAqzlhb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -50,7 +50,7 @@ const TzTzkzAqzlhb = sequelize.define('TzTzkzAqzlhb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -40,7 +40,7 @@ const TzTzkzCwpj = sequelize.define('TzTzkzCwpj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -48,7 +48,7 @@ const TzTzkzCwpj = sequelize.define('TzTzkzCwpj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -74,7 +74,7 @@ const TzTzkzGq = sequelize.define('TzTzkzGq', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -82,7 +82,7 @@ const TzTzkzGq = sequelize.define('TzTzkzGq', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -24,7 +24,7 @@ const TzTzkzJcpfyj = sequelize.define('TzTzkzJcpfyj', {
// },
// xdpfsj: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('xdpfsj');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -106,7 +106,7 @@ const TzTzkzJcpfyj = sequelize.define('TzTzkzJcpfyj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -114,7 +114,7 @@ const TzTzkzJcpfyj = sequelize.define('TzTzkzJcpfyj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -99,7 +99,7 @@ const TzTzkzTzekz = sequelize.define('TzTzkzTzekz', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -107,7 +107,7 @@ const TzTzkzTzekz = sequelize.define('TzTzkzTzekz', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -35,7 +35,7 @@ const TzTzkzTzsy = sequelize.define('TzTzkzTzsy', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -43,7 +43,7 @@ const TzTzkzTzsy = sequelize.define('TzTzkzTzsy', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -76,7 +76,7 @@ const TzTzmbzrs = sequelize.define('TzTzmbzrs', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -84,7 +84,7 @@ const TzTzmbzrs = sequelize.define('TzTzmbzrs', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -40,7 +40,7 @@ const TzTzmbzrsNd = sequelize.define('TzTzmbzrsNd', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -48,7 +48,7 @@ const TzTzmbzrsNd = sequelize.define('TzTzmbzrsNd', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -56,7 +56,7 @@ const TzTzmbzrsPfyj = sequelize.define('TzTzmbzrsPfyj', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -64,7 +64,7 @@ const TzTzmbzrsPfyj = sequelize.define('TzTzmbzrsPfyj', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -62,7 +62,7 @@ const TzTzmbzrsZb = sequelize.define('TzTzmbzrsZb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -70,7 +70,7 @@ const TzTzmbzrsZb = sequelize.define('TzTzmbzrsZb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -102,7 +102,7 @@ const TzXmtc = sequelize.define('TzXmtc', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -110,7 +110,7 @@ const TzXmtc = sequelize.define('TzXmtc', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -35,7 +35,7 @@ const TzXmtcCwzb = sequelize.define('TzXmtcCwzb', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -43,7 +43,7 @@ const TzXmtcCwzb = sequelize.define('TzXmtcCwzb', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -130,7 +130,7 @@ const TzZdfx = sequelize.define('TzZdfx', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -138,7 +138,7 @@ const TzZdfx = sequelize.define('TzZdfx', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -46,7 +46,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -54,7 +54,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -83,7 +83,7 @@ const TzZdfxcz = sequelize.define('TzZdfxcz', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -91,7 +91,7 @@ const TzZdfxcz = sequelize.define('TzZdfxcz', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -62,7 +62,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -70,7 +70,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -64,7 +64,7 @@ const TzZdsxsp = sequelize.define('TzZdsxsp', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -72,7 +72,7 @@ const TzZdsxsp = sequelize.define('TzZdsxsp', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -37,7 +37,7 @@
// },
// createdAt: {
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('createdAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -45,7 +45,7 @@
// },
// updatedAt: { // 同样处理 updatedAt
// type: DataTypes.DATE,
// defaultValue: new Date(),
// defaultValue: Date.now,
// get() {
// const rawValue = this.getDataValue('updatedAt');
// return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -27,7 +27,7 @@ const Depart = sequelize.define('Depart', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -35,7 +35,7 @@ const Depart = sequelize.define('Depart', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -56,7 +56,7 @@ const ExcelRecord = sequelize.define('ExcelRecord', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -64,7 +64,7 @@ const ExcelRecord = sequelize.define('ExcelRecord', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -42,7 +42,7 @@ const File = sequelize.define('File', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -50,7 +50,7 @@ const File = sequelize.define('File', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -37,6 +37,22 @@ const flowRecord = sequelize.define('flowRecord', {
defaultValue: 0,
comment: "0 正常 1 删除"
},
createdAt: {
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
}
}, {
tableName: 'system_flowrecord', // 指定表名(如果与模型名不同)
timestamps: true, // 是否自动添加 createdAt 和 updatedAt 字段(覆盖全局设置)
......
......@@ -54,7 +54,7 @@ const Menu = sequelize.define('Menu', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -62,7 +62,7 @@ const Menu = sequelize.define('Menu', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -51,6 +51,22 @@ const Message = sequelize.define('Message', {
defaultValue: 0,
comment: "0 正常 1 删除"
},
createdAt: {
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
}
}, {
tableName: 'system_message', // 指定表名(如果与模型名不同)
timestamps: true, // 是否自动添加 createdAt 和 updatedAt 字段(覆盖全局设置)
......
......@@ -28,7 +28,7 @@ const Position = sequelize.define('Position', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -36,7 +36,7 @@ const Position = sequelize.define('Position', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -54,6 +54,22 @@ const RequestLog = sequelize.define('User', {
comment: "日志类型 系统内部请求日志:system",
default: "system"
},
createdAt: {
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
}
}
}, {
tableName: 'system_request_log', // 指定表名(如果与模型名不同)
timestamps: true, // 是否自动添加 createdAt 和 updatedAt 字段(覆盖全局设置)
......
......@@ -29,7 +29,7 @@ const Role = sequelize.define('Role', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......@@ -37,7 +37,7 @@ const Role = sequelize.define('Role', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('updatedAt');
return rawValue ? moment(rawValue).format('YYYY-MM-DD HH:mm:ss') : '';
......
......@@ -43,7 +43,7 @@ const User = sequelize.define('User', {
},
createdAt: {
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue? moment(rawValue).format('YYYY-MM-DD HH:mm:ss'): '';
......@@ -51,7 +51,7 @@ const User = sequelize.define('User', {
},
updatedAt: { // 同样处理 updatedAt
type: DataTypes.DATE,
defaultValue: new Date(),
defaultValue: Date.now,
get() {
const rawValue = this.getDataValue('createdAt');
return rawValue? moment(rawValue).format('YYYY-MM-DD HH:mm:ss'): '';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment