rentease-backend-new/models/PaymentSetting.js

84 lines
1.8 KiB
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

const { DataTypes } = require('sequelize');
const sequelize = require('../config/db');
const PaymentSetting = sequelize.define('PaymentSetting', {
id: {
type: DataTypes.INTEGER,
primaryKey: true,
autoIncrement: true,
comment: 'ID'
},
alipayAccount: {
type: DataTypes.STRING(100),
allowNull: true,
comment: '支付宝收款账号'
},
alipayName: {
type: DataTypes.STRING(50),
allowNull: true,
defaultValue: '支付宝',
comment: '支付宝显示名称'
},
wechatId: {
type: DataTypes.STRING(50),
allowNull: true,
comment: '客服微信号'
},
wechatText: {
type: DataTypes.STRING(100),
allowNull: true,
defaultValue: '请添加客服微信',
comment: '微信显示文字'
},
bankName: {
type: DataTypes.STRING(100),
allowNull: true,
comment: '开户行'
},
bankAccount: {
type: DataTypes.STRING(50),
allowNull: true,
comment: '银行账号'
},
bankHolder: {
type: DataTypes.STRING(100),
allowNull: true,
comment: '户名'
},
servicePhone: {
type: DataTypes.STRING(20),
allowNull: true,
comment: '客服电话'
},
serviceTime: {
type: DataTypes.STRING(50),
allowNull: true,
defaultValue: '9:00-18:00',
comment: '工作时间'
},
isDeleted: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: 0,
comment: '删除状态0未删除1已删除'
},
createTime: {
type: DataTypes.DATE,
allowNull: false,
defaultValue: DataTypes.NOW,
comment: '创建时间'
},
updateTime: {
type: DataTypes.DATE,
allowNull: false,
defaultValue: DataTypes.NOW,
comment: '更新时间'
}
}, {
tableName: 'payment_settings',
timestamps: false,
comment: '支付设置表'
});
module.exports = PaymentSetting;