@d19n/youfibre-odin-sdk 2.0.256-beta.3 → 2.0.256
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/README.md
CHANGED
|
@@ -264,7 +264,7 @@ This SDK includes **174** entities across **12** modules.
|
|
|
264
264
|
| Entity | Description | Types |
|
|
265
265
|
|--------|-------------|-------|
|
|
266
266
|
| **BngProvision** | BngProvision Entity Definition | DEFAULT |
|
|
267
|
-
| **CustomerDevice** | CustomerDevice Entity Definition | BATTERY |
|
|
267
|
+
| **CustomerDevice** | CustomerDevice Entity Definition | BATTERY, TV_DEVICE |
|
|
268
268
|
| **CustomerDeviceAta** | CustomerDeviceAta Entity Definition | DEFAULT |
|
|
269
269
|
| **CustomerDeviceOnt** | CustomerDeviceOnt Entity Definition | DEFAULT |
|
|
270
270
|
| **CustomerDeviceOntRemoval** | CustomerDeviceOntRemoval Entity Definition | DEFAULT |
|
|
@@ -20,7 +20,9 @@ export declare enum CustomerDeviceEntityTypes {
|
|
|
20
20
|
/** Battery Backup Unit */
|
|
21
21
|
BATTERY = "BATTERY",
|
|
22
22
|
/** This is the default record type */
|
|
23
|
-
DEFAULT = "DEFAULT"
|
|
23
|
+
DEFAULT = "DEFAULT",
|
|
24
|
+
/** TV Device */
|
|
25
|
+
TV_DEVICE = "TV_DEVICE"
|
|
24
26
|
}
|
|
25
27
|
/**
|
|
26
28
|
* Property keys for CustomerDevice
|
|
@@ -66,6 +68,23 @@ export interface BatteryCustomerDeviceProperties {
|
|
|
66
68
|
*/
|
|
67
69
|
SerialNumber: string;
|
|
68
70
|
}
|
|
71
|
+
/**
|
|
72
|
+
* Properties for TV_DEVICE CustomerDevice records
|
|
73
|
+
*
|
|
74
|
+
* @see ServiceModule:CustomerDevice
|
|
75
|
+
*/
|
|
76
|
+
export interface TvDeviceCustomerDeviceProperties {
|
|
77
|
+
/** Mac Address
|
|
78
|
+
*
|
|
79
|
+
* @type {TEXT}
|
|
80
|
+
*/
|
|
81
|
+
MacAddress: string;
|
|
82
|
+
/** Serial Number
|
|
83
|
+
*
|
|
84
|
+
* @type {TEXT}
|
|
85
|
+
*/
|
|
86
|
+
SerialNumber: string;
|
|
87
|
+
}
|
|
69
88
|
/**
|
|
70
89
|
* CustomerDevice entity from ServiceModule
|
|
71
90
|
*
|
|
@@ -109,6 +128,12 @@ export declare const ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_CREATED = "ServiceModul
|
|
|
109
128
|
export declare const ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_UPDATED = "ServiceModule.CustomerDevice.DEFAULT.SubDbRecordUpdated";
|
|
110
129
|
/** This is the default record type deleted */
|
|
111
130
|
export declare const ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_DELETED = "ServiceModule.CustomerDevice.DEFAULT.SubDbRecordDeleted";
|
|
131
|
+
/** TV Device created */
|
|
132
|
+
export declare const ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_CREATED = "ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordCreated";
|
|
133
|
+
/** TV Device updated */
|
|
134
|
+
export declare const ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_UPDATED = "ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordUpdated";
|
|
135
|
+
/** TV Device deleted */
|
|
136
|
+
export declare const ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_DELETED = "ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordDeleted";
|
|
112
137
|
/** Event: CustomerDevice__FieldServiceDispatchedProduct link created */
|
|
113
138
|
export declare const ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_CREATED = "ServiceModule.CustomerDevice.FieldServiceDispatchedProduct.SubDbRecordAssociationCreated";
|
|
114
139
|
/** Event: CustomerDevice__FieldServiceDispatchedProduct link deleted */
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* Generated from Odin schema definition
|
|
13
13
|
*/
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_ORDER_ITEM_DELETED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_ORDER_ITEM_CREATED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_DELETED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_CREATED = exports.CustomerDevice = exports.CustomerDevicePropertyKeys = exports.CustomerDeviceEntityTypes = void 0;
|
|
15
|
+
exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_ORDER_ITEM_DELETED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_ORDER_ITEM_CREATED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_DELETED = exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_BATTERY_CREATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_DELETED = exports.ROUTING_KEY_CUSTOMER_DEVICE_UPDATED = exports.ROUTING_KEY_CUSTOMER_DEVICE_CREATED = exports.CustomerDevice = exports.CustomerDevicePropertyKeys = exports.CustomerDeviceEntityTypes = void 0;
|
|
16
16
|
const core_1 = require("@d19n/odin-types/dist/core");
|
|
17
17
|
/**
|
|
18
18
|
* Available types for CustomerDevice records
|
|
@@ -23,6 +23,8 @@ var CustomerDeviceEntityTypes;
|
|
|
23
23
|
CustomerDeviceEntityTypes["BATTERY"] = "BATTERY";
|
|
24
24
|
/** This is the default record type */
|
|
25
25
|
CustomerDeviceEntityTypes["DEFAULT"] = "DEFAULT";
|
|
26
|
+
/** TV Device */
|
|
27
|
+
CustomerDeviceEntityTypes["TV_DEVICE"] = "TV_DEVICE";
|
|
26
28
|
})(CustomerDeviceEntityTypes = exports.CustomerDeviceEntityTypes || (exports.CustomerDeviceEntityTypes = {}));
|
|
27
29
|
/**
|
|
28
30
|
* Property keys for CustomerDevice
|
|
@@ -74,6 +76,12 @@ exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_CREATED = 'ServiceModule.CustomerDev
|
|
|
74
76
|
exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_UPDATED = 'ServiceModule.CustomerDevice.DEFAULT.SubDbRecordUpdated';
|
|
75
77
|
/** This is the default record type deleted */
|
|
76
78
|
exports.ROUTING_KEY_CUSTOMER_DEVICE_DEFAULT_DELETED = 'ServiceModule.CustomerDevice.DEFAULT.SubDbRecordDeleted';
|
|
79
|
+
/** TV Device created */
|
|
80
|
+
exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_CREATED = 'ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordCreated';
|
|
81
|
+
/** TV Device updated */
|
|
82
|
+
exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_UPDATED = 'ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordUpdated';
|
|
83
|
+
/** TV Device deleted */
|
|
84
|
+
exports.ROUTING_KEY_CUSTOMER_DEVICE_TV_DEVICE_DELETED = 'ServiceModule.CustomerDevice.TV_DEVICE.SubDbRecordDeleted';
|
|
77
85
|
/** Event: CustomerDevice__FieldServiceDispatchedProduct link created */
|
|
78
86
|
exports.ROUTING_KEY_LINK_CUSTOMER_DEVICE_FIELD_SERVICE_DISPATCHED_PRODUCT_CREATED = 'ServiceModule.CustomerDevice.FieldServiceDispatchedProduct.SubDbRecordAssociationCreated';
|
|
79
87
|
/** Event: CustomerDevice__FieldServiceDispatchedProduct link deleted */
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* await record.createCustomerDevice({ ... }).execute();
|
|
14
14
|
* ```
|
|
15
15
|
*
|
|
16
|
-
* Entity Types: BATTERY, DEFAULT
|
|
16
|
+
* Entity Types: BATTERY, DEFAULT, TV_DEVICE
|
|
17
17
|
*
|
|
18
18
|
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
19
19
|
*/
|
|
@@ -22,12 +22,12 @@ import { PipelineStageEntity } from '@d19n/odin-types/dist/core';
|
|
|
22
22
|
import { IDbRecordCreateUpdateRes } from '@d19n/odin-types/dist/core/interfaces/v1.db.interfaces';
|
|
23
23
|
import { IOdinProvider } from '@d19n/odin-sdk-generator/dist/odin-sdk-types';
|
|
24
24
|
import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-manager';
|
|
25
|
-
import { CustomerDeviceProperties, BatteryCustomerDeviceProperties } from '../entities-v2/CustomerDevice';
|
|
25
|
+
import { CustomerDeviceProperties, BatteryCustomerDeviceProperties, TvDeviceCustomerDeviceProperties } from '../entities-v2/CustomerDevice';
|
|
26
26
|
import { CreateCustomerDeviceBatteryProperties } from '../actions-v2/CreateCustomerDeviceBatteryDto';
|
|
27
27
|
import { FieldServiceDispatchedProductRecord } from './FieldServiceDispatchedProductRecord';
|
|
28
28
|
import { OrderItemRecord } from './OrderItemRecord';
|
|
29
29
|
/** Valid entity types for CustomerDevice */
|
|
30
|
-
export declare type CustomerDeviceType = 'BATTERY' | 'DEFAULT';
|
|
30
|
+
export declare type CustomerDeviceType = 'BATTERY' | 'DEFAULT' | 'TV_DEVICE';
|
|
31
31
|
/**
|
|
32
32
|
* Builder for action execution with dryRun support
|
|
33
33
|
*
|
|
@@ -150,6 +150,22 @@ export declare class CustomerDeviceRecord<TProps = CustomerDeviceProperties> {
|
|
|
150
150
|
* @remarks This is the default record type
|
|
151
151
|
*/
|
|
152
152
|
isDefault(): this is CustomerDeviceRecord<CustomerDeviceProperties>;
|
|
153
|
+
/**
|
|
154
|
+
* Type guard: check if this record is of type TV_DEVICE
|
|
155
|
+
*
|
|
156
|
+
* When this returns true, TypeScript automatically narrows the type,
|
|
157
|
+
* giving you access to TV_DEVICE-specific properties.
|
|
158
|
+
*
|
|
159
|
+
* @example
|
|
160
|
+
* ```typescript
|
|
161
|
+
* if (record.isTvDevice()) {
|
|
162
|
+
* // TypeScript knows record.properties is TvDeviceCustomerDeviceProperties
|
|
163
|
+
* console.log(record.properties.SomeTypeSpecificField);
|
|
164
|
+
* }
|
|
165
|
+
* ```
|
|
166
|
+
* @remarks TV Device
|
|
167
|
+
*/
|
|
168
|
+
isTvDevice(): this is CustomerDeviceRecord<TvDeviceCustomerDeviceProperties>;
|
|
153
169
|
/** Valid labels for FieldServiceDispatchedProduct associations */
|
|
154
170
|
static readonly fieldServiceDispatchedProductsLabels: readonly ["CustomerDevice__FieldServiceDispatchedProduct"];
|
|
155
171
|
/**
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* await record.createCustomerDevice({ ... }).execute();
|
|
15
15
|
* ```
|
|
16
16
|
*
|
|
17
|
-
* Entity Types: BATTERY, DEFAULT
|
|
17
|
+
* Entity Types: BATTERY, DEFAULT, TV_DEVICE
|
|
18
18
|
*
|
|
19
19
|
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
20
20
|
*/
|
|
@@ -179,6 +179,22 @@ class CustomerDeviceRecord {
|
|
|
179
179
|
* @remarks This is the default record type
|
|
180
180
|
*/
|
|
181
181
|
isDefault() { var _a; return ((_a = this._record) === null || _a === void 0 ? void 0 : _a.type) === 'DEFAULT'; }
|
|
182
|
+
/**
|
|
183
|
+
* Type guard: check if this record is of type TV_DEVICE
|
|
184
|
+
*
|
|
185
|
+
* When this returns true, TypeScript automatically narrows the type,
|
|
186
|
+
* giving you access to TV_DEVICE-specific properties.
|
|
187
|
+
*
|
|
188
|
+
* @example
|
|
189
|
+
* ```typescript
|
|
190
|
+
* if (record.isTvDevice()) {
|
|
191
|
+
* // TypeScript knows record.properties is TvDeviceCustomerDeviceProperties
|
|
192
|
+
* console.log(record.properties.SomeTypeSpecificField);
|
|
193
|
+
* }
|
|
194
|
+
* ```
|
|
195
|
+
* @remarks TV Device
|
|
196
|
+
*/
|
|
197
|
+
isTvDevice() { var _a; return ((_a = this._record) === null || _a === void 0 ? void 0 : _a.type) === 'TV_DEVICE'; }
|
|
182
198
|
/**
|
|
183
199
|
* Access linked FieldServiceDispatchedProduct records
|
|
184
200
|
* @remarks Available labels: CustomerDevice__FieldServiceDispatchedProduct
|