const system=require("../../../system");
const settings=require("../../../../config/settings");
const uiconfig=system.getUiConfig2(settings.appKey);
module.exports = (db, DataTypes) => {
  return db.define("saasmerchanttitle", {
    saas_merchant_id: { type: DataTypes.STRING(32), allowNull: false, COMMENT: '商户id' },
    merchant_name: { type: DataTypes.STRING(45), allowNull: false, COMMENT: '商户名称' },
    merchant_credit_code: { type: DataTypes.STRING(45), allowNull: false, COMMENT: '商户纳税人识别号' },
    merchant_tax_type: { type: DataTypes.STRING(4), allowNull: false, COMMENT: '纳税人类型 00一般纳税人 10小规模纳税人' },
    merchant_addr: { type: DataTypes.STRING(45), allowNull: false, COMMENT: '商户地址' },
    merchant_mobile: { type: DataTypes.STRING(45), allowNull: false, COMMENT: '商户电话' },
    merchant_bank: { type: DataTypes.STRING(4), allowNull: true, defaultValue: "", COMMENT: '商户开户行' },
    merchant_account: { type: DataTypes.STRING(32), allowNull: false, COMMENT: '商户银行账号' },
    created_at: { type: DataTypes.DATE, field: 'created_at', allowNull: false },
		updated_at: { type: DataTypes.DATE, field: 'updated_at', allowNull: false},
    deleted_at: { type: DataTypes.DATE, allowNull: true },
  },{
     paranoid: true,//假的删除
     underscored: true,
     version: true,
     freezeTableName: true,
     tableName: 'saas_merchant_title'
  });
}
