@sprucelabs/spruce-appointment-utils 7.7.24 → 7.7.27
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/build/esm/viewControllers/AbstractCapabilityCardViewController.js +0 -2
- package/build/esm/viewControllers/EditOverrideDetailsCard.vc.d.ts +2 -2
- package/build/esm/viewControllers/EditOverrideDetailsCard.vc.js +2 -2
- package/build/viewControllers/AbstractCapabilityCardViewController.js +0 -2
- package/build/viewControllers/EditOverrideDetailsCard.vc.d.ts +2 -2
- package/build/viewControllers/EditOverrideDetailsCard.vc.js +2 -2
- package/package.json +1 -1
|
@@ -43,7 +43,6 @@ export default class AbstractCapabilityCardViewController extends AbstractViewCo
|
|
|
43
43
|
name: 'isEnabled',
|
|
44
44
|
value: (_b = serviceCapability === null || serviceCapability === void 0 ? void 0 : serviceCapability.isEnabled) !== null && _b !== void 0 ? _b : false,
|
|
45
45
|
onChange: (value) => __awaiter(this, void 0, void 0, function* () {
|
|
46
|
-
console.log('toggling is enabled');
|
|
47
46
|
yield this.handleClickCheckbox(service, value);
|
|
48
47
|
}),
|
|
49
48
|
},
|
|
@@ -61,7 +60,6 @@ export default class AbstractCapabilityCardViewController extends AbstractViewCo
|
|
|
61
60
|
name: 'doesOffer',
|
|
62
61
|
value: (_e = serviceCapability === null || serviceCapability === void 0 ? void 0 : serviceCapability.doesOffer) !== null && _e !== void 0 ? _e : false,
|
|
63
62
|
onChange: (value) => __awaiter(this, void 0, void 0, function* () {
|
|
64
|
-
console.log('toggling does offer');
|
|
65
63
|
yield this.handleToggleDoesOffer(service, value);
|
|
66
64
|
}),
|
|
67
65
|
},
|
|
@@ -5,14 +5,14 @@ declare const schema: {
|
|
|
5
5
|
id: string;
|
|
6
6
|
fields: {
|
|
7
7
|
price: {
|
|
8
|
-
type: "
|
|
8
|
+
type: "number";
|
|
9
9
|
label: string;
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
};
|
|
13
13
|
declare type Schema = typeof schema;
|
|
14
14
|
export declare type FormVc = FormViewController<Schema>;
|
|
15
|
-
declare type SubmitHandler = (price: number | undefined, timeBlocks: SpruceSchemas.Appointments.v2021_06_23.CapabilityTimeBlock[] | undefined) => void;
|
|
15
|
+
declare type SubmitHandler = (price: number | undefined | null, timeBlocks: SpruceSchemas.Appointments.v2021_06_23.CapabilityTimeBlock[] | undefined) => void;
|
|
16
16
|
interface EditOverrideDetailsOptions {
|
|
17
17
|
service?: any;
|
|
18
18
|
serviceRoleCapability?: any;
|
|
@@ -13,7 +13,7 @@ const schema = buildSchema({
|
|
|
13
13
|
id: 'priceSchema',
|
|
14
14
|
fields: {
|
|
15
15
|
price: {
|
|
16
|
-
type: '
|
|
16
|
+
type: 'number',
|
|
17
17
|
label: 'Price',
|
|
18
18
|
},
|
|
19
19
|
},
|
|
@@ -40,7 +40,7 @@ export default class EditOverrideDetailsCardViewController extends AbstractViewC
|
|
|
40
40
|
schema,
|
|
41
41
|
shouldShowCancelButton: false,
|
|
42
42
|
onSubmit: ({ values }) => {
|
|
43
|
-
this.submitHandler(values.price
|
|
43
|
+
this.submitHandler(values.price, this.getDurationVc().getTimeBlocks());
|
|
44
44
|
},
|
|
45
45
|
onCancel: () => {
|
|
46
46
|
this.cancelHandler();
|
|
@@ -36,7 +36,6 @@ class AbstractCapabilityCardViewController extends heartwood_view_controllers_1.
|
|
|
36
36
|
name: 'isEnabled',
|
|
37
37
|
value: (_b = serviceCapability === null || serviceCapability === void 0 ? void 0 : serviceCapability.isEnabled) !== null && _b !== void 0 ? _b : false,
|
|
38
38
|
onChange: async (value) => {
|
|
39
|
-
console.log('toggling is enabled');
|
|
40
39
|
await this.handleClickCheckbox(service, value);
|
|
41
40
|
},
|
|
42
41
|
},
|
|
@@ -54,7 +53,6 @@ class AbstractCapabilityCardViewController extends heartwood_view_controllers_1.
|
|
|
54
53
|
name: 'doesOffer',
|
|
55
54
|
value: (_e = serviceCapability === null || serviceCapability === void 0 ? void 0 : serviceCapability.doesOffer) !== null && _e !== void 0 ? _e : false,
|
|
56
55
|
onChange: async (value) => {
|
|
57
|
-
console.log('toggling does offer');
|
|
58
56
|
await this.handleToggleDoesOffer(service, value);
|
|
59
57
|
},
|
|
60
58
|
},
|
|
@@ -5,14 +5,14 @@ declare const schema: {
|
|
|
5
5
|
id: string;
|
|
6
6
|
fields: {
|
|
7
7
|
price: {
|
|
8
|
-
type: "
|
|
8
|
+
type: "number";
|
|
9
9
|
label: string;
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
};
|
|
13
13
|
declare type Schema = typeof schema;
|
|
14
14
|
export declare type FormVc = FormViewController<Schema>;
|
|
15
|
-
declare type SubmitHandler = (price: number | undefined, timeBlocks: SpruceSchemas.Appointments.v2021_06_23.CapabilityTimeBlock[] | undefined) => void;
|
|
15
|
+
declare type SubmitHandler = (price: number | undefined | null, timeBlocks: SpruceSchemas.Appointments.v2021_06_23.CapabilityTimeBlock[] | undefined) => void;
|
|
16
16
|
interface EditOverrideDetailsOptions {
|
|
17
17
|
service?: any;
|
|
18
18
|
serviceRoleCapability?: any;
|
|
@@ -6,7 +6,7 @@ const schema = (0, schema_1.buildSchema)({
|
|
|
6
6
|
id: 'priceSchema',
|
|
7
7
|
fields: {
|
|
8
8
|
price: {
|
|
9
|
-
type: '
|
|
9
|
+
type: 'number',
|
|
10
10
|
label: 'Price',
|
|
11
11
|
},
|
|
12
12
|
},
|
|
@@ -33,7 +33,7 @@ class EditOverrideDetailsCardViewController extends heartwood_view_controllers_1
|
|
|
33
33
|
schema,
|
|
34
34
|
shouldShowCancelButton: false,
|
|
35
35
|
onSubmit: ({ values }) => {
|
|
36
|
-
this.submitHandler(values.price
|
|
36
|
+
this.submitHandler(values.price, this.getDurationVc().getTimeBlocks());
|
|
37
37
|
},
|
|
38
38
|
onCancel: () => {
|
|
39
39
|
this.cancelHandler();
|