@sprucelabs/spruce-appointment-utils 14.0.151 → 14.1.0

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.
@@ -15,7 +15,7 @@ export default abstract class AbstractCapabilityCardViewController extends Abstr
15
15
  name: string;
16
16
  }): ActiveRecordCardViewController;
17
17
  protected renderRow(service: Service): any;
18
- private renderPrice;
18
+ private renderSubText;
19
19
  private getCapabilityForService;
20
20
  private handleClickCheckbox;
21
21
  private handleClickRow;
@@ -60,7 +60,7 @@ export default class AbstractCapabilityCardViewController extends AbstractViewCo
60
60
  content: service.name,
61
61
  },
62
62
  subText: {
63
- content: this.renderPrice(service, serviceCapability),
63
+ content: this.renderSubText(service, serviceCapability),
64
64
  },
65
65
  },
66
66
  {
@@ -75,10 +75,10 @@ export default class AbstractCapabilityCardViewController extends AbstractViewCo
75
75
  ].filter((c) => !!c),
76
76
  };
77
77
  }
78
- renderPrice(service, capability) {
78
+ renderSubText(service, capability) {
79
79
  var _a, _b;
80
80
  let price = '';
81
- if (service.price || !(capability === null || capability === void 0 ? void 0 : capability.price)) {
81
+ if (service.price || (capability === null || capability === void 0 ? void 0 : capability.price)) {
82
82
  price = `$${(_a = capability === null || capability === void 0 ? void 0 : capability.price) !== null && _a !== void 0 ? _a : service.price} - `;
83
83
  }
84
84
  return `${price}${this.calculateDuration((_b = capability === null || capability === void 0 ? void 0 : capability.timeBlocks) !== null && _b !== void 0 ? _b : service.timeBlocks)}`;
@@ -15,7 +15,7 @@ export default abstract class AbstractCapabilityCardViewController extends Abstr
15
15
  name: string;
16
16
  }): ActiveRecordCardViewController;
17
17
  protected renderRow(service: Service): any;
18
- private renderPrice;
18
+ private renderSubText;
19
19
  private getCapabilityForService;
20
20
  private handleClickCheckbox;
21
21
  private handleClickRow;
@@ -52,7 +52,7 @@ class AbstractCapabilityCardViewController extends heartwood_view_controllers_1.
52
52
  content: service.name,
53
53
  },
54
54
  subText: {
55
- content: this.renderPrice(service, serviceCapability),
55
+ content: this.renderSubText(service, serviceCapability),
56
56
  },
57
57
  },
58
58
  {
@@ -67,9 +67,9 @@ class AbstractCapabilityCardViewController extends heartwood_view_controllers_1.
67
67
  ].filter((c) => !!c),
68
68
  };
69
69
  }
70
- renderPrice(service, capability) {
70
+ renderSubText(service, capability) {
71
71
  let price = '';
72
- if (service.price || !capability?.price) {
72
+ if (service.price || capability?.price) {
73
73
  price = `$${capability?.price ?? service.price} - `;
74
74
  }
75
75
  return `${price}${this.calculateDuration(capability?.timeBlocks ?? service.timeBlocks)}`;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sprucelabs/spruce-appointment-utils",
3
3
  "description": "Utils for working with appointments and Sprucebot.",
4
- "version": "14.0.151",
4
+ "version": "14.1.0",
5
5
  "skill": {
6
6
  "namespace": "appointments"
7
7
  },