feat: implement managed storage plans and provider settings

- Added new UI schema for managing storage plans, including catalog, pricing, and product configurations.
- Introduced StoragePlanService to handle storage plan operations and integrate with existing billing services.
- Updated SuperAdmin settings to include managed storage provider configurations.
- Enhanced localization files with new keys for storage plan management.
- Implemented API endpoints for fetching and updating storage plans.

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei
2025-11-21 16:23:13 +08:00
parent 914342807d
commit f0678038c2
37 changed files with 3537 additions and 171 deletions

View File

@@ -0,0 +1 @@
ALTER TABLE "tenant" ADD COLUMN "storage_plan_id" text;

File diff suppressed because it is too large Load Diff

View File

@@ -43,6 +43,13 @@
"when": 1763626275917,
"tag": "0005_flawless_wild_pack",
"breakpoints": true
},
{
"idx": 6,
"version": "7",
"when": 1763656041992,
"tag": "0006_quick_titania",
"breakpoints": true
}
]
}

View File

@@ -62,6 +62,7 @@ export const tenants = pgTable(
slug: text('slug').notNull(),
name: text('name').notNull(),
planId: text('plan_id').notNull().default('free'),
storagePlanId: text('storage_plan_id'),
banned: boolean('banned').notNull().default(false),
status: tenantStatusEnum('status').notNull().default('inactive'),
createdAt: timestamp('created_at', { mode: 'string' }).defaultNow().notNull(),