136 lines
3.0 KiB
TypeScript
136 lines
3.0 KiB
TypeScript
export type SysAdminPaginateUsersParams = {
|
|
page: number;
|
|
limit: number;
|
|
name?: string;
|
|
lastName?: string;
|
|
email?: string;
|
|
isVerified?: boolean;
|
|
createdFrom?: string;
|
|
createdTo?: string;
|
|
sortBy?: "name" | "createdAt";
|
|
sortOrder?: "asc" | "desc";
|
|
};
|
|
|
|
export type PaginateUsersResults = {
|
|
data: any[];
|
|
page: number;
|
|
pages: number;
|
|
};
|
|
|
|
export type SysAdminUpdateProfileParams = {
|
|
userId: string;
|
|
firstName?: string;
|
|
lastName?: string;
|
|
street?: string;
|
|
streetNumber?: string;
|
|
builingFloor?: string;
|
|
buildingApartament?: string;
|
|
block?: string;
|
|
city?: string;
|
|
state?: string;
|
|
country?: string;
|
|
zipCode?: string;
|
|
phoneCountryCode?: string;
|
|
phoneAreaCode?: string;
|
|
phoneNumber?: string;
|
|
};
|
|
|
|
export type SysAdminSetVerifiedParams = {
|
|
userId: string;
|
|
isVerified: boolean;
|
|
};
|
|
|
|
export type SysAdminDeleteUserParams = {
|
|
userId: string;
|
|
};
|
|
|
|
export type SysAdminOrganizationsStatusParams = {
|
|
userId: string;
|
|
};
|
|
|
|
export type SysAdminUserOrganizationsResult = {
|
|
clientIn: { companyId: string; companyName: string }[];
|
|
collaboratorIn: { companyId: string; companyName: string }[];
|
|
};
|
|
|
|
export type SysAdminRecalculatePlanUsageCycleParams = {
|
|
userId: string;
|
|
};
|
|
|
|
export type SysAdminRecalculatePlanUsageCycleResult = {
|
|
userId: string;
|
|
subscriptionId: string;
|
|
planId: string;
|
|
cycleStart: string;
|
|
cycleEnd: string;
|
|
organizationsCount: number;
|
|
employeesCount: number;
|
|
servicesCount: number;
|
|
clientsCount: number;
|
|
repeatsCount: number;
|
|
appointmentsCount: number;
|
|
};
|
|
|
|
export type SysAdminUserSubscriptionDetailsParams = {
|
|
userId: string;
|
|
};
|
|
|
|
export type SysAdminExtendUserSubscriptionParams = {
|
|
userId: string;
|
|
mode: "add_months" | "set_end_date";
|
|
months?: 1 | 2;
|
|
endDate?: string;
|
|
reason?: string;
|
|
};
|
|
|
|
export type SysAdminExtendUserSubscriptionResult = {
|
|
userId: string;
|
|
subscriptionId: string;
|
|
previousEndDate: string;
|
|
newEndDate: string;
|
|
paymentId: string;
|
|
transactionId?: string;
|
|
};
|
|
|
|
export type SysAdminFinalizeUserSubscriptionParams = {
|
|
userId: string;
|
|
reason?: string;
|
|
};
|
|
|
|
export type SysAdminFinalizeUserSubscriptionResult = {
|
|
userId: string;
|
|
subscriptionId: string;
|
|
previousEndDate: string;
|
|
newEndDate: string;
|
|
};
|
|
|
|
export type SysAdminUserSubscriptionDetailsResult = {
|
|
userId: string;
|
|
currentSubscription: {
|
|
id: string;
|
|
plan: {
|
|
id: string;
|
|
name: string;
|
|
code: string;
|
|
price: number;
|
|
} | null;
|
|
startDate: string;
|
|
endDate: string;
|
|
isActive: boolean;
|
|
mpStatus?: string;
|
|
billingMonths?: number;
|
|
pendingPaymentType?: "extension" | "upgrade";
|
|
pendingPaymentPreferenceId?: string;
|
|
lastPaymentStatus?: string;
|
|
} | null;
|
|
payments: {
|
|
id: string;
|
|
subscriptionId: string;
|
|
amount: number;
|
|
paymentDate: string;
|
|
paymentMethod?: string;
|
|
status: string;
|
|
transactionId?: string;
|
|
}[];
|
|
};
|