@felloh-org/lambda-wrapper 1.2.8 → 1.2.9

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.
@@ -153,6 +153,13 @@ let Booking = (_dec = (0, _typeorm.Entity)({
153
153
  return response;
154
154
  }
155
155
 
156
+ getPublicCompactData() {
157
+ return {
158
+ id: this.id,
159
+ booking_reference: this.booking_reference
160
+ };
161
+ }
162
+
156
163
  }, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
157
164
  configurable: true,
158
165
  enumerable: true,
@@ -195,6 +195,12 @@ let PaymentLink = (_dec = (0, _typeorm.Entity)({
195
195
  };
196
196
  }
197
197
 
198
+ getPublicUltraCompactData() {
199
+ return {
200
+ id: this.id
201
+ };
202
+ }
203
+
198
204
  }, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
199
205
  configurable: true,
200
206
  enumerable: true,
@@ -192,6 +192,14 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
192
192
  provider_reference: this.provider_reference
193
193
  };
194
194
 
195
+ if (this.booking !== null && typeof this.booking.id !== 'undefined') {
196
+ response.booking = this.booking.getPublicCompactData();
197
+ }
198
+
199
+ if (this.payment_link !== null && typeof this.payment_link !== 'undefined') {
200
+ response.payment_link = this.payment_link.getPublicUltraCompactData();
201
+ }
202
+
195
203
  if (this.organisation !== null && typeof this.organisation.id !== 'undefined') {
196
204
  response.organisation = this.organisation.getPublicCompactData();
197
205
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@felloh-org/lambda-wrapper",
3
- "version": "1.2.8",
3
+ "version": "1.2.9",
4
4
  "description": "Lambda wrapper for all Felloh Serverless Projects",
5
5
  "main": "dist/index.js",
6
6
  "engines": {