This commit is contained in:
张成
2026-04-01 09:59:54 +08:00
parent aac2d4a8d5
commit 14f5d75d9d
11 changed files with 98 additions and 43 deletions

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_api_call_log = db.define(
"biz_api_call_log",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
user_id: {
type: Sequelize.BIGINT.UNSIGNED,
allowNull: false,

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_api_token = db.define(
"biz_api_token",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
user_id: {
type: Sequelize.BIGINT.UNSIGNED,
allowNull: false,

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_audit_log = db.define(
"biz_audit_log",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
admin_user_id: {
type: Sequelize.BIGINT.UNSIGNED,
allowNull: true,

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_plan = db.define(
"biz_plan",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
plan_code: {
type: Sequelize.STRING(64),
allowNull: false,
@@ -64,6 +60,6 @@ module.exports = (db) => {
comment: "套餐",
}
);
// biz_plan.sync({ alter: true });
// biz_plan.sync({ alter: true });
return biz_plan;
};

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_subscription = db.define(
"biz_subscription",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
user_id: {
type: Sequelize.BIGINT.UNSIGNED,
allowNull: false,

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_usage_monthly = db.define(
"biz_usage_monthly",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
user_id: {
type: Sequelize.BIGINT.UNSIGNED,
allowNull: false,

View File

@@ -4,11 +4,7 @@ module.exports = (db) => {
const biz_user = db.define(
"biz_user",
{
id: {
type: Sequelize.BIGINT.UNSIGNED,
primaryKey: true,
autoIncrement: true,
},
name: {
type: Sequelize.STRING(100),
allowNull: false,