@d19n/youfibre-odin-sdk 2.0.122 → 2.0.124
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 +6 -2
- package/dist/EntityRegistry.d.ts +2 -0
- package/dist/EntityRegistry.js +2 -0
- package/dist/OdinApiClient.d.ts +4 -0
- package/dist/OdinApiClient.js +8 -0
- package/dist/OdinDbClient.d.ts +4 -0
- package/dist/OdinDbClient.js +8 -0
- package/dist/accessors-v2/YfFieldServiceVisitAccessor.d.ts +111 -0
- package/dist/accessors-v2/YfFieldServiceVisitAccessor.js +190 -0
- package/dist/accessors-v2/index.d.ts +1 -0
- package/dist/accessors-v2/index.js +3 -1
- package/dist/actions-v2/CompleteServiceWorkOrderFlowDto.d.ts +1026 -3
- package/dist/actions-v2/CompleteServiceWorkOrderFlowDto.js +115 -2
- package/dist/actions-v2/CreateContactDto.d.ts +7 -7
- package/dist/actions-v2/CreateInboundCallDto.d.ts +33 -1
- package/dist/actions-v2/CreateLeadFromAddressDto.d.ts +7 -7
- package/dist/actions-v2/MoveCaseToClosedWithAdditionalNoteDto.d.ts +172 -0
- package/dist/actions-v2/MoveCaseToClosedWithAdditionalNoteDto.js +122 -0
- package/dist/actions-v2/UpdateAdditionalCareDto.d.ts +28 -29
- package/dist/actions-v2/UpdateAdditionalNoteDto.d.ts +73 -0
- package/dist/actions-v2/UpdateAdditionalNoteDto.js +56 -0
- package/dist/actions-v2/UpdateContactDto.d.ts +28 -29
- package/dist/api-sdk-v2/AddressApi.d.ts +2 -0
- package/dist/api-sdk-v2/AddressApi.js +6 -0
- package/dist/api-sdk-v2/ContactApi.d.ts +2 -2
- package/dist/api-sdk-v2/ContactApi.js +6 -6
- package/dist/api-sdk-v2/YfFieldServiceVisitApi.d.ts +2 -0
- package/dist/api-sdk-v2/YfFieldServiceVisitApi.js +6 -0
- package/dist/db-accessors-v2/YfFieldServiceVisitDbAccessor.d.ts +149 -0
- package/dist/db-accessors-v2/YfFieldServiceVisitDbAccessor.js +227 -0
- package/dist/db-accessors-v2/index.d.ts +1 -0
- package/dist/db-accessors-v2/index.js +3 -1
- package/dist/db-sdk-v2/AddressDb.d.ts +2 -0
- package/dist/db-sdk-v2/AddressDb.js +6 -0
- package/dist/db-sdk-v2/ContactDb.d.ts +2 -2
- package/dist/db-sdk-v2/ContactDb.js +6 -6
- package/dist/db-sdk-v2/YfFieldServiceVisitDb.d.ts +2 -0
- package/dist/db-sdk-v2/YfFieldServiceVisitDb.js +6 -0
- package/dist/entities-v2/Address.d.ts +3 -0
- package/dist/entities-v2/Contact.d.ts +88 -89
- package/dist/entities-v2/Contact.js +58 -59
- package/dist/entities-v2/YfFieldServiceVisit.d.ts +20 -13
- package/dist/entities-v2/YfFieldServiceVisit.js +7 -3
- package/dist/records-v2/AddressRecord.d.ts +20 -0
- package/dist/records-v2/AddressRecord.js +33 -0
- package/dist/records-v2/CaseRecord.d.ts +113 -0
- package/dist/records-v2/CaseRecord.js +164 -1
- package/dist/records-v2/ContactRecord.d.ts +20 -20
- package/dist/records-v2/ContactRecord.js +33 -33
- package/dist/records-v2/FileRecord.d.ts +20 -0
- package/dist/records-v2/FileRecord.js +33 -0
- package/dist/records-v2/NoteRecord.d.ts +20 -0
- package/dist/records-v2/NoteRecord.js +33 -0
- package/dist/records-v2/WorkOrderRecord.d.ts +98 -8
- package/dist/records-v2/WorkOrderRecord.js +169 -10
- package/dist/records-v2/YfFieldServiceVisitRecord.d.ts +265 -0
- package/dist/records-v2/YfFieldServiceVisitRecord.js +379 -0
- package/dist/records-v2/index.d.ts +1 -0
- package/dist/records-v2/index.js +8 -5
- package/package.json +1 -1
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* UpdateAdditionalNote Action DTO
|
|
3
|
+
*
|
|
4
|
+
* Updates the additional note field
|
|
5
|
+
*
|
|
6
|
+
* @module SupportModule
|
|
7
|
+
* @entity Case
|
|
8
|
+
* @actionKey UpdateAdditionalNote
|
|
9
|
+
* @event k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote
|
|
10
|
+
*
|
|
11
|
+
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
12
|
+
*/
|
|
13
|
+
import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
|
|
14
|
+
/**
|
|
15
|
+
* RabbitMQ message payload for UpdateAdditionalNote updated events
|
|
16
|
+
*
|
|
17
|
+
* @event k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote
|
|
18
|
+
*/
|
|
19
|
+
export interface UpdateAdditionalNoteMessage extends OdinRecordUpdatedEvent<UpdateAdditionalNoteDto, UpdateAdditionalNoteProperties> {
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Properties for UpdateAdditionalNote action
|
|
23
|
+
*
|
|
24
|
+
* @property Required fields: 1
|
|
25
|
+
* @property Optional fields: 0
|
|
26
|
+
*/
|
|
27
|
+
export interface UpdateAdditionalNoteProperties {
|
|
28
|
+
/**
|
|
29
|
+
* Additional Notes
|
|
30
|
+
*
|
|
31
|
+
* Additional Notes (Customer Service - Case)
|
|
32
|
+
* @type {TEXT_LONG}
|
|
33
|
+
* @required
|
|
34
|
+
*/
|
|
35
|
+
AdditionalNotes: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* UpdateAdditionalNote
|
|
39
|
+
*
|
|
40
|
+
* Updates the additional note field
|
|
41
|
+
*
|
|
42
|
+
* @actionType UPDATE - Updates an existing Case record
|
|
43
|
+
* @module SupportModule
|
|
44
|
+
* @entity Case
|
|
45
|
+
* @event k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote
|
|
46
|
+
* @permission schema.action.updateadditionalnote.trigger
|
|
47
|
+
* @benchmark This action is tracked for performance benchmarks
|
|
48
|
+
*/
|
|
49
|
+
export declare class UpdateAdditionalNoteDto extends OdinRecordUpdateDto<UpdateAdditionalNoteProperties> {
|
|
50
|
+
/** Used by SDK generators to identify action type */
|
|
51
|
+
static readonly ACTION_TYPE = "UPDATE";
|
|
52
|
+
static readonly ACTION_KEY = "UpdateAdditionalNote";
|
|
53
|
+
static readonly MODULE_NAME = "SupportModule";
|
|
54
|
+
static readonly ENTITIES: string[];
|
|
55
|
+
static readonly EVENT_NAME = "k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote";
|
|
56
|
+
static readonly PERMISSION = "schema.action.updateadditionalnote.trigger";
|
|
57
|
+
/** Step metadata - entity this action targets */
|
|
58
|
+
static readonly STEP_ENTITY = "SupportModule:Case";
|
|
59
|
+
static readonly STEP_SCHEMA_ID = "bb540d25-53bf-491b-9d03-f3d42f755b3a";
|
|
60
|
+
static readonly STEP_SCHEMA_ACTION_ID = "9a7cf6dc-93c1-48d3-8392-45d0ef11ea2b";
|
|
61
|
+
static readonly AUTO_LINK_PARENT = false;
|
|
62
|
+
readonly actionName: string;
|
|
63
|
+
readonly schemaActionId: string;
|
|
64
|
+
readonly entity: string;
|
|
65
|
+
constructor(record: OdinRecord<any> | {
|
|
66
|
+
id: string;
|
|
67
|
+
entity: string;
|
|
68
|
+
type?: string;
|
|
69
|
+
}, properties: UpdateAdditionalNoteProperties, options?: {
|
|
70
|
+
journeyId?: string;
|
|
71
|
+
stageKey?: string;
|
|
72
|
+
});
|
|
73
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* UpdateAdditionalNote Action DTO
|
|
4
|
+
*
|
|
5
|
+
* Updates the additional note field
|
|
6
|
+
*
|
|
7
|
+
* @module SupportModule
|
|
8
|
+
* @entity Case
|
|
9
|
+
* @actionKey UpdateAdditionalNote
|
|
10
|
+
* @event k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote
|
|
11
|
+
*
|
|
12
|
+
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.UpdateAdditionalNoteDto = void 0;
|
|
16
|
+
const core_1 = require("@d19n/odin-types/dist/core");
|
|
17
|
+
/**
|
|
18
|
+
* UpdateAdditionalNote
|
|
19
|
+
*
|
|
20
|
+
* Updates the additional note field
|
|
21
|
+
*
|
|
22
|
+
* @actionType UPDATE - Updates an existing Case record
|
|
23
|
+
* @module SupportModule
|
|
24
|
+
* @entity Case
|
|
25
|
+
* @event k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote
|
|
26
|
+
* @permission schema.action.updateadditionalnote.trigger
|
|
27
|
+
* @benchmark This action is tracked for performance benchmarks
|
|
28
|
+
*/
|
|
29
|
+
class UpdateAdditionalNoteDto extends core_1.OdinRecordUpdateDto {
|
|
30
|
+
constructor(record, properties, options) {
|
|
31
|
+
super({
|
|
32
|
+
id: record.id,
|
|
33
|
+
entity: record.entity,
|
|
34
|
+
type: record.type,
|
|
35
|
+
properties,
|
|
36
|
+
journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
|
|
37
|
+
stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
|
|
38
|
+
});
|
|
39
|
+
this.actionName = 'UpdateAdditionalNote';
|
|
40
|
+
this.schemaActionId = '9a7cf6dc-93c1-48d3-8392-45d0ef11ea2b';
|
|
41
|
+
this.entity = 'SupportModule:Case';
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
exports.UpdateAdditionalNoteDto = UpdateAdditionalNoteDto;
|
|
45
|
+
/** Used by SDK generators to identify action type */
|
|
46
|
+
UpdateAdditionalNoteDto.ACTION_TYPE = 'UPDATE';
|
|
47
|
+
UpdateAdditionalNoteDto.ACTION_KEY = 'UpdateAdditionalNote';
|
|
48
|
+
UpdateAdditionalNoteDto.MODULE_NAME = 'SupportModule';
|
|
49
|
+
UpdateAdditionalNoteDto.ENTITIES = ['Case'];
|
|
50
|
+
UpdateAdditionalNoteDto.EVENT_NAME = 'k1.t-hEOJjsDb.SupportModule.Case.Update.UpdateAdditionalNote';
|
|
51
|
+
UpdateAdditionalNoteDto.PERMISSION = 'schema.action.updateadditionalnote.trigger';
|
|
52
|
+
/** Step metadata - entity this action targets */
|
|
53
|
+
UpdateAdditionalNoteDto.STEP_ENTITY = 'SupportModule:Case';
|
|
54
|
+
UpdateAdditionalNoteDto.STEP_SCHEMA_ID = 'bb540d25-53bf-491b-9d03-f3d42f755b3a';
|
|
55
|
+
UpdateAdditionalNoteDto.STEP_SCHEMA_ACTION_ID = '9a7cf6dc-93c1-48d3-8392-45d0ef11ea2b';
|
|
56
|
+
UpdateAdditionalNoteDto.AUTO_LINK_PARENT = false;
|
|
@@ -21,8 +21,8 @@ export interface UpdateContactMessage extends OdinRecordUpdatedEvent<UpdateConta
|
|
|
21
21
|
/**
|
|
22
22
|
* Properties for UpdateContact action
|
|
23
23
|
*
|
|
24
|
-
* @property Required fields:
|
|
25
|
-
* @property Optional fields:
|
|
24
|
+
* @property Required fields: 4
|
|
25
|
+
* @property Optional fields: 14
|
|
26
26
|
*/
|
|
27
27
|
export interface UpdateContactProperties {
|
|
28
28
|
/**
|
|
@@ -49,22 +49,13 @@ export interface UpdateContactProperties {
|
|
|
49
49
|
* @required
|
|
50
50
|
*/
|
|
51
51
|
LastName: string;
|
|
52
|
-
/**
|
|
53
|
-
* Additional Care Reason
|
|
54
|
-
*
|
|
55
|
-
* Primary reason for additional care (single select). (Sales - Contact)
|
|
56
|
-
* @type {ENUM}
|
|
57
|
-
* @required
|
|
58
|
-
* @visibleWhen AdditionalCareRequired = [true]
|
|
59
|
-
*/
|
|
60
|
-
AdditionalCareReason: string;
|
|
61
52
|
/**
|
|
62
53
|
* Additional Care Consent
|
|
63
54
|
*
|
|
64
55
|
* Customer consent for recording additional care requiremetns (Sales - Contact)
|
|
65
56
|
* @type {BOOLEAN}
|
|
66
57
|
* @required
|
|
67
|
-
* @visibleWhen AdditionalCareRequired = [true]
|
|
58
|
+
* @visibleWhen AdditionalCareRequired = [true,"YES"]
|
|
68
59
|
*/
|
|
69
60
|
AdditionalCareConsent: boolean;
|
|
70
61
|
/**
|
|
@@ -118,36 +109,44 @@ export interface UpdateContactProperties {
|
|
|
118
109
|
*/
|
|
119
110
|
CurrentContractType?: string | null;
|
|
120
111
|
/**
|
|
121
|
-
*
|
|
112
|
+
* Critical Dependencies
|
|
122
113
|
*
|
|
123
114
|
* Marks if the customer requires additional care (Ofcom vulnerable customer handling). (Sales - Contact)
|
|
124
|
-
* @type {
|
|
125
|
-
*/
|
|
126
|
-
AdditionalCareRequired?: boolean | null;
|
|
127
|
-
/**
|
|
128
|
-
* Additional Care Notes
|
|
129
|
-
*
|
|
130
|
-
* Free-text notes field for Contact. Used by Sales team for documentation.
|
|
131
|
-
* @type {TEXT_LONG}
|
|
132
|
-
* @visibleWhen AdditionalCareRequired = [true]
|
|
115
|
+
* @type {ENUM}
|
|
133
116
|
*/
|
|
134
|
-
|
|
117
|
+
AdditionalCareRequired?: string | null;
|
|
135
118
|
/**
|
|
136
119
|
* Medically Dependant
|
|
137
120
|
*
|
|
138
121
|
* Is the customer medically dependant on their broadband (Sales - Contact)
|
|
139
|
-
* @type {
|
|
140
|
-
* @visibleWhen AdditionalCareRequired = [true]
|
|
122
|
+
* @type {ENUM}
|
|
123
|
+
* @visibleWhen AdditionalCareRequired = [true,"YES"]
|
|
141
124
|
*/
|
|
142
|
-
MedicallyDependant?:
|
|
125
|
+
MedicallyDependant?: string | null;
|
|
143
126
|
/**
|
|
144
127
|
* Telecare Alarm
|
|
145
128
|
*
|
|
146
129
|
* Does the customer use a Telecare Alarm (Sales - Contact)
|
|
147
|
-
* @type {
|
|
148
|
-
* @visibleWhen AdditionalCareRequired = [true]
|
|
130
|
+
* @type {ENUM}
|
|
131
|
+
* @visibleWhen AdditionalCareRequired = [true,"YES"]
|
|
132
|
+
*/
|
|
133
|
+
TelecareAlarm?: string | null;
|
|
134
|
+
/**
|
|
135
|
+
* Additional Care Requirements
|
|
136
|
+
*
|
|
137
|
+
* Primary reason for additional care (single select). (Sales - Contact)
|
|
138
|
+
* @type {ENUM_MULTI_SELECT}
|
|
139
|
+
* @visibleWhen AdditionalCareRequired = [true,"YES"]
|
|
149
140
|
*/
|
|
150
|
-
|
|
141
|
+
AdditionalCareReason?: string | null;
|
|
142
|
+
/**
|
|
143
|
+
* Additional Care Notes
|
|
144
|
+
*
|
|
145
|
+
* Free-text notes field for Contact. Used by Sales team for documentation.
|
|
146
|
+
* @type {TEXT_LONG}
|
|
147
|
+
* @visibleWhen AdditionalCareRequired = [true,"YES"]
|
|
148
|
+
*/
|
|
149
|
+
AdditionalCareNotes?: string | null;
|
|
151
150
|
}
|
|
152
151
|
/**
|
|
153
152
|
* UpdateContact
|
|
@@ -37,6 +37,7 @@ export declare class AddressApi extends ApiProvider {
|
|
|
37
37
|
private _case?;
|
|
38
38
|
private _crmdataset?;
|
|
39
39
|
private _addressinteraction?;
|
|
40
|
+
private _yffieldservicevisit?;
|
|
40
41
|
constructor(authParams?: OauthParams, authToken?: string);
|
|
41
42
|
get file(): ApiRecordLinkManager;
|
|
42
43
|
get note(): ApiRecordLinkManager;
|
|
@@ -58,6 +59,7 @@ export declare class AddressApi extends ApiProvider {
|
|
|
58
59
|
get case(): ApiRecordLinkManager;
|
|
59
60
|
get crmdataset(): ApiRecordLinkManager;
|
|
60
61
|
get addressinteraction(): ApiRecordLinkManager;
|
|
62
|
+
get yffieldservicevisit(): ApiRecordLinkManager;
|
|
61
63
|
setRecord(sourceRecord: any): void;
|
|
62
64
|
schema(): Promise<import("@d19n/odin-types/dist/core").OdinSchema>;
|
|
63
65
|
search(params: Partial<OdinSearchV2>): Promise<import("@d19n/odin-sdk-generator/dist/odin-sdk-types").OdinSearchResponse<import("@d19n/odin-types/dist/core").OdinRecord<AddressProperties>>>;
|
|
@@ -153,6 +153,12 @@ class AddressApi extends api_provider_1.ApiProvider {
|
|
|
153
153
|
}
|
|
154
154
|
return this._addressinteraction;
|
|
155
155
|
}
|
|
156
|
+
get yffieldservicevisit() {
|
|
157
|
+
if (!this._yffieldservicevisit) {
|
|
158
|
+
this._yffieldservicevisit = new api_record_link_manager_1.ApiRecordLinkManager(this.authParams, 'CrmModule:Address', 'FieldServiceModule:YfFieldServiceVisit', 'YfFieldServiceVisit__ Address');
|
|
159
|
+
}
|
|
160
|
+
return this._yffieldservicevisit;
|
|
161
|
+
}
|
|
156
162
|
// ============================================
|
|
157
163
|
// STANDARD METHODS (Unchanged API)
|
|
158
164
|
// ============================================
|
|
@@ -37,7 +37,6 @@ export declare class ContactApi extends ApiProvider {
|
|
|
37
37
|
private _appointment?;
|
|
38
38
|
private _fingerprint?;
|
|
39
39
|
private _case?;
|
|
40
|
-
private _affiliatecode?;
|
|
41
40
|
private _organization?;
|
|
42
41
|
private _address?;
|
|
43
42
|
private _smsmessage?;
|
|
@@ -52,6 +51,7 @@ export declare class ContactApi extends ApiProvider {
|
|
|
52
51
|
private _workorder__alternative_contact?;
|
|
53
52
|
private _impersonationtracker?;
|
|
54
53
|
private _accountcredit?;
|
|
54
|
+
private _affiliatecode?;
|
|
55
55
|
constructor(authParams?: OauthParams, authToken?: string);
|
|
56
56
|
get note(): ApiRecordLinkManager;
|
|
57
57
|
get lead(): ApiRecordLinkManager;
|
|
@@ -73,7 +73,6 @@ export declare class ContactApi extends ApiProvider {
|
|
|
73
73
|
get appointment(): ApiRecordLinkManager;
|
|
74
74
|
get fingerprint(): ApiRecordLinkManager;
|
|
75
75
|
get case(): ApiRecordLinkManager;
|
|
76
|
-
get affiliatecode(): ApiRecordLinkManager;
|
|
77
76
|
get organization(): ApiRecordLinkManager;
|
|
78
77
|
get address(): ApiRecordLinkManager;
|
|
79
78
|
get smsmessage(): ApiRecordLinkManager;
|
|
@@ -88,6 +87,7 @@ export declare class ContactApi extends ApiProvider {
|
|
|
88
87
|
get workorder__alternative_contact(): ApiRecordLinkManager;
|
|
89
88
|
get impersonationtracker(): ApiRecordLinkManager;
|
|
90
89
|
get accountcredit(): ApiRecordLinkManager;
|
|
90
|
+
get affiliatecode(): ApiRecordLinkManager;
|
|
91
91
|
setRecord(sourceRecord: any): void;
|
|
92
92
|
schema(): Promise<import("@d19n/odin-types/dist/core").OdinSchema>;
|
|
93
93
|
search(params: Partial<OdinSearchV2>): Promise<import("@d19n/odin-sdk-generator/dist/odin-sdk-types").OdinSearchResponse<import("@d19n/odin-types/dist/core").OdinRecord<ContactProperties>>>;
|
|
@@ -153,12 +153,6 @@ class ContactApi extends api_provider_1.ApiProvider {
|
|
|
153
153
|
}
|
|
154
154
|
return this._case;
|
|
155
155
|
}
|
|
156
|
-
get affiliatecode() {
|
|
157
|
-
if (!this._affiliatecode) {
|
|
158
|
-
this._affiliatecode = new api_record_link_manager_1.ApiRecordLinkManager(this.authParams, 'CrmModule:Contact', 'CrmModule:AffiliateCode', 'ContactAffiliateCodes');
|
|
159
|
-
}
|
|
160
|
-
return this._affiliatecode;
|
|
161
|
-
}
|
|
162
156
|
get organization() {
|
|
163
157
|
if (!this._organization) {
|
|
164
158
|
this._organization = new api_record_link_manager_1.ApiRecordLinkManager(this.authParams, 'CrmModule:Contact', 'CrmModule:Organization', 'Organization__Contact');
|
|
@@ -243,6 +237,12 @@ class ContactApi extends api_provider_1.ApiProvider {
|
|
|
243
237
|
}
|
|
244
238
|
return this._accountcredit;
|
|
245
239
|
}
|
|
240
|
+
get affiliatecode() {
|
|
241
|
+
if (!this._affiliatecode) {
|
|
242
|
+
this._affiliatecode = new api_record_link_manager_1.ApiRecordLinkManager(this.authParams, 'CrmModule:Contact', 'CrmModule:AffiliateCode', 'ContactAffiliateCodes');
|
|
243
|
+
}
|
|
244
|
+
return this._affiliatecode;
|
|
245
|
+
}
|
|
246
246
|
// ============================================
|
|
247
247
|
// STANDARD METHODS (Unchanged API)
|
|
248
248
|
// ============================================
|
|
@@ -20,10 +20,12 @@ export declare class YfFieldServiceVisitApi extends ApiProvider {
|
|
|
20
20
|
private _note?;
|
|
21
21
|
private _file?;
|
|
22
22
|
private _workorder?;
|
|
23
|
+
private _address?;
|
|
23
24
|
constructor(authParams?: OauthParams, authToken?: string);
|
|
24
25
|
get note(): ApiRecordLinkManager;
|
|
25
26
|
get file(): ApiRecordLinkManager;
|
|
26
27
|
get workorder(): ApiRecordLinkManager;
|
|
28
|
+
get address(): ApiRecordLinkManager;
|
|
27
29
|
setRecord(sourceRecord: any): void;
|
|
28
30
|
schema(): Promise<import("@d19n/odin-types/dist/core").OdinSchema>;
|
|
29
31
|
search(params: Partial<OdinSearchV2>): Promise<import("@d19n/odin-sdk-generator/dist/odin-sdk-types").OdinSearchResponse<import("@d19n/odin-types/dist/core").OdinRecord<YfFieldServiceVisitProperties>>>;
|
|
@@ -51,6 +51,12 @@ class YfFieldServiceVisitApi extends api_provider_1.ApiProvider {
|
|
|
51
51
|
}
|
|
52
52
|
return this._workorder;
|
|
53
53
|
}
|
|
54
|
+
get address() {
|
|
55
|
+
if (!this._address) {
|
|
56
|
+
this._address = new api_record_link_manager_1.ApiRecordLinkManager(this.authParams, 'FieldServiceModule:YfFieldServiceVisit', 'CrmModule:Address', 'YfFieldServiceVisit__ Address');
|
|
57
|
+
}
|
|
58
|
+
return this._address;
|
|
59
|
+
}
|
|
54
60
|
// ============================================
|
|
55
61
|
// STANDARD METHODS (Unchanged API)
|
|
56
62
|
// ============================================
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* YfFieldServiceVisit DB Accessor
|
|
3
|
+
*
|
|
4
|
+
* Provides typed access to YfFieldServiceVisit records via direct database access.
|
|
5
|
+
* For use in backend services with principal + dbService.
|
|
6
|
+
* Returns wrapped records with typed action methods.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```typescript
|
|
10
|
+
* // Simple get
|
|
11
|
+
* const record = await accessor.get(id);
|
|
12
|
+
*
|
|
13
|
+
* // With related entities
|
|
14
|
+
* const record = await accessor.get(id, { entities: ["Contact", "Address"] });
|
|
15
|
+
*
|
|
16
|
+
* // With permissions bypass (separate options)
|
|
17
|
+
* const record = await accessor.get(id, {}, { omitPermissionsCheck: true });
|
|
18
|
+
*
|
|
19
|
+
* // Silent write (no RabbitMQ events)
|
|
20
|
+
* const result = await accessor.upsert([dto], { omitWriteEvents: true });
|
|
21
|
+
*
|
|
22
|
+
* // Constructor-level default (applies to all calls)
|
|
23
|
+
* const accessor = new YfFieldServiceVisitDbAccessor(principal, dbService, { omitPermissionsCheck: true });
|
|
24
|
+
* ```
|
|
25
|
+
*
|
|
26
|
+
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
27
|
+
*/
|
|
28
|
+
import { OdinSearchV2 } from '@d19n/odin-types/dist/core';
|
|
29
|
+
import { DbProvider, DbProviderOptions, DbGetQueryOptions } from '@d19n/odin-sdk-generator/dist/db.provider';
|
|
30
|
+
import { QueryBuilder } from '@d19n/odin-sdk-generator/dist/query-builder';
|
|
31
|
+
import { YfFieldServiceVisitProperties } from '../entities-v2/YfFieldServiceVisit';
|
|
32
|
+
import { YfFieldServiceVisitRecord } from '../records-v2/YfFieldServiceVisitRecord';
|
|
33
|
+
/** Search response with wrapped records */
|
|
34
|
+
export interface YfFieldServiceVisitDbSearchResponse {
|
|
35
|
+
records: YfFieldServiceVisitRecord[];
|
|
36
|
+
totalRecords: number;
|
|
37
|
+
hasMore: boolean;
|
|
38
|
+
}
|
|
39
|
+
export declare class YfFieldServiceVisitDbAccessor {
|
|
40
|
+
private readonly _provider;
|
|
41
|
+
private readonly _moduleName;
|
|
42
|
+
private readonly _entityName;
|
|
43
|
+
private readonly _defaultOptions?;
|
|
44
|
+
/**
|
|
45
|
+
* Create a new YfFieldServiceVisitDbAccessor
|
|
46
|
+
* @param principal - The authenticated principal
|
|
47
|
+
* @param dbService - The database service instance
|
|
48
|
+
* @param defaultOptions - Default provider options applied to all operations
|
|
49
|
+
*/
|
|
50
|
+
constructor(principal: any, dbService: any, defaultOptions?: DbProviderOptions);
|
|
51
|
+
get moduleName(): string;
|
|
52
|
+
get entityName(): string;
|
|
53
|
+
/**
|
|
54
|
+
* Create a new empty YfFieldServiceVisit record instance for create operations.
|
|
55
|
+
* Pre-generates an ID that can be referenced before the record is saved.
|
|
56
|
+
*
|
|
57
|
+
* @param id - Optional ID to use (auto-generated UUID if not provided)
|
|
58
|
+
* @returns A new record wrapper with pre-generated ID
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* ```typescript
|
|
62
|
+
* // Auto-generated ID
|
|
63
|
+
* const note = odinDb.notes.new();
|
|
64
|
+
* console.log(note.id); // UUID available immediately
|
|
65
|
+
*
|
|
66
|
+
* // Custom ID
|
|
67
|
+
* const order = odinDb.orders.new("custom-id-123");
|
|
68
|
+
*
|
|
69
|
+
* // Reference ID before save
|
|
70
|
+
* const account = odinDb.accounts.new();
|
|
71
|
+
* const contact = odinDb.contacts.new();
|
|
72
|
+
* await contact
|
|
73
|
+
* .link({ id: account.id, entity: "CrmModule:Account" })
|
|
74
|
+
* .createContact({ FirstName: "John" });
|
|
75
|
+
* ```
|
|
76
|
+
*/
|
|
77
|
+
new(id?: string): YfFieldServiceVisitRecord;
|
|
78
|
+
/**
|
|
79
|
+
* Get a single YfFieldServiceVisit record by ID
|
|
80
|
+
*
|
|
81
|
+
* @param id - The record ID
|
|
82
|
+
* @param queryOptions - Query options (WHAT to fetch: entities to include)
|
|
83
|
+
* @param providerOptions - Provider options (HOW to fetch: omitPermissionsCheck)
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* ```typescript
|
|
87
|
+
* // Simple get
|
|
88
|
+
* const record = await accessor.get(id);
|
|
89
|
+
*
|
|
90
|
+
* // With related entities
|
|
91
|
+
* const record = await accessor.get(id, { entities: ["Contact", "Address"] });
|
|
92
|
+
*
|
|
93
|
+
* // With permissions bypass
|
|
94
|
+
* const record = await accessor.get(id, {}, { omitPermissionsCheck: true });
|
|
95
|
+
*
|
|
96
|
+
* // Both options
|
|
97
|
+
* const record = await accessor.get(id, { entities: ["Invoice"] }, { omitPermissionsCheck: true });
|
|
98
|
+
* ```
|
|
99
|
+
*/
|
|
100
|
+
get(id: string, queryOptions?: DbGetQueryOptions, providerOptions?: DbProviderOptions): Promise<YfFieldServiceVisitRecord>;
|
|
101
|
+
/**
|
|
102
|
+
* Get multiple YfFieldServiceVisit records by IDs
|
|
103
|
+
*
|
|
104
|
+
* @param ids - Array of record IDs
|
|
105
|
+
* @param queryOptions - Query options (WHAT to fetch: entities to include)
|
|
106
|
+
* @param providerOptions - Provider options (HOW to fetch: omitPermissionsCheck)
|
|
107
|
+
*/
|
|
108
|
+
getMany(ids: string[], queryOptions?: DbGetQueryOptions, providerOptions?: DbProviderOptions): Promise<YfFieldServiceVisitRecord[]>;
|
|
109
|
+
/**
|
|
110
|
+
* Search YfFieldServiceVisit records
|
|
111
|
+
*
|
|
112
|
+
* @param params - Search parameters
|
|
113
|
+
* @param providerOptions - Provider options (HOW to fetch: omitPermissionsCheck)
|
|
114
|
+
*/
|
|
115
|
+
search(params: Partial<OdinSearchV2>, providerOptions?: DbProviderOptions): Promise<YfFieldServiceVisitDbSearchResponse>;
|
|
116
|
+
/**
|
|
117
|
+
* Search all YfFieldServiceVisit records with automatic pagination
|
|
118
|
+
*
|
|
119
|
+
* @param params - Search parameters
|
|
120
|
+
* @param providerOptions - Provider options (HOW to fetch: omitPermissionsCheck)
|
|
121
|
+
*/
|
|
122
|
+
searchAll(params: Partial<OdinSearchV2>, providerOptions?: DbProviderOptions): Promise<YfFieldServiceVisitRecord[]>;
|
|
123
|
+
/**
|
|
124
|
+
* Async generator for paginating through all matching records.
|
|
125
|
+
* Yields batches of wrapped records.
|
|
126
|
+
*
|
|
127
|
+
* @param params - Search parameters
|
|
128
|
+
* @param providerOptions - Provider options (HOW to fetch: omitPermissionsCheck)
|
|
129
|
+
*/
|
|
130
|
+
paginate(params: Partial<OdinSearchV2>, providerOptions?: DbProviderOptions): AsyncGenerator<YfFieldServiceVisitRecord[]>;
|
|
131
|
+
/**
|
|
132
|
+
* Create a fluent query builder for YfFieldServiceVisit records
|
|
133
|
+
*
|
|
134
|
+
* @example
|
|
135
|
+
* ```typescript
|
|
136
|
+
* const results = await accessor
|
|
137
|
+
* .query()
|
|
138
|
+
* .where('Status', 'in', ['Active', 'Pending'])
|
|
139
|
+
* .where('CreatedAt', 'gte', '2025-01-01')
|
|
140
|
+
* .select('id', 'title', 'properties.*')
|
|
141
|
+
* .sortBy('createdAt', 'desc')
|
|
142
|
+
* .limit(100)
|
|
143
|
+
* .execute();
|
|
144
|
+
* ```
|
|
145
|
+
*/
|
|
146
|
+
query(): QueryBuilder<YfFieldServiceVisitProperties, YfFieldServiceVisitRecord>;
|
|
147
|
+
/** Access the underlying DbProvider */
|
|
148
|
+
get provider(): DbProvider;
|
|
149
|
+
}
|