hububb-saas-shared 1.2.22 → 1.2.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/service/index.d.ts +6 -0
- package/dist/schemas/service/index.js +2 -0
- package/dist/schemas/task-pricing/index.d.ts +59 -0
- package/dist/schemas/task-pricing/index.js +25 -0
- package/dist/types/enums/index.d.ts +5 -0
- package/dist/types/enums/index.js +7 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.js +1 -0
- package/dist/types/service/index.d.ts +2 -0
- package/dist/types/task/index.d.ts +2 -0
- package/dist/types/task-pricing/index.d.ts +10 -0
- package/dist/types/task-pricing/index.js +2 -0
- package/dist/types/user/index.d.ts +2 -0
- package/package.json +1 -1
package/dist/schemas/index.d.ts
CHANGED
package/dist/schemas/index.js
CHANGED
|
@@ -107,3 +107,4 @@ __exportStar(require("./task-inventory-item"), exports);
|
|
|
107
107
|
__exportStar(require("./task-quote"), exports);
|
|
108
108
|
__exportStar(require("./task-reporting-video"), exports);
|
|
109
109
|
__exportStar(require("./task-reporting-photo"), exports);
|
|
110
|
+
__exportStar(require("./task-pricing"), exports);
|
|
@@ -15,6 +15,8 @@ export declare const serviceSchema: import("zod").ZodObject<{
|
|
|
15
15
|
stripePriceId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
16
16
|
startingFromPrice: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
17
17
|
priceType: import("zod").ZodNativeEnum<typeof PriceType>;
|
|
18
|
+
commissionPercentage: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
19
|
+
markupPercentage: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
18
20
|
departmentId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
19
21
|
subdepartmentId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
20
22
|
display: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -39,6 +41,8 @@ export declare const serviceSchema: import("zod").ZodObject<{
|
|
|
39
41
|
originalImageUrl?: string | null | undefined;
|
|
40
42
|
stripePriceId?: string | undefined;
|
|
41
43
|
startingFromPrice?: number | undefined;
|
|
44
|
+
commissionPercentage?: number | undefined;
|
|
45
|
+
markupPercentage?: number | undefined;
|
|
42
46
|
departmentId?: number | undefined;
|
|
43
47
|
subdepartmentId?: number | undefined;
|
|
44
48
|
requirements?: string | undefined;
|
|
@@ -62,6 +66,8 @@ export declare const serviceSchema: import("zod").ZodObject<{
|
|
|
62
66
|
originalImageUrl?: string | null | undefined;
|
|
63
67
|
stripePriceId?: string | undefined;
|
|
64
68
|
startingFromPrice?: number | undefined;
|
|
69
|
+
commissionPercentage?: number | undefined;
|
|
70
|
+
markupPercentage?: number | undefined;
|
|
65
71
|
departmentId?: number | undefined;
|
|
66
72
|
subdepartmentId?: number | undefined;
|
|
67
73
|
requirements?: string | undefined;
|
|
@@ -19,6 +19,8 @@ exports.serviceSchema = (0, zod_1.object)({
|
|
|
19
19
|
stripePriceId: (0, zod_1.string)().optional(),
|
|
20
20
|
startingFromPrice: (0, zod_1.number)().optional(),
|
|
21
21
|
priceType: (0, zod_1.nativeEnum)(enums_1.PriceType),
|
|
22
|
+
commissionPercentage: (0, zod_1.number)().optional(),
|
|
23
|
+
markupPercentage: (0, zod_1.number)().optional(),
|
|
22
24
|
departmentId: (0, zod_1.number)().int().optional(),
|
|
23
25
|
subdepartmentId: (0, zod_1.number)().int().optional(),
|
|
24
26
|
display: (0, zod_1.boolean)().optional(),
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { TaskPricingStatus } from "../../types/enums";
|
|
2
|
+
export declare const taskPricingSchema: import("zod").ZodObject<{
|
|
3
|
+
id: import("zod").ZodNumber;
|
|
4
|
+
taskId: import("zod").ZodNumber;
|
|
5
|
+
serviceId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
6
|
+
basePrice: import("zod").ZodNumber;
|
|
7
|
+
commissionPercentage: import("zod").ZodNumber;
|
|
8
|
+
markupPercentage: import("zod").ZodNumber;
|
|
9
|
+
markupAmount: import("zod").ZodNumber;
|
|
10
|
+
hostTotal: import("zod").ZodNumber;
|
|
11
|
+
commissionAmount: import("zod").ZodNumber;
|
|
12
|
+
providerEarnings: import("zod").ZodNumber;
|
|
13
|
+
hububbEarnings: import("zod").ZodNumber;
|
|
14
|
+
currency: import("zod").ZodString;
|
|
15
|
+
notes: import("zod").ZodOptional<import("zod").ZodString>;
|
|
16
|
+
status: import("zod").ZodNativeEnum<typeof TaskPricingStatus>;
|
|
17
|
+
paidAt: import("zod").ZodOptional<import("zod").ZodDate>;
|
|
18
|
+
addedBy: import("zod").ZodString;
|
|
19
|
+
createdAt: import("zod").ZodDate;
|
|
20
|
+
updatedAt: import("zod").ZodDate;
|
|
21
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
22
|
+
currency: string;
|
|
23
|
+
id: number;
|
|
24
|
+
status: TaskPricingStatus;
|
|
25
|
+
createdAt: Date;
|
|
26
|
+
updatedAt: Date;
|
|
27
|
+
basePrice: number;
|
|
28
|
+
commissionPercentage: number;
|
|
29
|
+
markupPercentage: number;
|
|
30
|
+
taskId: number;
|
|
31
|
+
markupAmount: number;
|
|
32
|
+
hostTotal: number;
|
|
33
|
+
commissionAmount: number;
|
|
34
|
+
providerEarnings: number;
|
|
35
|
+
hububbEarnings: number;
|
|
36
|
+
addedBy: string;
|
|
37
|
+
serviceId?: number | undefined;
|
|
38
|
+
notes?: string | undefined;
|
|
39
|
+
paidAt?: Date | undefined;
|
|
40
|
+
}, {
|
|
41
|
+
currency: string;
|
|
42
|
+
id: number;
|
|
43
|
+
status: TaskPricingStatus;
|
|
44
|
+
createdAt: Date;
|
|
45
|
+
updatedAt: Date;
|
|
46
|
+
basePrice: number;
|
|
47
|
+
commissionPercentage: number;
|
|
48
|
+
markupPercentage: number;
|
|
49
|
+
taskId: number;
|
|
50
|
+
markupAmount: number;
|
|
51
|
+
hostTotal: number;
|
|
52
|
+
commissionAmount: number;
|
|
53
|
+
providerEarnings: number;
|
|
54
|
+
hububbEarnings: number;
|
|
55
|
+
addedBy: string;
|
|
56
|
+
serviceId?: number | undefined;
|
|
57
|
+
notes?: string | undefined;
|
|
58
|
+
paidAt?: Date | undefined;
|
|
59
|
+
}>;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.taskPricingSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const enums_1 = require("../../types/enums");
|
|
6
|
+
exports.taskPricingSchema = (0, zod_1.object)({
|
|
7
|
+
id: (0, zod_1.number)().int(),
|
|
8
|
+
taskId: (0, zod_1.number)().int(),
|
|
9
|
+
serviceId: (0, zod_1.number)().int().optional(),
|
|
10
|
+
basePrice: (0, zod_1.number)(),
|
|
11
|
+
commissionPercentage: (0, zod_1.number)(),
|
|
12
|
+
markupPercentage: (0, zod_1.number)(),
|
|
13
|
+
markupAmount: (0, zod_1.number)(),
|
|
14
|
+
hostTotal: (0, zod_1.number)(),
|
|
15
|
+
commissionAmount: (0, zod_1.number)(),
|
|
16
|
+
providerEarnings: (0, zod_1.number)(),
|
|
17
|
+
hububbEarnings: (0, zod_1.number)(),
|
|
18
|
+
currency: (0, zod_1.string)(),
|
|
19
|
+
notes: (0, zod_1.string)().optional(),
|
|
20
|
+
status: (0, zod_1.nativeEnum)(enums_1.TaskPricingStatus),
|
|
21
|
+
paidAt: (0, zod_1.date)().optional(),
|
|
22
|
+
addedBy: (0, zod_1.string)(),
|
|
23
|
+
createdAt: (0, zod_1.date)(),
|
|
24
|
+
updatedAt: (0, zod_1.date)(),
|
|
25
|
+
});
|
|
@@ -151,6 +151,11 @@ export declare enum TaskReportingPhotoType {
|
|
|
151
151
|
BEFORE = "BEFORE",
|
|
152
152
|
AFTER = "AFTER"
|
|
153
153
|
}
|
|
154
|
+
export declare enum TaskPricingStatus {
|
|
155
|
+
PENDING = "PENDING",
|
|
156
|
+
PAID = "PAID",
|
|
157
|
+
CANCELLED = "CANCELLED"
|
|
158
|
+
}
|
|
154
159
|
export declare enum HumanReviewPriority {
|
|
155
160
|
LOW = "LOW",
|
|
156
161
|
NORMAL = "NORMAL",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.HumanReviewStatus = exports.HumanReviewPriority = exports.TaskReportingPhotoType = exports.TaskReportingVideoType = exports.TaskQuoteStatus = exports.TaskInventoryItemStatus = exports.TaskInventoryStatus = exports.InventoryItemCategory = exports.TaskBlockReason = exports.InvitedServiceProviderPreferencesPriority = exports.InvitedServiceProviderStatus = exports.PropertyManagerSessionType = exports.PropertyManagerSuggestionStatus = exports.PropertyManagerSessionStatus = exports.AgentActionType = exports.AgentSessionStatus = exports.GuestCoordinatorResponseStyle = exports.AiAgentCategory = exports.PropertyType = exports.OnboardingType = exports.SubscriptionStatus = exports.PurchaseStatus = exports.PriceType = exports.InvoiceStatus = exports.InvoiceType = exports.TaskPriority = exports.TaskStatus = exports.ServiceCategory = exports.ServiceGroup = exports.ServiceType = void 0;
|
|
3
|
+
exports.HumanReviewStatus = exports.HumanReviewPriority = exports.TaskPricingStatus = exports.TaskReportingPhotoType = exports.TaskReportingVideoType = exports.TaskQuoteStatus = exports.TaskInventoryItemStatus = exports.TaskInventoryStatus = exports.InventoryItemCategory = exports.TaskBlockReason = exports.InvitedServiceProviderPreferencesPriority = exports.InvitedServiceProviderStatus = exports.PropertyManagerSessionType = exports.PropertyManagerSuggestionStatus = exports.PropertyManagerSessionStatus = exports.AgentActionType = exports.AgentSessionStatus = exports.GuestCoordinatorResponseStyle = exports.AiAgentCategory = exports.PropertyType = exports.OnboardingType = exports.SubscriptionStatus = exports.PurchaseStatus = exports.PriceType = exports.InvoiceStatus = exports.InvoiceType = exports.TaskPriority = exports.TaskStatus = exports.ServiceCategory = exports.ServiceGroup = exports.ServiceType = void 0;
|
|
4
4
|
var ServiceType;
|
|
5
5
|
(function (ServiceType) {
|
|
6
6
|
ServiceType["INTEGRATION"] = "INTEGRATION";
|
|
@@ -186,6 +186,12 @@ var TaskReportingPhotoType;
|
|
|
186
186
|
TaskReportingPhotoType["BEFORE"] = "BEFORE";
|
|
187
187
|
TaskReportingPhotoType["AFTER"] = "AFTER";
|
|
188
188
|
})(TaskReportingPhotoType || (exports.TaskReportingPhotoType = TaskReportingPhotoType = {}));
|
|
189
|
+
var TaskPricingStatus;
|
|
190
|
+
(function (TaskPricingStatus) {
|
|
191
|
+
TaskPricingStatus["PENDING"] = "PENDING";
|
|
192
|
+
TaskPricingStatus["PAID"] = "PAID";
|
|
193
|
+
TaskPricingStatus["CANCELLED"] = "CANCELLED";
|
|
194
|
+
})(TaskPricingStatus || (exports.TaskPricingStatus = TaskPricingStatus = {}));
|
|
189
195
|
var HumanReviewPriority;
|
|
190
196
|
(function (HumanReviewPriority) {
|
|
191
197
|
HumanReviewPriority["LOW"] = "LOW";
|
package/dist/types/index.d.ts
CHANGED
package/dist/types/index.js
CHANGED
|
@@ -108,3 +108,4 @@ __exportStar(require("./task-inventory-item"), exports);
|
|
|
108
108
|
__exportStar(require("./task-quote"), exports);
|
|
109
109
|
__exportStar(require("./task-reporting-video"), exports);
|
|
110
110
|
__exportStar(require("./task-reporting-photo"), exports);
|
|
111
|
+
__exportStar(require("./task-pricing"), exports);
|
|
@@ -6,6 +6,7 @@ import { Purchase } from "../purchase";
|
|
|
6
6
|
import { ServiceProviderService } from "../service-provider-service";
|
|
7
7
|
import { ManagementTier } from "../management-tier";
|
|
8
8
|
import { PropertyCart } from "../property-cart";
|
|
9
|
+
import { TaskPricing } from "../task-pricing";
|
|
9
10
|
export interface Service extends infer<typeof serviceSchema> {
|
|
10
11
|
tierServices?: TierService[];
|
|
11
12
|
subscriptionServices?: SubscriptionService[];
|
|
@@ -13,4 +14,5 @@ export interface Service extends infer<typeof serviceSchema> {
|
|
|
13
14
|
serviceProviders?: ServiceProviderService[];
|
|
14
15
|
managementTier?: ManagementTier;
|
|
15
16
|
cartItems?: PropertyCart[];
|
|
17
|
+
taskPricings?: TaskPricing[];
|
|
16
18
|
}
|
|
@@ -27,6 +27,7 @@ import { TaskInventory } from "../task-inventory";
|
|
|
27
27
|
import { TaskQuote } from "../task-quote";
|
|
28
28
|
import { TaskReportingVideo } from "../task-reporting-video";
|
|
29
29
|
import { TaskReportingPhoto } from "../task-reporting-photo";
|
|
30
|
+
import { TaskPricing } from "../task-pricing";
|
|
30
31
|
export interface Task extends infer<typeof taskSchema> {
|
|
31
32
|
property?: Property;
|
|
32
33
|
department?: TaskDepartment;
|
|
@@ -58,4 +59,5 @@ export interface Task extends infer<typeof taskSchema> {
|
|
|
58
59
|
quote?: TaskQuote;
|
|
59
60
|
reportingVideos?: TaskReportingVideo[];
|
|
60
61
|
reportingPhotos?: TaskReportingPhoto[];
|
|
62
|
+
pricing?: TaskPricing;
|
|
61
63
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { infer } from "zod";
|
|
2
|
+
import { taskPricingSchema } from "../../schemas/task-pricing";
|
|
3
|
+
import { Task } from "../task";
|
|
4
|
+
import { Service } from "../service";
|
|
5
|
+
import { User } from "../user";
|
|
6
|
+
export interface TaskPricing extends infer<typeof taskPricingSchema> {
|
|
7
|
+
task?: Task;
|
|
8
|
+
service?: Service;
|
|
9
|
+
addedByUser?: User;
|
|
10
|
+
}
|
|
@@ -19,6 +19,7 @@ import { PendingPaymentAction } from "../pending-payment-action";
|
|
|
19
19
|
import { UserAiAgentSubscription } from "../ai-agent/user-ai-agent-subscription";
|
|
20
20
|
import { InvitedServiceProvider } from "../invited-service-provider";
|
|
21
21
|
import { InvitedServiceProviderPreferences } from "../invited-service-provider-preferences";
|
|
22
|
+
import { TaskPricing } from "../task-pricing";
|
|
22
23
|
export interface User extends infer<typeof userSchema> {
|
|
23
24
|
tier?: Tier;
|
|
24
25
|
properties?: Property[];
|
|
@@ -43,4 +44,5 @@ export interface User extends infer<typeof userSchema> {
|
|
|
43
44
|
aiAgentSubscriptions?: UserAiAgentSubscription[];
|
|
44
45
|
invitedServiceProviders?: InvitedServiceProvider[];
|
|
45
46
|
invitedServiceProviderPreferences?: InvitedServiceProviderPreferences[];
|
|
47
|
+
addedTaskPricings?: TaskPricing[];
|
|
46
48
|
}
|