添加银行政府后端接口

This commit is contained in:
2025-09-25 15:53:44 +08:00
parent b17bdcc24c
commit 5b6b7e0a96
60 changed files with 5345 additions and 1920 deletions

View File

@@ -0,0 +1,41 @@
const sequelize = require('../config/database');
const { DataTypes } = require('sequelize');
const Department = sequelize.define('Department', {
id: {
type: DataTypes.INTEGER,
primaryKey: true,
autoIncrement: true
},
name: {
type: DataTypes.STRING,
allowNull: false,
unique: true,
comment: '部门名称'
},
description: {
type: DataTypes.TEXT,
allowNull: true,
comment: '部门描述'
},
created_by: {
type: DataTypes.INTEGER,
allowNull: true,
comment: '创建人ID'
},
updated_by: {
type: DataTypes.INTEGER,
allowNull: true,
comment: '更新人ID'
}
}, {
tableName: 'government_departments',
indexes: [
{
name: 'idx_department_name',
fields: ['name']
}
]
});
module.exports = Department;