♻️ refactor(account, order, plan, profile, support, email): restructure application modules and enhance error handling

Updated Docker configuration, refactored middleware for improved error handling, and restructured account, order, plan, profile, and support modules, including their routes, services, and validations. Enhanced email processing queues and utilities for token generation, pagination, and response management to streamline the application architecture and enhance maintainability.
This commit is contained in:
abumahid
2026-04-21 03:12:39 +06:00
parent c881efea0f
commit 0f7af70b90
94 changed files with 2593 additions and 127 deletions
+33
View File
@@ -0,0 +1,33 @@
import { z } from "zod";
const create_plan = z.object({
planName: z.string("Enter the plan name..."),
price: z.number("Enter the plan price..."),
planType: z.enum(["FREE", "STANDARD", "PRO"]),
planDesc: z.string("Enter the plan description..."),
planFeatures: z.union([
z.string(),
z.number(),
z.boolean(),
z.null(),
z.array(z.any()),
z.record(z.string(), z.any())
])
});
const update_plan = z.object({
planName: z.string(),
price: z.number(),
planType: z.enum(["FREE", "STANDARD", "PRO"]),
planDesc: z.string().optional(),
planFeatures: z.union([
z.string(),
z.number(),
z.boolean(),
z.null(),
z.array(z.any()),
z.record(z.string(), z.any())
])
});
export const plan_validations = {
create_plan,
update_plan,
};