repzo 1.0.201 → 1.0.203
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/lib/index.d.ts +40 -2
- package/lib/index.js +87 -0
- package/lib/types/index.d.ts +388 -1
- package/package.json +1 -1
- package/src/index.ts +203 -0
- package/src/types/index.ts +409 -1
package/lib/index.d.ts
CHANGED
|
@@ -107,9 +107,13 @@ export declare const end_points: {
|
|
|
107
107
|
readonly REPORT_VIEW_DEFAULT: "report-view-default";
|
|
108
108
|
readonly REPORT_VIEW_FAVORITE: "report-view-favorite";
|
|
109
109
|
readonly COPY_REPORT_VIEW: "copy-report-view";
|
|
110
|
+
readonly CLM_PRESENTATION: "clm-presentation";
|
|
111
|
+
readonly CLM_SEQUENCE: "clm-sequence";
|
|
112
|
+
readonly CLM_SLIDE: "clm-slide";
|
|
113
|
+
readonly CLM_FEEDBACK_ACTIVITY: "clm-feedback-activity";
|
|
110
114
|
};
|
|
111
115
|
export type EndPoints = (typeof end_points)[keyof typeof end_points];
|
|
112
|
-
export declare const availableService: readonly ["client", "product", "variant", "category", "sub_category", "brand", "product_group", "tax", "measureunit", "measureunitFamily", "media", "priceList", "priceListItem", "team", "returnReason", "rep", "tag", "warehouse", "route", "productModifiersGroup", "channel", "speciality", "clientContact", "paymentTerm", "bank", "bank_list", "customStatus", "customList", "customListItem", "inventoryAdjustmentReason", "workorder", "workorderRequest", "supplier", "quickConvertToPdf", "visit", "activityFeedback", "activityFeedbackV2", "feedbackOption", "invoice", "proforma", "payment", "refund", "settlement", "check", "day", "receivingMaterial", "adjustAccount", "transfer", "msl", "mslProduct", "mediaStorage", "storecheckTemplate", "activityStorecheck", "adjustInventory", "inventory", "integrationApp", "joinActionsWebHook", "patchAction", "updateIntegrationMeta", "assetPartType", "assetPart", "assetPartUnit", "assetPartReceival", "assetPartTransfer", "returnAssetPartUnit", "storeAssetPartUnit", "ocrInvoiceJobTemplate", "ocrInvoiceJobGroup", "activityAiSalesOrder", "ocrInvoiceJob", "ocrInvoiceJobPage", "settings", "mailUnsubscribe", "approvalRequest", "safeInvoiceSerialCounter", "clientLocation", "assetType", "asset", "assetUnit", "workorderPortal", "approval", "workorderCategory", "contract", "contractInstallment", "repBalanceSummary", "workorderPortalLink", "customField", "salesAnalyticsReport"];
|
|
116
|
+
export declare const availableService: readonly ["client", "product", "variant", "category", "sub_category", "brand", "product_group", "tax", "measureunit", "measureunitFamily", "media", "priceList", "priceListItem", "team", "returnReason", "rep", "tag", "warehouse", "route", "productModifiersGroup", "channel", "speciality", "clientContact", "paymentTerm", "bank", "bank_list", "customStatus", "customList", "customListItem", "inventoryAdjustmentReason", "workorder", "workorderRequest", "supplier", "quickConvertToPdf", "visit", "activityFeedback", "activityFeedbackV2", "feedbackOption", "invoice", "proforma", "payment", "refund", "settlement", "check", "day", "receivingMaterial", "adjustAccount", "transfer", "msl", "mslProduct", "mediaStorage", "storecheckTemplate", "activityStorecheck", "adjustInventory", "inventory", "integrationApp", "joinActionsWebHook", "patchAction", "updateIntegrationMeta", "assetPartType", "assetPart", "assetPartUnit", "assetPartReceival", "assetPartTransfer", "returnAssetPartUnit", "storeAssetPartUnit", "ocrInvoiceJobTemplate", "ocrInvoiceJobGroup", "activityAiSalesOrder", "ocrInvoiceJob", "ocrInvoiceJobPage", "settings", "mailUnsubscribe", "approvalRequest", "safeInvoiceSerialCounter", "clientLocation", "assetType", "asset", "assetUnit", "workorderPortal", "approval", "workorderCategory", "contract", "contractInstallment", "repBalanceSummary", "workorderPortalLink", "customField", "salesAnalyticsReport", "clmPresentation", "clmSequence", "clmSlide"];
|
|
113
117
|
export type AvailableService = (typeof availableService)[number];
|
|
114
118
|
export default class Repzo {
|
|
115
119
|
private svAPIEndpoint;
|
|
@@ -225,13 +229,17 @@ export default class Repzo {
|
|
|
225
229
|
readonly REPORT_VIEW_DEFAULT: "report-view-default";
|
|
226
230
|
readonly REPORT_VIEW_FAVORITE: "report-view-favorite";
|
|
227
231
|
readonly COPY_REPORT_VIEW: "copy-report-view";
|
|
232
|
+
readonly CLM_PRESENTATION: "clm-presentation";
|
|
233
|
+
readonly CLM_SEQUENCE: "clm-sequence";
|
|
234
|
+
readonly CLM_SLIDE: "clm-slide";
|
|
235
|
+
readonly CLM_FEEDBACK_ACTIVITY: "clm-feedback-activity";
|
|
228
236
|
};
|
|
229
237
|
private _fetch;
|
|
230
238
|
private _create;
|
|
231
239
|
private _update;
|
|
232
240
|
private _patch;
|
|
233
241
|
private _delete;
|
|
234
|
-
available_services: readonly ["client", "product", "variant", "category", "sub_category", "brand", "product_group", "tax", "measureunit", "measureunitFamily", "media", "priceList", "priceListItem", "team", "returnReason", "rep", "tag", "warehouse", "route", "productModifiersGroup", "channel", "speciality", "clientContact", "paymentTerm", "bank", "bank_list", "customStatus", "customList", "customListItem", "inventoryAdjustmentReason", "workorder", "workorderRequest", "supplier", "quickConvertToPdf", "visit", "activityFeedback", "activityFeedbackV2", "feedbackOption", "invoice", "proforma", "payment", "refund", "settlement", "check", "day", "receivingMaterial", "adjustAccount", "transfer", "msl", "mslProduct", "mediaStorage", "storecheckTemplate", "activityStorecheck", "adjustInventory", "inventory", "integrationApp", "joinActionsWebHook", "patchAction", "updateIntegrationMeta", "assetPartType", "assetPart", "assetPartUnit", "assetPartReceival", "assetPartTransfer", "returnAssetPartUnit", "storeAssetPartUnit", "ocrInvoiceJobTemplate", "ocrInvoiceJobGroup", "activityAiSalesOrder", "ocrInvoiceJob", "ocrInvoiceJobPage", "settings", "mailUnsubscribe", "approvalRequest", "safeInvoiceSerialCounter", "clientLocation", "assetType", "asset", "assetUnit", "workorderPortal", "approval", "workorderCategory", "contract", "contractInstallment", "repBalanceSummary", "workorderPortalLink", "customField", "salesAnalyticsReport"];
|
|
242
|
+
available_services: readonly ["client", "product", "variant", "category", "sub_category", "brand", "product_group", "tax", "measureunit", "measureunitFamily", "media", "priceList", "priceListItem", "team", "returnReason", "rep", "tag", "warehouse", "route", "productModifiersGroup", "channel", "speciality", "clientContact", "paymentTerm", "bank", "bank_list", "customStatus", "customList", "customListItem", "inventoryAdjustmentReason", "workorder", "workorderRequest", "supplier", "quickConvertToPdf", "visit", "activityFeedback", "activityFeedbackV2", "feedbackOption", "invoice", "proforma", "payment", "refund", "settlement", "check", "day", "receivingMaterial", "adjustAccount", "transfer", "msl", "mslProduct", "mediaStorage", "storecheckTemplate", "activityStorecheck", "adjustInventory", "inventory", "integrationApp", "joinActionsWebHook", "patchAction", "updateIntegrationMeta", "assetPartType", "assetPart", "assetPartUnit", "assetPartReceival", "assetPartTransfer", "returnAssetPartUnit", "storeAssetPartUnit", "ocrInvoiceJobTemplate", "ocrInvoiceJobGroup", "activityAiSalesOrder", "ocrInvoiceJob", "ocrInvoiceJobPage", "settings", "mailUnsubscribe", "approvalRequest", "safeInvoiceSerialCounter", "clientLocation", "assetType", "asset", "assetUnit", "workorderPortal", "approval", "workorderCategory", "contract", "contractInstallment", "repBalanceSummary", "workorderPortalLink", "customField", "salesAnalyticsReport", "clmPresentation", "clmSequence", "clmSlide"];
|
|
235
243
|
client: {
|
|
236
244
|
_path: "client";
|
|
237
245
|
find: (params?: Service.Client.Find.Params) => Promise<Service.Client.Find.Result>;
|
|
@@ -1066,4 +1074,34 @@ export default class Repzo {
|
|
|
1066
1074
|
_path: "copy-report-view";
|
|
1067
1075
|
update: (id: Service.CopyReportView.Update.ID, body: Service.CopyReportView.Update.Body) => Promise<Service.CopyReportView.Update.Result>;
|
|
1068
1076
|
};
|
|
1077
|
+
clmPresentation: {
|
|
1078
|
+
_path: "clm-presentation";
|
|
1079
|
+
find: (params?: Service.CLMPresentation.Find.Params) => Promise<Service.CLMPresentation.Find.Result>;
|
|
1080
|
+
get: (id: Service.CLMPresentation.Get.ID, params?: Service.CLMPresentation.Get.Params) => Promise<Service.CLMPresentation.Get.Result>;
|
|
1081
|
+
create: (body: Service.CLMPresentation.Create.Body) => Promise<Service.CLMPresentation.Create.Result>;
|
|
1082
|
+
update: (id: Service.CLMPresentation.Update.ID, body: Service.CLMPresentation.Update.Body) => Promise<Service.CLMPresentation.Update.Result>;
|
|
1083
|
+
remove: (id: Service.CLMPresentation.Update.ID) => Promise<Service.CLMPresentation.Remove.Result>;
|
|
1084
|
+
};
|
|
1085
|
+
clmSequence: {
|
|
1086
|
+
_path: "clm-sequence";
|
|
1087
|
+
find: (params?: Service.CLMSequence.Find.Params) => Promise<Service.CLMSequence.Find.Result>;
|
|
1088
|
+
get: (id: Service.CLMSequence.Get.ID, params?: Service.CLMSequence.Get.Params) => Promise<Service.CLMSequence.Get.Result>;
|
|
1089
|
+
create: (body: Service.CLMSequence.Create.Body) => Promise<Service.CLMSequence.Create.Result>;
|
|
1090
|
+
update: (id: Service.CLMSequence.Update.ID, body: Service.CLMSequence.Update.Body) => Promise<Service.CLMSequence.Update.Result>;
|
|
1091
|
+
remove: (id: Service.CLMSequence.Update.ID) => Promise<Service.CLMSequence.Remove.Result>;
|
|
1092
|
+
};
|
|
1093
|
+
clmSlide: {
|
|
1094
|
+
_path: "clm-slide";
|
|
1095
|
+
find: (params?: Service.CLMSlide.Find.Params) => Promise<Service.CLMSlide.Find.Result>;
|
|
1096
|
+
get: (id: Service.CLMSlide.Get.ID, params?: Service.CLMSlide.Get.Params) => Promise<Service.CLMSlide.Get.Result>;
|
|
1097
|
+
create: (body: Service.CLMSlide.Create.Body) => Promise<Service.CLMSlide.Create.Result>;
|
|
1098
|
+
update: (id: Service.CLMSlide.Update.ID, body: Service.CLMSlide.Update.Body) => Promise<Service.CLMSlide.Update.Result>;
|
|
1099
|
+
remove: (id: Service.CLMSlide.Update.ID) => Promise<Service.CLMSlide.Remove.Result>;
|
|
1100
|
+
};
|
|
1101
|
+
clmFeedbackActivity: {
|
|
1102
|
+
_path: "clm-feedback-activity";
|
|
1103
|
+
find: (params?: Service.CLMFeedbackActivity.Find.Params) => Promise<Service.CLMFeedbackActivity.Find.Result>;
|
|
1104
|
+
get: (id: Service.CLMFeedbackActivity.Get.ID, params?: Service.CLMFeedbackActivity.Get.Params) => Promise<Service.CLMFeedbackActivity.Get.Result>;
|
|
1105
|
+
create: (body: Service.CLMFeedbackActivity.Create.Body) => Promise<Service.CLMFeedbackActivity.Create.Result>;
|
|
1106
|
+
};
|
|
1069
1107
|
}
|
package/lib/index.js
CHANGED
|
@@ -108,6 +108,10 @@ export const end_points = {
|
|
|
108
108
|
REPORT_VIEW_DEFAULT: "report-view-default",
|
|
109
109
|
REPORT_VIEW_FAVORITE: "report-view-favorite",
|
|
110
110
|
COPY_REPORT_VIEW: "copy-report-view",
|
|
111
|
+
CLM_PRESENTATION: "clm-presentation",
|
|
112
|
+
CLM_SEQUENCE: "clm-sequence",
|
|
113
|
+
CLM_SLIDE: "clm-slide",
|
|
114
|
+
CLM_FEEDBACK_ACTIVITY: "clm-feedback-activity",
|
|
111
115
|
};
|
|
112
116
|
export const availableService = [
|
|
113
117
|
"client",
|
|
@@ -198,6 +202,9 @@ export const availableService = [
|
|
|
198
202
|
"workorderPortalLink",
|
|
199
203
|
"customField",
|
|
200
204
|
"salesAnalyticsReport",
|
|
205
|
+
"clmPresentation",
|
|
206
|
+
"clmSequence",
|
|
207
|
+
"clmSlide",
|
|
201
208
|
];
|
|
202
209
|
class Repzo {
|
|
203
210
|
constructor(apiKey, options) {
|
|
@@ -2188,6 +2195,86 @@ class Repzo {
|
|
|
2188
2195
|
return res;
|
|
2189
2196
|
},
|
|
2190
2197
|
};
|
|
2198
|
+
this.clmPresentation = {
|
|
2199
|
+
_path: Repzo._end_points.CLM_PRESENTATION,
|
|
2200
|
+
find: async (params) => {
|
|
2201
|
+
let res = await this._fetch(this.svAPIEndpoint, this.clmPresentation._path, params);
|
|
2202
|
+
return res;
|
|
2203
|
+
},
|
|
2204
|
+
get: async (id, params) => {
|
|
2205
|
+
return await this._fetch(this.svAPIEndpoint, this.clmPresentation._path + `/${id}`, params);
|
|
2206
|
+
},
|
|
2207
|
+
create: async (body) => {
|
|
2208
|
+
let res = await this._create(this.svAPIEndpoint, this.clmPresentation._path, body);
|
|
2209
|
+
return res;
|
|
2210
|
+
},
|
|
2211
|
+
update: async (id, body) => {
|
|
2212
|
+
let res = await this._update(this.svAPIEndpoint, this.clmPresentation._path + `/${id}`, body);
|
|
2213
|
+
return res;
|
|
2214
|
+
},
|
|
2215
|
+
remove: async (id) => {
|
|
2216
|
+
let res = await this._delete(this.svAPIEndpoint, this.clmPresentation._path + `/${id}`);
|
|
2217
|
+
return res;
|
|
2218
|
+
},
|
|
2219
|
+
};
|
|
2220
|
+
this.clmSequence = {
|
|
2221
|
+
_path: Repzo._end_points.CLM_SEQUENCE,
|
|
2222
|
+
find: async (params) => {
|
|
2223
|
+
let res = await this._fetch(this.svAPIEndpoint, this.clmSequence._path, params);
|
|
2224
|
+
return res;
|
|
2225
|
+
},
|
|
2226
|
+
get: async (id, params) => {
|
|
2227
|
+
return await this._fetch(this.svAPIEndpoint, this.clmSequence._path + `/${id}`, params);
|
|
2228
|
+
},
|
|
2229
|
+
create: async (body) => {
|
|
2230
|
+
let res = await this._create(this.svAPIEndpoint, this.clmSequence._path, body);
|
|
2231
|
+
return res;
|
|
2232
|
+
},
|
|
2233
|
+
update: async (id, body) => {
|
|
2234
|
+
let res = await this._update(this.svAPIEndpoint, this.clmSequence._path + `/${id}`, body);
|
|
2235
|
+
return res;
|
|
2236
|
+
},
|
|
2237
|
+
remove: async (id) => {
|
|
2238
|
+
let res = await this._delete(this.svAPIEndpoint, this.clmSequence._path + `/${id}`);
|
|
2239
|
+
return res;
|
|
2240
|
+
},
|
|
2241
|
+
};
|
|
2242
|
+
this.clmSlide = {
|
|
2243
|
+
_path: Repzo._end_points.CLM_SLIDE,
|
|
2244
|
+
find: async (params) => {
|
|
2245
|
+
let res = await this._fetch(this.svAPIEndpoint, this.clmSlide._path, params);
|
|
2246
|
+
return res;
|
|
2247
|
+
},
|
|
2248
|
+
get: async (id, params) => {
|
|
2249
|
+
return await this._fetch(this.svAPIEndpoint, this.clmSlide._path + `/${id}`, params);
|
|
2250
|
+
},
|
|
2251
|
+
create: async (body) => {
|
|
2252
|
+
let res = await this._create(this.svAPIEndpoint, this.clmSlide._path, body);
|
|
2253
|
+
return res;
|
|
2254
|
+
},
|
|
2255
|
+
update: async (id, body) => {
|
|
2256
|
+
let res = await this._update(this.svAPIEndpoint, this.clmSlide._path + `/${id}`, body);
|
|
2257
|
+
return res;
|
|
2258
|
+
},
|
|
2259
|
+
remove: async (id) => {
|
|
2260
|
+
let res = await this._delete(this.svAPIEndpoint, this.clmSlide._path + `/${id}`);
|
|
2261
|
+
return res;
|
|
2262
|
+
},
|
|
2263
|
+
};
|
|
2264
|
+
this.clmFeedbackActivity = {
|
|
2265
|
+
_path: Repzo._end_points.CLM_FEEDBACK_ACTIVITY,
|
|
2266
|
+
find: async (params) => {
|
|
2267
|
+
let res = await this._fetch(this.svAPIEndpoint, this.clmFeedbackActivity._path, params);
|
|
2268
|
+
return res;
|
|
2269
|
+
},
|
|
2270
|
+
get: async (id, params) => {
|
|
2271
|
+
return await this._fetch(this.svAPIEndpoint, this.clmFeedbackActivity._path + `/${id}`, params);
|
|
2272
|
+
},
|
|
2273
|
+
create: async (body) => {
|
|
2274
|
+
let res = await this._create(this.svAPIEndpoint, this.clmFeedbackActivity._path, body);
|
|
2275
|
+
return res;
|
|
2276
|
+
},
|
|
2277
|
+
};
|
|
2191
2278
|
this.svAPIEndpoint =
|
|
2192
2279
|
!options?.env || options?.env == "production"
|
|
2193
2280
|
? "https://sv.api.repzo.me"
|
package/lib/types/index.d.ts
CHANGED
|
@@ -646,6 +646,7 @@ export declare namespace Service {
|
|
|
646
646
|
updatedAt: string;
|
|
647
647
|
__v: number;
|
|
648
648
|
}
|
|
649
|
+
export type Data = ProductSchema;
|
|
649
650
|
interface ProductBody {
|
|
650
651
|
name?: string;
|
|
651
652
|
category?: string;
|
|
@@ -1849,6 +1850,7 @@ export declare namespace Service {
|
|
|
1849
1850
|
previous_entry?: any;
|
|
1850
1851
|
show_previous_result?: boolean;
|
|
1851
1852
|
hidden?: boolean;
|
|
1853
|
+
force_live_photo?: boolean;
|
|
1852
1854
|
custom_list?: string;
|
|
1853
1855
|
custom_list_element?: string;
|
|
1854
1856
|
parent_field?: string;
|
|
@@ -2896,6 +2898,7 @@ export declare namespace Service {
|
|
|
2896
2898
|
createdAt: string;
|
|
2897
2899
|
updatedAt: string;
|
|
2898
2900
|
}
|
|
2901
|
+
export type Data = RouteSchema;
|
|
2899
2902
|
export interface RouteBody {
|
|
2900
2903
|
name?: string;
|
|
2901
2904
|
disabled?: boolean;
|
|
@@ -15930,7 +15933,7 @@ export declare namespace Service {
|
|
|
15930
15933
|
export {};
|
|
15931
15934
|
}
|
|
15932
15935
|
namespace NotificationsCenter {
|
|
15933
|
-
export type Command = "update-categories" | "update-clients" | "bulk-update-clients" | "update-inventory" | "update-measureunitFamilies" | "update-measureunits" | "update-pricelistItems" | "update-pricelists" | "update-products" | "update-rep" | "update-salesmsl" | "update-settings" | "update-tags" | "update-taxes" | "update-transfer" | "update-warehouses" | "update-jobCategories" | "update-plans" | "update-workorders" | "update-commentsThread" | "update-approval-request" | "update-variant-batch" | "update-asset-part-type" | "update-asset-part" | "update-asset-part-unit" | "update-custom-status" | "update-module-custom-validator" | "update-feedback-options" | "update-customfields";
|
|
15936
|
+
export type Command = "update-categories" | "update-clients" | "bulk-update-clients" | "update-inventory" | "update-measureunitFamilies" | "update-measureunits" | "update-pricelistItems" | "update-pricelists" | "update-products" | "update-rep" | "update-salesmsl" | "update-settings" | "update-tags" | "update-taxes" | "update-transfer" | "update-warehouses" | "update-jobCategories" | "update-plans" | "update-workorders" | "update-commentsThread" | "update-approval-request" | "update-variant-batch" | "update-asset-part-type" | "update-asset-part" | "update-asset-part-unit" | "update-custom-status" | "update-module-custom-validator" | "update-feedback-options" | "update-customfields" | "update-speciality" | "update-presentation" | "update-sequence" | "update-slide";
|
|
15934
15937
|
export interface Data {
|
|
15935
15938
|
_id: StringId;
|
|
15936
15939
|
command: Command;
|
|
@@ -16857,6 +16860,390 @@ export declare namespace Service {
|
|
|
16857
16860
|
};
|
|
16858
16861
|
}
|
|
16859
16862
|
}
|
|
16863
|
+
namespace CLMPresentation {
|
|
16864
|
+
export interface Data {
|
|
16865
|
+
_id: StringId;
|
|
16866
|
+
company_namespace: string[];
|
|
16867
|
+
name: string;
|
|
16868
|
+
disabled: boolean;
|
|
16869
|
+
teams: StringId[];
|
|
16870
|
+
createdAt: string;
|
|
16871
|
+
updatedAt: string;
|
|
16872
|
+
__v?: number;
|
|
16873
|
+
}
|
|
16874
|
+
export interface CreateBody {
|
|
16875
|
+
company_namespace?: string[];
|
|
16876
|
+
name: string;
|
|
16877
|
+
disabled?: boolean;
|
|
16878
|
+
teams?: StringId[];
|
|
16879
|
+
}
|
|
16880
|
+
export type UpdateBody = Partial<Data>;
|
|
16881
|
+
export type PopulatedDoc = Data & {
|
|
16882
|
+
teams_populated?: Pick<Team.TeamSchema, "name" | "_id">[];
|
|
16883
|
+
};
|
|
16884
|
+
type PopulatedKeys = "teams";
|
|
16885
|
+
type SortingKeys = "_id" | "createdAt" | "updatedAt";
|
|
16886
|
+
export namespace Find {
|
|
16887
|
+
type Params = DefaultPaginationQueryParams & {
|
|
16888
|
+
sortBy?: {
|
|
16889
|
+
field: SortingKeys;
|
|
16890
|
+
type: "asc" | "desc";
|
|
16891
|
+
}[];
|
|
16892
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
16893
|
+
_id?: StringId | StringId[];
|
|
16894
|
+
search?: string;
|
|
16895
|
+
name?: string | string[];
|
|
16896
|
+
disabled?: boolean;
|
|
16897
|
+
teams?: StringId | StringId[];
|
|
16898
|
+
from_updatedAt?: number;
|
|
16899
|
+
to_updatedAt?: number;
|
|
16900
|
+
from_createdAt?: number;
|
|
16901
|
+
to_createdAt?: number;
|
|
16902
|
+
};
|
|
16903
|
+
interface Result extends DefaultPaginationResult {
|
|
16904
|
+
data: PopulatedDoc[];
|
|
16905
|
+
}
|
|
16906
|
+
}
|
|
16907
|
+
export namespace Get {
|
|
16908
|
+
type ID = string;
|
|
16909
|
+
type Params = {
|
|
16910
|
+
populatedKeys?: PopulatedKeys[];
|
|
16911
|
+
};
|
|
16912
|
+
type Result = PopulatedDoc;
|
|
16913
|
+
}
|
|
16914
|
+
export namespace Create {
|
|
16915
|
+
type Body = CreateBody;
|
|
16916
|
+
type Result = Data;
|
|
16917
|
+
}
|
|
16918
|
+
export namespace Update {
|
|
16919
|
+
type ID = StringId;
|
|
16920
|
+
type Body = UpdateBody;
|
|
16921
|
+
type Result = Data;
|
|
16922
|
+
}
|
|
16923
|
+
export namespace Remove {
|
|
16924
|
+
type ID = string;
|
|
16925
|
+
type Result = Data;
|
|
16926
|
+
}
|
|
16927
|
+
export {};
|
|
16928
|
+
}
|
|
16929
|
+
namespace CLMSequence {
|
|
16930
|
+
export interface Data {
|
|
16931
|
+
_id: StringId;
|
|
16932
|
+
company_namespace: string[];
|
|
16933
|
+
presentation: StringId;
|
|
16934
|
+
product: StringId;
|
|
16935
|
+
disabled: boolean;
|
|
16936
|
+
position: number;
|
|
16937
|
+
createdAt: string;
|
|
16938
|
+
updatedAt: string;
|
|
16939
|
+
__v?: number;
|
|
16940
|
+
}
|
|
16941
|
+
export interface CreateBody {
|
|
16942
|
+
company_namespace?: string[];
|
|
16943
|
+
presentation: StringId;
|
|
16944
|
+
product: StringId;
|
|
16945
|
+
disabled?: boolean;
|
|
16946
|
+
position: number;
|
|
16947
|
+
}
|
|
16948
|
+
export type UpdateBody = Partial<Data>;
|
|
16949
|
+
export type PopulatedDoc = Data & {
|
|
16950
|
+
presentation_populated?: Pick<CLMPresentation.Data, "name" | "_id">[];
|
|
16951
|
+
product_populated?: Pick<Product.Data, "name" | "_id" | "local_name" | "barcode" | "sku">[];
|
|
16952
|
+
};
|
|
16953
|
+
type PopulatedKeys = "presentation" | "product";
|
|
16954
|
+
type SortingKeys = "_id" | "position";
|
|
16955
|
+
export namespace Find {
|
|
16956
|
+
type Params = DefaultPaginationQueryParams & {
|
|
16957
|
+
sortBy?: {
|
|
16958
|
+
field: SortingKeys;
|
|
16959
|
+
type: "asc" | "desc";
|
|
16960
|
+
}[];
|
|
16961
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
16962
|
+
_id?: StringId | StringId[];
|
|
16963
|
+
search?: string;
|
|
16964
|
+
product?: StringId | StringId[];
|
|
16965
|
+
presentation?: StringId | StringId[];
|
|
16966
|
+
disabled?: boolean;
|
|
16967
|
+
from_updatedAt?: number;
|
|
16968
|
+
to_updatedAt?: number;
|
|
16969
|
+
from_createdAt?: number;
|
|
16970
|
+
to_createdAt?: number;
|
|
16971
|
+
};
|
|
16972
|
+
interface Result extends DefaultPaginationResult {
|
|
16973
|
+
data: PopulatedDoc[];
|
|
16974
|
+
}
|
|
16975
|
+
}
|
|
16976
|
+
export namespace Get {
|
|
16977
|
+
type ID = string;
|
|
16978
|
+
type Params = {
|
|
16979
|
+
populatedKeys?: PopulatedKeys[];
|
|
16980
|
+
};
|
|
16981
|
+
type Result = PopulatedDoc;
|
|
16982
|
+
}
|
|
16983
|
+
export namespace Create {
|
|
16984
|
+
type Body = CreateBody;
|
|
16985
|
+
type Result = Data;
|
|
16986
|
+
}
|
|
16987
|
+
export namespace Update {
|
|
16988
|
+
type ID = StringId;
|
|
16989
|
+
type Body = UpdateBody;
|
|
16990
|
+
type Result = Data;
|
|
16991
|
+
}
|
|
16992
|
+
export namespace Remove {
|
|
16993
|
+
type ID = string;
|
|
16994
|
+
type Result = Data;
|
|
16995
|
+
}
|
|
16996
|
+
export {};
|
|
16997
|
+
}
|
|
16998
|
+
namespace CLMSlide {
|
|
16999
|
+
export interface Data {
|
|
17000
|
+
_id: StringId;
|
|
17001
|
+
company_namespace: string[];
|
|
17002
|
+
sequence: StringId;
|
|
17003
|
+
photo_media: StringId;
|
|
17004
|
+
is_book_mark?: boolean;
|
|
17005
|
+
book_mark_key_message?: string;
|
|
17006
|
+
disabled: boolean;
|
|
17007
|
+
position: number;
|
|
17008
|
+
createdAt: string;
|
|
17009
|
+
updatedAt: string;
|
|
17010
|
+
__v?: number;
|
|
17011
|
+
}
|
|
17012
|
+
export interface CreateBody {
|
|
17013
|
+
company_namespace?: string[];
|
|
17014
|
+
sequence: StringId;
|
|
17015
|
+
photo_media: StringId;
|
|
17016
|
+
is_book_mark?: boolean;
|
|
17017
|
+
book_mark_key_message?: string;
|
|
17018
|
+
disabled?: boolean;
|
|
17019
|
+
position: number;
|
|
17020
|
+
}
|
|
17021
|
+
export type UpdateBody = Partial<Data>;
|
|
17022
|
+
export type PopulatedDoc = Data & {
|
|
17023
|
+
sequence_populated?: Pick<CLMSequence.Data, "position" | "_id" | "product" | "presentation">[];
|
|
17024
|
+
photo_media_populated?: PopulatedMediaStorage;
|
|
17025
|
+
};
|
|
17026
|
+
type PopulatedKeys = "sequence" | "photo_media";
|
|
17027
|
+
type SortingKeys = "_id" | "position" | "is_book_mark";
|
|
17028
|
+
export namespace Find {
|
|
17029
|
+
type Params = DefaultPaginationQueryParams & {
|
|
17030
|
+
sortBy?: {
|
|
17031
|
+
field: SortingKeys;
|
|
17032
|
+
type: "asc" | "desc";
|
|
17033
|
+
}[];
|
|
17034
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
17035
|
+
_id?: StringId | StringId[];
|
|
17036
|
+
search?: string;
|
|
17037
|
+
sequence?: StringId | StringId[];
|
|
17038
|
+
is_book_mark?: boolean | boolean[];
|
|
17039
|
+
disabled?: boolean;
|
|
17040
|
+
from_updatedAt?: number;
|
|
17041
|
+
to_updatedAt?: number;
|
|
17042
|
+
from_createdAt?: number;
|
|
17043
|
+
to_createdAt?: number;
|
|
17044
|
+
};
|
|
17045
|
+
interface Result extends DefaultPaginationResult {
|
|
17046
|
+
data: PopulatedDoc[];
|
|
17047
|
+
}
|
|
17048
|
+
}
|
|
17049
|
+
export namespace Get {
|
|
17050
|
+
type ID = string;
|
|
17051
|
+
type Params = {
|
|
17052
|
+
populatedKeys?: PopulatedKeys[];
|
|
17053
|
+
};
|
|
17054
|
+
type Result = PopulatedDoc;
|
|
17055
|
+
}
|
|
17056
|
+
export namespace Create {
|
|
17057
|
+
type Body = CreateBody;
|
|
17058
|
+
type Result = Data;
|
|
17059
|
+
}
|
|
17060
|
+
export namespace Update {
|
|
17061
|
+
type ID = StringId;
|
|
17062
|
+
type Body = UpdateBody;
|
|
17063
|
+
type Result = Data;
|
|
17064
|
+
}
|
|
17065
|
+
export namespace Remove {
|
|
17066
|
+
type ID = string;
|
|
17067
|
+
type Result = Data;
|
|
17068
|
+
}
|
|
17069
|
+
export {};
|
|
17070
|
+
}
|
|
17071
|
+
namespace CLMFeedbackActivity {
|
|
17072
|
+
export interface Data {
|
|
17073
|
+
_id: StringId;
|
|
17074
|
+
geo_tag: GeoTag;
|
|
17075
|
+
geoPoint?: GeoPoint;
|
|
17076
|
+
time: number;
|
|
17077
|
+
tags?: StringId[];
|
|
17078
|
+
visit_id: string;
|
|
17079
|
+
visit?: StringId;
|
|
17080
|
+
creator: {
|
|
17081
|
+
_id: StringId;
|
|
17082
|
+
type: "rep";
|
|
17083
|
+
name?: string;
|
|
17084
|
+
rep?: StringId;
|
|
17085
|
+
};
|
|
17086
|
+
client: StringId;
|
|
17087
|
+
client_name: string;
|
|
17088
|
+
sync_id: string;
|
|
17089
|
+
teams?: StringId[];
|
|
17090
|
+
route?: StringId;
|
|
17091
|
+
platform?: string;
|
|
17092
|
+
version_name?: string;
|
|
17093
|
+
battery_level?: number;
|
|
17094
|
+
device_brand?: string;
|
|
17095
|
+
device_os?: string;
|
|
17096
|
+
device_os_version?: string;
|
|
17097
|
+
device_model?: string;
|
|
17098
|
+
time_zone?: string;
|
|
17099
|
+
identifier?: number;
|
|
17100
|
+
device_id?: string;
|
|
17101
|
+
device_unique_id?: string;
|
|
17102
|
+
network_state?: number;
|
|
17103
|
+
job_start_time?: number;
|
|
17104
|
+
job_end_time?: number;
|
|
17105
|
+
job_duration?: number;
|
|
17106
|
+
company_namespace: string[];
|
|
17107
|
+
createdAt: string;
|
|
17108
|
+
updatedAt: string;
|
|
17109
|
+
__v?: number;
|
|
17110
|
+
completion_status: "ended" | "canceled";
|
|
17111
|
+
presentation: StringId;
|
|
17112
|
+
presentation_name: string;
|
|
17113
|
+
duration_on_presentation_ms: number;
|
|
17114
|
+
result: [
|
|
17115
|
+
{
|
|
17116
|
+
sequence: StringId;
|
|
17117
|
+
sequence_name: string;
|
|
17118
|
+
duration_on_sequence_ms: number;
|
|
17119
|
+
slides: [
|
|
17120
|
+
{
|
|
17121
|
+
slide: StringId;
|
|
17122
|
+
feedback: "positive" | "negative";
|
|
17123
|
+
duration_on_slide_ms: number;
|
|
17124
|
+
}
|
|
17125
|
+
];
|
|
17126
|
+
}
|
|
17127
|
+
];
|
|
17128
|
+
interactions: [
|
|
17129
|
+
{
|
|
17130
|
+
interaction_time: number;
|
|
17131
|
+
interaction_type: "slide_landing" | "slide_leaving" | "zoom" | "feedback_given" | "presentation_play" | "presentation_end" | "presentation_cancel";
|
|
17132
|
+
interaction_detail: "in" | "out" | "positive" | "negative" | null;
|
|
17133
|
+
slide?: StringId;
|
|
17134
|
+
sequence?: StringId;
|
|
17135
|
+
}
|
|
17136
|
+
];
|
|
17137
|
+
}
|
|
17138
|
+
export interface CreateBody {
|
|
17139
|
+
geo_tag: GeoTag;
|
|
17140
|
+
geoPoint?: GeoPoint;
|
|
17141
|
+
time: number;
|
|
17142
|
+
tags?: StringId[];
|
|
17143
|
+
visit_id: string;
|
|
17144
|
+
creator?: {
|
|
17145
|
+
_id: StringId;
|
|
17146
|
+
type: "rep";
|
|
17147
|
+
name?: string;
|
|
17148
|
+
rep?: StringId;
|
|
17149
|
+
};
|
|
17150
|
+
client: StringId;
|
|
17151
|
+
client_name: string;
|
|
17152
|
+
sync_id: string;
|
|
17153
|
+
teams?: StringId[];
|
|
17154
|
+
route?: StringId;
|
|
17155
|
+
platform?: string;
|
|
17156
|
+
version_name?: string;
|
|
17157
|
+
battery_level?: number;
|
|
17158
|
+
device_brand?: string;
|
|
17159
|
+
device_os?: string;
|
|
17160
|
+
device_os_version?: string;
|
|
17161
|
+
device_model?: string;
|
|
17162
|
+
time_zone?: string;
|
|
17163
|
+
identifier?: number;
|
|
17164
|
+
device_id?: string;
|
|
17165
|
+
device_unique_id?: string;
|
|
17166
|
+
network_state?: number;
|
|
17167
|
+
job_start_time?: number;
|
|
17168
|
+
job_end_time?: number;
|
|
17169
|
+
job_duration?: number;
|
|
17170
|
+
company_namespace?: string[];
|
|
17171
|
+
completion_status: "ended" | "canceled";
|
|
17172
|
+
presentation: StringId;
|
|
17173
|
+
presentation_name: string;
|
|
17174
|
+
duration_on_presentation_ms: number;
|
|
17175
|
+
result?: [
|
|
17176
|
+
{
|
|
17177
|
+
sequence: StringId;
|
|
17178
|
+
sequence_name: string;
|
|
17179
|
+
duration_on_sequence_ms: number;
|
|
17180
|
+
slides: [
|
|
17181
|
+
{
|
|
17182
|
+
slide: StringId;
|
|
17183
|
+
feedback: "positive" | "negative";
|
|
17184
|
+
duration_on_slide_ms: number;
|
|
17185
|
+
}
|
|
17186
|
+
];
|
|
17187
|
+
}
|
|
17188
|
+
];
|
|
17189
|
+
interactions: [
|
|
17190
|
+
{
|
|
17191
|
+
interaction_time: number;
|
|
17192
|
+
interaction_type: "slide_landing" | "slide_leaving" | "zoom" | "feedback_given" | "presentation_play" | "presentation_end" | "presentation_cancel";
|
|
17193
|
+
interaction_detail: "in" | "out" | "positive" | "negative" | null;
|
|
17194
|
+
slide?: StringId;
|
|
17195
|
+
sequence?: StringId;
|
|
17196
|
+
}
|
|
17197
|
+
];
|
|
17198
|
+
}
|
|
17199
|
+
export type PopulatedDoc = Data & {
|
|
17200
|
+
client_populated?: Pick<Client.Data, "_id" | "name" | "local_name" | "client_code">[];
|
|
17201
|
+
visit_populated?: Visit.Data;
|
|
17202
|
+
route_populated?: Pick<Route.Data, "_id" | "name">;
|
|
17203
|
+
teams_populated?: Pick<Team.TeamSchema, "name" | "_id">[];
|
|
17204
|
+
tags_populated?: Pick<Tag.Data, "_id" | "tag" | "type">[];
|
|
17205
|
+
presentation_populated?: Pick<CLMPresentation.Data, "name" | "_id">;
|
|
17206
|
+
};
|
|
17207
|
+
type PopulatedKeys = "client" | "visit" | "route" | "teams" | "tags" | "presentation";
|
|
17208
|
+
export namespace Find {
|
|
17209
|
+
type Params = DefaultPaginationQueryParams & {
|
|
17210
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
17211
|
+
from_time?: number;
|
|
17212
|
+
to_time?: number;
|
|
17213
|
+
_id?: StringId | StringId[];
|
|
17214
|
+
presentation?: StringId | StringId[];
|
|
17215
|
+
client?: StringId | StringId[];
|
|
17216
|
+
tags?: StringId | StringId[];
|
|
17217
|
+
CLIENT_TAGS?: StringId | StringId[];
|
|
17218
|
+
AREA_TAGS?: StringId | StringId[];
|
|
17219
|
+
teams?: StringId | StringId[];
|
|
17220
|
+
route?: StringId | StringId[];
|
|
17221
|
+
creator?: StringId | StringId[];
|
|
17222
|
+
creator_id?: StringId | StringId[];
|
|
17223
|
+
creator_type?: StringId | StringId[];
|
|
17224
|
+
"creator._id"?: StringId | StringId[];
|
|
17225
|
+
"creator.type"?: StringId | StringId[];
|
|
17226
|
+
visit_id?: string | string[];
|
|
17227
|
+
visit?: StringId | StringId[];
|
|
17228
|
+
sync_id?: string | string[];
|
|
17229
|
+
};
|
|
17230
|
+
interface Result extends DefaultPaginationResult {
|
|
17231
|
+
data: PopulatedDoc[];
|
|
17232
|
+
}
|
|
17233
|
+
}
|
|
17234
|
+
export namespace Get {
|
|
17235
|
+
type ID = string;
|
|
17236
|
+
type Params = {
|
|
17237
|
+
populatedKeys?: PopulatedKeys[];
|
|
17238
|
+
};
|
|
17239
|
+
type Result = PopulatedDoc;
|
|
17240
|
+
}
|
|
17241
|
+
export namespace Create {
|
|
17242
|
+
type Body = CreateBody;
|
|
17243
|
+
type Result = Data;
|
|
17244
|
+
}
|
|
17245
|
+
export {};
|
|
17246
|
+
}
|
|
16860
17247
|
}
|
|
16861
17248
|
export type StringId = string;
|
|
16862
17249
|
export type NameSpaces = string[];
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -118,6 +118,10 @@ export const end_points = {
|
|
|
118
118
|
REPORT_VIEW_DEFAULT: "report-view-default",
|
|
119
119
|
REPORT_VIEW_FAVORITE: "report-view-favorite",
|
|
120
120
|
COPY_REPORT_VIEW: "copy-report-view",
|
|
121
|
+
CLM_PRESENTATION: "clm-presentation",
|
|
122
|
+
CLM_SEQUENCE: "clm-sequence",
|
|
123
|
+
CLM_SLIDE: "clm-slide",
|
|
124
|
+
CLM_FEEDBACK_ACTIVITY: "clm-feedback-activity",
|
|
121
125
|
} as const;
|
|
122
126
|
export type EndPoints = (typeof end_points)[keyof typeof end_points];
|
|
123
127
|
|
|
@@ -210,6 +214,9 @@ export const availableService = [
|
|
|
210
214
|
"workorderPortalLink",
|
|
211
215
|
"customField",
|
|
212
216
|
"salesAnalyticsReport",
|
|
217
|
+
"clmPresentation",
|
|
218
|
+
"clmSequence",
|
|
219
|
+
"clmSlide",
|
|
213
220
|
] as const;
|
|
214
221
|
export type AvailableService = (typeof availableService)[number];
|
|
215
222
|
|
|
@@ -5564,6 +5571,202 @@ export default class Repzo {
|
|
|
5564
5571
|
return res;
|
|
5565
5572
|
},
|
|
5566
5573
|
};
|
|
5574
|
+
|
|
5575
|
+
clmPresentation = {
|
|
5576
|
+
_path: Repzo._end_points.CLM_PRESENTATION,
|
|
5577
|
+
find: async (
|
|
5578
|
+
params?: Service.CLMPresentation.Find.Params,
|
|
5579
|
+
): Promise<Service.CLMPresentation.Find.Result> => {
|
|
5580
|
+
let res: Service.CLMPresentation.Find.Result = await this._fetch(
|
|
5581
|
+
this.svAPIEndpoint,
|
|
5582
|
+
this.clmPresentation._path,
|
|
5583
|
+
params,
|
|
5584
|
+
);
|
|
5585
|
+
return res;
|
|
5586
|
+
},
|
|
5587
|
+
get: async (
|
|
5588
|
+
id: Service.CLMPresentation.Get.ID,
|
|
5589
|
+
params?: Service.CLMPresentation.Get.Params,
|
|
5590
|
+
): Promise<Service.CLMPresentation.Get.Result> => {
|
|
5591
|
+
return await this._fetch(
|
|
5592
|
+
this.svAPIEndpoint,
|
|
5593
|
+
this.clmPresentation._path + `/${id}`,
|
|
5594
|
+
params,
|
|
5595
|
+
);
|
|
5596
|
+
},
|
|
5597
|
+
create: async (
|
|
5598
|
+
body: Service.CLMPresentation.Create.Body,
|
|
5599
|
+
): Promise<Service.CLMPresentation.Create.Result> => {
|
|
5600
|
+
let res = await this._create(
|
|
5601
|
+
this.svAPIEndpoint,
|
|
5602
|
+
this.clmPresentation._path,
|
|
5603
|
+
body,
|
|
5604
|
+
);
|
|
5605
|
+
return res;
|
|
5606
|
+
},
|
|
5607
|
+
update: async (
|
|
5608
|
+
id: Service.CLMPresentation.Update.ID,
|
|
5609
|
+
body: Service.CLMPresentation.Update.Body,
|
|
5610
|
+
): Promise<Service.CLMPresentation.Update.Result> => {
|
|
5611
|
+
let res: Service.CLMPresentation.Update.Result = await this._update(
|
|
5612
|
+
this.svAPIEndpoint,
|
|
5613
|
+
this.clmPresentation._path + `/${id}`,
|
|
5614
|
+
body,
|
|
5615
|
+
);
|
|
5616
|
+
return res;
|
|
5617
|
+
},
|
|
5618
|
+
remove: async (
|
|
5619
|
+
id: Service.CLMPresentation.Update.ID,
|
|
5620
|
+
): Promise<Service.CLMPresentation.Remove.Result> => {
|
|
5621
|
+
let res: Service.CLMPresentation.Remove.Result = await this._delete(
|
|
5622
|
+
this.svAPIEndpoint,
|
|
5623
|
+
this.clmPresentation._path + `/${id}`,
|
|
5624
|
+
);
|
|
5625
|
+
return res;
|
|
5626
|
+
},
|
|
5627
|
+
};
|
|
5628
|
+
|
|
5629
|
+
clmSequence = {
|
|
5630
|
+
_path: Repzo._end_points.CLM_SEQUENCE,
|
|
5631
|
+
find: async (
|
|
5632
|
+
params?: Service.CLMSequence.Find.Params,
|
|
5633
|
+
): Promise<Service.CLMSequence.Find.Result> => {
|
|
5634
|
+
let res: Service.CLMSequence.Find.Result = await this._fetch(
|
|
5635
|
+
this.svAPIEndpoint,
|
|
5636
|
+
this.clmSequence._path,
|
|
5637
|
+
params,
|
|
5638
|
+
);
|
|
5639
|
+
return res;
|
|
5640
|
+
},
|
|
5641
|
+
get: async (
|
|
5642
|
+
id: Service.CLMSequence.Get.ID,
|
|
5643
|
+
params?: Service.CLMSequence.Get.Params,
|
|
5644
|
+
): Promise<Service.CLMSequence.Get.Result> => {
|
|
5645
|
+
return await this._fetch(
|
|
5646
|
+
this.svAPIEndpoint,
|
|
5647
|
+
this.clmSequence._path + `/${id}`,
|
|
5648
|
+
params,
|
|
5649
|
+
);
|
|
5650
|
+
},
|
|
5651
|
+
create: async (
|
|
5652
|
+
body: Service.CLMSequence.Create.Body,
|
|
5653
|
+
): Promise<Service.CLMSequence.Create.Result> => {
|
|
5654
|
+
let res = await this._create(
|
|
5655
|
+
this.svAPIEndpoint,
|
|
5656
|
+
this.clmSequence._path,
|
|
5657
|
+
body,
|
|
5658
|
+
);
|
|
5659
|
+
return res;
|
|
5660
|
+
},
|
|
5661
|
+
update: async (
|
|
5662
|
+
id: Service.CLMSequence.Update.ID,
|
|
5663
|
+
body: Service.CLMSequence.Update.Body,
|
|
5664
|
+
): Promise<Service.CLMSequence.Update.Result> => {
|
|
5665
|
+
let res: Service.CLMSequence.Update.Result = await this._update(
|
|
5666
|
+
this.svAPIEndpoint,
|
|
5667
|
+
this.clmSequence._path + `/${id}`,
|
|
5668
|
+
body,
|
|
5669
|
+
);
|
|
5670
|
+
return res;
|
|
5671
|
+
},
|
|
5672
|
+
remove: async (
|
|
5673
|
+
id: Service.CLMSequence.Update.ID,
|
|
5674
|
+
): Promise<Service.CLMSequence.Remove.Result> => {
|
|
5675
|
+
let res: Service.CLMSequence.Remove.Result = await this._delete(
|
|
5676
|
+
this.svAPIEndpoint,
|
|
5677
|
+
this.clmSequence._path + `/${id}`,
|
|
5678
|
+
);
|
|
5679
|
+
return res;
|
|
5680
|
+
},
|
|
5681
|
+
};
|
|
5682
|
+
|
|
5683
|
+
clmSlide = {
|
|
5684
|
+
_path: Repzo._end_points.CLM_SLIDE,
|
|
5685
|
+
find: async (
|
|
5686
|
+
params?: Service.CLMSlide.Find.Params,
|
|
5687
|
+
): Promise<Service.CLMSlide.Find.Result> => {
|
|
5688
|
+
let res: Service.CLMSlide.Find.Result = await this._fetch(
|
|
5689
|
+
this.svAPIEndpoint,
|
|
5690
|
+
this.clmSlide._path,
|
|
5691
|
+
params,
|
|
5692
|
+
);
|
|
5693
|
+
return res;
|
|
5694
|
+
},
|
|
5695
|
+
get: async (
|
|
5696
|
+
id: Service.CLMSlide.Get.ID,
|
|
5697
|
+
params?: Service.CLMSlide.Get.Params,
|
|
5698
|
+
): Promise<Service.CLMSlide.Get.Result> => {
|
|
5699
|
+
return await this._fetch(
|
|
5700
|
+
this.svAPIEndpoint,
|
|
5701
|
+
this.clmSlide._path + `/${id}`,
|
|
5702
|
+
params,
|
|
5703
|
+
);
|
|
5704
|
+
},
|
|
5705
|
+
create: async (
|
|
5706
|
+
body: Service.CLMSlide.Create.Body,
|
|
5707
|
+
): Promise<Service.CLMSlide.Create.Result> => {
|
|
5708
|
+
let res = await this._create(
|
|
5709
|
+
this.svAPIEndpoint,
|
|
5710
|
+
this.clmSlide._path,
|
|
5711
|
+
body,
|
|
5712
|
+
);
|
|
5713
|
+
return res;
|
|
5714
|
+
},
|
|
5715
|
+
update: async (
|
|
5716
|
+
id: Service.CLMSlide.Update.ID,
|
|
5717
|
+
body: Service.CLMSlide.Update.Body,
|
|
5718
|
+
): Promise<Service.CLMSlide.Update.Result> => {
|
|
5719
|
+
let res: Service.CLMSlide.Update.Result = await this._update(
|
|
5720
|
+
this.svAPIEndpoint,
|
|
5721
|
+
this.clmSlide._path + `/${id}`,
|
|
5722
|
+
body,
|
|
5723
|
+
);
|
|
5724
|
+
return res;
|
|
5725
|
+
},
|
|
5726
|
+
remove: async (
|
|
5727
|
+
id: Service.CLMSlide.Update.ID,
|
|
5728
|
+
): Promise<Service.CLMSlide.Remove.Result> => {
|
|
5729
|
+
let res: Service.CLMSlide.Remove.Result = await this._delete(
|
|
5730
|
+
this.svAPIEndpoint,
|
|
5731
|
+
this.clmSlide._path + `/${id}`,
|
|
5732
|
+
);
|
|
5733
|
+
return res;
|
|
5734
|
+
},
|
|
5735
|
+
};
|
|
5736
|
+
|
|
5737
|
+
clmFeedbackActivity = {
|
|
5738
|
+
_path: Repzo._end_points.CLM_FEEDBACK_ACTIVITY,
|
|
5739
|
+
find: async (
|
|
5740
|
+
params?: Service.CLMFeedbackActivity.Find.Params,
|
|
5741
|
+
): Promise<Service.CLMFeedbackActivity.Find.Result> => {
|
|
5742
|
+
let res: Service.CLMFeedbackActivity.Find.Result = await this._fetch(
|
|
5743
|
+
this.svAPIEndpoint,
|
|
5744
|
+
this.clmFeedbackActivity._path,
|
|
5745
|
+
params,
|
|
5746
|
+
);
|
|
5747
|
+
return res;
|
|
5748
|
+
},
|
|
5749
|
+
get: async (
|
|
5750
|
+
id: Service.CLMFeedbackActivity.Get.ID,
|
|
5751
|
+
params?: Service.CLMFeedbackActivity.Get.Params,
|
|
5752
|
+
): Promise<Service.CLMFeedbackActivity.Get.Result> => {
|
|
5753
|
+
return await this._fetch(
|
|
5754
|
+
this.svAPIEndpoint,
|
|
5755
|
+
this.clmFeedbackActivity._path + `/${id}`,
|
|
5756
|
+
params,
|
|
5757
|
+
);
|
|
5758
|
+
},
|
|
5759
|
+
create: async (
|
|
5760
|
+
body: Service.CLMFeedbackActivity.Create.Body,
|
|
5761
|
+
): Promise<Service.CLMFeedbackActivity.Create.Result> => {
|
|
5762
|
+
let res = await this._create(
|
|
5763
|
+
this.svAPIEndpoint,
|
|
5764
|
+
this.clmFeedbackActivity._path,
|
|
5765
|
+
body,
|
|
5766
|
+
);
|
|
5767
|
+
return res;
|
|
5768
|
+
},
|
|
5769
|
+
};
|
|
5567
5770
|
}
|
|
5568
5771
|
|
|
5569
5772
|
function normalizeParams(params: Params): { [key: string]: any } {
|
package/src/types/index.ts
CHANGED
|
@@ -849,6 +849,7 @@ export namespace Service {
|
|
|
849
849
|
updatedAt: string;
|
|
850
850
|
__v: number;
|
|
851
851
|
}
|
|
852
|
+
export type Data = ProductSchema;
|
|
852
853
|
interface ProductBody {
|
|
853
854
|
name?: string;
|
|
854
855
|
category?: string;
|
|
@@ -2211,6 +2212,7 @@ export namespace Service {
|
|
|
2211
2212
|
previous_entry?: any;
|
|
2212
2213
|
show_previous_result?: boolean;
|
|
2213
2214
|
hidden?: boolean;
|
|
2215
|
+
force_live_photo?: boolean;
|
|
2214
2216
|
custom_list?: string;
|
|
2215
2217
|
custom_list_element?: string;
|
|
2216
2218
|
parent_field?: string;
|
|
@@ -3320,6 +3322,7 @@ export namespace Service {
|
|
|
3320
3322
|
createdAt: string;
|
|
3321
3323
|
updatedAt: string;
|
|
3322
3324
|
}
|
|
3325
|
+
export type Data = RouteSchema;
|
|
3323
3326
|
export interface RouteBody {
|
|
3324
3327
|
name?: string;
|
|
3325
3328
|
disabled?: boolean;
|
|
@@ -18104,7 +18107,12 @@ export namespace Service {
|
|
|
18104
18107
|
| "update-custom-status"
|
|
18105
18108
|
| "update-module-custom-validator"
|
|
18106
18109
|
| "update-feedback-options"
|
|
18107
|
-
| "update-customfields"
|
|
18110
|
+
| "update-customfields"
|
|
18111
|
+
| "update-speciality"
|
|
18112
|
+
| "update-presentation"
|
|
18113
|
+
| "update-sequence"
|
|
18114
|
+
| "update-slide";
|
|
18115
|
+
|
|
18108
18116
|
export interface Data {
|
|
18109
18117
|
_id: StringId;
|
|
18110
18118
|
command: Command;
|
|
@@ -19107,6 +19115,406 @@ export namespace Service {
|
|
|
19107
19115
|
export type Result = ReportView.Data & { copied_from: StringId };
|
|
19108
19116
|
}
|
|
19109
19117
|
}
|
|
19118
|
+
|
|
19119
|
+
export namespace CLMPresentation {
|
|
19120
|
+
export interface Data {
|
|
19121
|
+
_id: StringId;
|
|
19122
|
+
company_namespace: string[];
|
|
19123
|
+
name: string;
|
|
19124
|
+
disabled: boolean;
|
|
19125
|
+
teams: StringId[];
|
|
19126
|
+
createdAt: string;
|
|
19127
|
+
updatedAt: string;
|
|
19128
|
+
__v?: number;
|
|
19129
|
+
}
|
|
19130
|
+
export interface CreateBody {
|
|
19131
|
+
company_namespace?: string[];
|
|
19132
|
+
name: string;
|
|
19133
|
+
disabled?: boolean;
|
|
19134
|
+
teams?: StringId[];
|
|
19135
|
+
}
|
|
19136
|
+
export type UpdateBody = Partial<Data>;
|
|
19137
|
+
|
|
19138
|
+
export type PopulatedDoc = Data & {
|
|
19139
|
+
teams_populated?: Pick<Team.TeamSchema, "name" | "_id">[];
|
|
19140
|
+
};
|
|
19141
|
+
|
|
19142
|
+
type PopulatedKeys = "teams";
|
|
19143
|
+
type SortingKeys = "_id" | "createdAt" | "updatedAt";
|
|
19144
|
+
|
|
19145
|
+
export namespace Find {
|
|
19146
|
+
export type Params = DefaultPaginationQueryParams & {
|
|
19147
|
+
sortBy?: { field: SortingKeys; type: "asc" | "desc" }[];
|
|
19148
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
19149
|
+
_id?: StringId | StringId[];
|
|
19150
|
+
search?: string;
|
|
19151
|
+
name?: string | string[];
|
|
19152
|
+
disabled?: boolean;
|
|
19153
|
+
teams?: StringId | StringId[];
|
|
19154
|
+
from_updatedAt?: number;
|
|
19155
|
+
to_updatedAt?: number;
|
|
19156
|
+
from_createdAt?: number;
|
|
19157
|
+
to_createdAt?: number;
|
|
19158
|
+
};
|
|
19159
|
+
export interface Result extends DefaultPaginationResult {
|
|
19160
|
+
data: PopulatedDoc[];
|
|
19161
|
+
}
|
|
19162
|
+
}
|
|
19163
|
+
export namespace Get {
|
|
19164
|
+
export type ID = string;
|
|
19165
|
+
export type Params = { populatedKeys?: PopulatedKeys[] };
|
|
19166
|
+
export type Result = PopulatedDoc;
|
|
19167
|
+
}
|
|
19168
|
+
export namespace Create {
|
|
19169
|
+
export type Body = CreateBody;
|
|
19170
|
+
export type Result = Data;
|
|
19171
|
+
}
|
|
19172
|
+
export namespace Update {
|
|
19173
|
+
export type ID = StringId;
|
|
19174
|
+
export type Body = UpdateBody;
|
|
19175
|
+
export type Result = Data;
|
|
19176
|
+
}
|
|
19177
|
+
export namespace Remove {
|
|
19178
|
+
export type ID = string;
|
|
19179
|
+
export type Result = Data;
|
|
19180
|
+
}
|
|
19181
|
+
}
|
|
19182
|
+
|
|
19183
|
+
export namespace CLMSequence {
|
|
19184
|
+
export interface Data {
|
|
19185
|
+
_id: StringId;
|
|
19186
|
+
company_namespace: string[];
|
|
19187
|
+
presentation: StringId;
|
|
19188
|
+
product: StringId;
|
|
19189
|
+
disabled: boolean;
|
|
19190
|
+
position: number;
|
|
19191
|
+
createdAt: string;
|
|
19192
|
+
updatedAt: string;
|
|
19193
|
+
__v?: number;
|
|
19194
|
+
}
|
|
19195
|
+
export interface CreateBody {
|
|
19196
|
+
company_namespace?: string[];
|
|
19197
|
+
presentation: StringId;
|
|
19198
|
+
product: StringId;
|
|
19199
|
+
disabled?: boolean;
|
|
19200
|
+
position: number;
|
|
19201
|
+
}
|
|
19202
|
+
export type UpdateBody = Partial<Data>;
|
|
19203
|
+
|
|
19204
|
+
export type PopulatedDoc = Data & {
|
|
19205
|
+
presentation_populated?: Pick<CLMPresentation.Data, "name" | "_id">[];
|
|
19206
|
+
product_populated?: Pick<
|
|
19207
|
+
Product.Data,
|
|
19208
|
+
"name" | "_id" | "local_name" | "barcode" | "sku"
|
|
19209
|
+
>[];
|
|
19210
|
+
};
|
|
19211
|
+
|
|
19212
|
+
type PopulatedKeys = "presentation" | "product";
|
|
19213
|
+
type SortingKeys = "_id" | "position";
|
|
19214
|
+
|
|
19215
|
+
export namespace Find {
|
|
19216
|
+
export type Params = DefaultPaginationQueryParams & {
|
|
19217
|
+
sortBy?: { field: SortingKeys; type: "asc" | "desc" }[];
|
|
19218
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
19219
|
+
_id?: StringId | StringId[];
|
|
19220
|
+
search?: string;
|
|
19221
|
+
product?: StringId | StringId[];
|
|
19222
|
+
presentation?: StringId | StringId[];
|
|
19223
|
+
disabled?: boolean;
|
|
19224
|
+
from_updatedAt?: number;
|
|
19225
|
+
to_updatedAt?: number;
|
|
19226
|
+
from_createdAt?: number;
|
|
19227
|
+
to_createdAt?: number;
|
|
19228
|
+
};
|
|
19229
|
+
export interface Result extends DefaultPaginationResult {
|
|
19230
|
+
data: PopulatedDoc[];
|
|
19231
|
+
}
|
|
19232
|
+
}
|
|
19233
|
+
export namespace Get {
|
|
19234
|
+
export type ID = string;
|
|
19235
|
+
export type Params = { populatedKeys?: PopulatedKeys[] };
|
|
19236
|
+
export type Result = PopulatedDoc;
|
|
19237
|
+
}
|
|
19238
|
+
export namespace Create {
|
|
19239
|
+
export type Body = CreateBody;
|
|
19240
|
+
export type Result = Data;
|
|
19241
|
+
}
|
|
19242
|
+
export namespace Update {
|
|
19243
|
+
export type ID = StringId;
|
|
19244
|
+
export type Body = UpdateBody;
|
|
19245
|
+
export type Result = Data;
|
|
19246
|
+
}
|
|
19247
|
+
export namespace Remove {
|
|
19248
|
+
export type ID = string;
|
|
19249
|
+
export type Result = Data;
|
|
19250
|
+
}
|
|
19251
|
+
}
|
|
19252
|
+
|
|
19253
|
+
export namespace CLMSlide {
|
|
19254
|
+
export interface Data {
|
|
19255
|
+
_id: StringId;
|
|
19256
|
+
company_namespace: string[];
|
|
19257
|
+
sequence: StringId;
|
|
19258
|
+
photo_media: StringId;
|
|
19259
|
+
is_book_mark?: boolean;
|
|
19260
|
+
book_mark_key_message?: string;
|
|
19261
|
+
disabled: boolean;
|
|
19262
|
+
position: number;
|
|
19263
|
+
createdAt: string;
|
|
19264
|
+
updatedAt: string;
|
|
19265
|
+
__v?: number;
|
|
19266
|
+
}
|
|
19267
|
+
export interface CreateBody {
|
|
19268
|
+
company_namespace?: string[];
|
|
19269
|
+
sequence: StringId;
|
|
19270
|
+
photo_media: StringId;
|
|
19271
|
+
is_book_mark?: boolean;
|
|
19272
|
+
book_mark_key_message?: string;
|
|
19273
|
+
disabled?: boolean;
|
|
19274
|
+
position: number;
|
|
19275
|
+
}
|
|
19276
|
+
export type UpdateBody = Partial<Data>;
|
|
19277
|
+
|
|
19278
|
+
export type PopulatedDoc = Data & {
|
|
19279
|
+
sequence_populated?: Pick<
|
|
19280
|
+
CLMSequence.Data,
|
|
19281
|
+
"position" | "_id" | "product" | "presentation"
|
|
19282
|
+
>[];
|
|
19283
|
+
photo_media_populated?: PopulatedMediaStorage;
|
|
19284
|
+
};
|
|
19285
|
+
|
|
19286
|
+
type PopulatedKeys = "sequence" | "photo_media";
|
|
19287
|
+
type SortingKeys = "_id" | "position" | "is_book_mark";
|
|
19288
|
+
|
|
19289
|
+
export namespace Find {
|
|
19290
|
+
export type Params = DefaultPaginationQueryParams & {
|
|
19291
|
+
sortBy?: { field: SortingKeys; type: "asc" | "desc" }[];
|
|
19292
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
19293
|
+
_id?: StringId | StringId[];
|
|
19294
|
+
search?: string;
|
|
19295
|
+
sequence?: StringId | StringId[];
|
|
19296
|
+
is_book_mark?: boolean | boolean[];
|
|
19297
|
+
disabled?: boolean;
|
|
19298
|
+
from_updatedAt?: number;
|
|
19299
|
+
to_updatedAt?: number;
|
|
19300
|
+
from_createdAt?: number;
|
|
19301
|
+
to_createdAt?: number;
|
|
19302
|
+
};
|
|
19303
|
+
export interface Result extends DefaultPaginationResult {
|
|
19304
|
+
data: PopulatedDoc[];
|
|
19305
|
+
}
|
|
19306
|
+
}
|
|
19307
|
+
export namespace Get {
|
|
19308
|
+
export type ID = string;
|
|
19309
|
+
export type Params = { populatedKeys?: PopulatedKeys[] };
|
|
19310
|
+
export type Result = PopulatedDoc;
|
|
19311
|
+
}
|
|
19312
|
+
export namespace Create {
|
|
19313
|
+
export type Body = CreateBody;
|
|
19314
|
+
export type Result = Data;
|
|
19315
|
+
}
|
|
19316
|
+
export namespace Update {
|
|
19317
|
+
export type ID = StringId;
|
|
19318
|
+
export type Body = UpdateBody;
|
|
19319
|
+
export type Result = Data;
|
|
19320
|
+
}
|
|
19321
|
+
export namespace Remove {
|
|
19322
|
+
export type ID = string;
|
|
19323
|
+
export type Result = Data;
|
|
19324
|
+
}
|
|
19325
|
+
}
|
|
19326
|
+
|
|
19327
|
+
export namespace CLMFeedbackActivity {
|
|
19328
|
+
export interface Data {
|
|
19329
|
+
_id: StringId;
|
|
19330
|
+
geo_tag: GeoTag;
|
|
19331
|
+
geoPoint?: GeoPoint;
|
|
19332
|
+
time: number;
|
|
19333
|
+
tags?: StringId[];
|
|
19334
|
+
visit_id: string;
|
|
19335
|
+
visit?: StringId;
|
|
19336
|
+
creator: { _id: StringId; type: "rep"; name?: string; rep?: StringId };
|
|
19337
|
+
client: StringId;
|
|
19338
|
+
client_name: string;
|
|
19339
|
+
sync_id: string;
|
|
19340
|
+
teams?: StringId[];
|
|
19341
|
+
route?: StringId;
|
|
19342
|
+
platform?: string;
|
|
19343
|
+
version_name?: string;
|
|
19344
|
+
battery_level?: number;
|
|
19345
|
+
device_brand?: string;
|
|
19346
|
+
device_os?: string;
|
|
19347
|
+
device_os_version?: string;
|
|
19348
|
+
device_model?: string;
|
|
19349
|
+
time_zone?: string;
|
|
19350
|
+
identifier?: number;
|
|
19351
|
+
device_id?: string;
|
|
19352
|
+
device_unique_id?: string;
|
|
19353
|
+
network_state?: number;
|
|
19354
|
+
job_start_time?: number;
|
|
19355
|
+
job_end_time?: number;
|
|
19356
|
+
job_duration?: number;
|
|
19357
|
+
company_namespace: string[];
|
|
19358
|
+
createdAt: string;
|
|
19359
|
+
updatedAt: string;
|
|
19360
|
+
__v?: number;
|
|
19361
|
+
|
|
19362
|
+
completion_status: "ended" | "canceled";
|
|
19363
|
+
presentation: StringId;
|
|
19364
|
+
presentation_name: string;
|
|
19365
|
+
duration_on_presentation_ms: number;
|
|
19366
|
+
result: [
|
|
19367
|
+
{
|
|
19368
|
+
sequence: StringId;
|
|
19369
|
+
sequence_name: string;
|
|
19370
|
+
duration_on_sequence_ms: number;
|
|
19371
|
+
slides: [
|
|
19372
|
+
{
|
|
19373
|
+
slide: StringId;
|
|
19374
|
+
feedback: "positive" | "negative";
|
|
19375
|
+
duration_on_slide_ms: number;
|
|
19376
|
+
},
|
|
19377
|
+
];
|
|
19378
|
+
},
|
|
19379
|
+
];
|
|
19380
|
+
interactions: [
|
|
19381
|
+
{
|
|
19382
|
+
interaction_time: number;
|
|
19383
|
+
interaction_type:
|
|
19384
|
+
| "slide_landing"
|
|
19385
|
+
| "slide_leaving"
|
|
19386
|
+
| "zoom"
|
|
19387
|
+
| "feedback_given"
|
|
19388
|
+
| "presentation_play"
|
|
19389
|
+
| "presentation_end"
|
|
19390
|
+
| "presentation_cancel";
|
|
19391
|
+
interaction_detail: "in" | "out" | "positive" | "negative" | null; // required for zoom and feedback_given, null for other
|
|
19392
|
+
slide?: StringId; // optional for presentation_play, presentation_end, presentation_cancel, required for other
|
|
19393
|
+
sequence?: StringId; // optional for presentation_play, presentation_end, presentation_cancel, required for other
|
|
19394
|
+
},
|
|
19395
|
+
];
|
|
19396
|
+
}
|
|
19397
|
+
export interface CreateBody {
|
|
19398
|
+
geo_tag: GeoTag;
|
|
19399
|
+
geoPoint?: GeoPoint; // ????
|
|
19400
|
+
time: number;
|
|
19401
|
+
tags?: StringId[];
|
|
19402
|
+
visit_id: string;
|
|
19403
|
+
creator?: { _id: StringId; type: "rep"; name?: string; rep?: StringId };
|
|
19404
|
+
client: StringId;
|
|
19405
|
+
client_name: string;
|
|
19406
|
+
sync_id: string;
|
|
19407
|
+
teams?: StringId[];
|
|
19408
|
+
route?: StringId;
|
|
19409
|
+
platform?: string;
|
|
19410
|
+
version_name?: string;
|
|
19411
|
+
battery_level?: number;
|
|
19412
|
+
device_brand?: string;
|
|
19413
|
+
device_os?: string;
|
|
19414
|
+
device_os_version?: string;
|
|
19415
|
+
device_model?: string;
|
|
19416
|
+
time_zone?: string;
|
|
19417
|
+
identifier?: number;
|
|
19418
|
+
device_id?: string;
|
|
19419
|
+
device_unique_id?: string;
|
|
19420
|
+
network_state?: number;
|
|
19421
|
+
job_start_time?: number;
|
|
19422
|
+
job_end_time?: number;
|
|
19423
|
+
job_duration?: number;
|
|
19424
|
+
company_namespace?: string[];
|
|
19425
|
+
|
|
19426
|
+
completion_status: "ended" | "canceled";
|
|
19427
|
+
presentation: StringId;
|
|
19428
|
+
presentation_name: string;
|
|
19429
|
+
duration_on_presentation_ms: number;
|
|
19430
|
+
result?: [
|
|
19431
|
+
{
|
|
19432
|
+
sequence: StringId;
|
|
19433
|
+
sequence_name: string;
|
|
19434
|
+
duration_on_sequence_ms: number;
|
|
19435
|
+
slides: [
|
|
19436
|
+
{
|
|
19437
|
+
slide: StringId;
|
|
19438
|
+
feedback: "positive" | "negative";
|
|
19439
|
+
duration_on_slide_ms: number;
|
|
19440
|
+
},
|
|
19441
|
+
];
|
|
19442
|
+
},
|
|
19443
|
+
];
|
|
19444
|
+
interactions: [
|
|
19445
|
+
{
|
|
19446
|
+
interaction_time: number;
|
|
19447
|
+
interaction_type:
|
|
19448
|
+
| "slide_landing"
|
|
19449
|
+
| "slide_leaving"
|
|
19450
|
+
| "zoom"
|
|
19451
|
+
| "feedback_given"
|
|
19452
|
+
| "presentation_play"
|
|
19453
|
+
| "presentation_end"
|
|
19454
|
+
| "presentation_cancel";
|
|
19455
|
+
interaction_detail: "in" | "out" | "positive" | "negative" | null; // required for zoom and feedback_given, null for other
|
|
19456
|
+
slide?: StringId; // optional for presentation_play, presentation_end, presentation_cancel, required for other
|
|
19457
|
+
sequence?: StringId; // optional for presentation_play, presentation_end, presentation_cancel, required for other
|
|
19458
|
+
},
|
|
19459
|
+
];
|
|
19460
|
+
}
|
|
19461
|
+
|
|
19462
|
+
export type PopulatedDoc = Data & {
|
|
19463
|
+
client_populated?: Pick<
|
|
19464
|
+
Client.Data,
|
|
19465
|
+
"_id" | "name" | "local_name" | "client_code"
|
|
19466
|
+
>[];
|
|
19467
|
+
visit_populated?: Visit.Data;
|
|
19468
|
+
route_populated?: Pick<Route.Data, "_id" | "name">;
|
|
19469
|
+
teams_populated?: Pick<Team.TeamSchema, "name" | "_id">[];
|
|
19470
|
+
tags_populated?: Pick<Tag.Data, "_id" | "tag" | "type">[];
|
|
19471
|
+
presentation_populated?: Pick<CLMPresentation.Data, "name" | "_id">;
|
|
19472
|
+
};
|
|
19473
|
+
|
|
19474
|
+
type PopulatedKeys =
|
|
19475
|
+
| "client"
|
|
19476
|
+
| "visit"
|
|
19477
|
+
| "route"
|
|
19478
|
+
| "teams"
|
|
19479
|
+
| "tags"
|
|
19480
|
+
| "presentation";
|
|
19481
|
+
|
|
19482
|
+
export namespace Find {
|
|
19483
|
+
export type Params = DefaultPaginationQueryParams & {
|
|
19484
|
+
populatedKeys?: PopulatedKeys | PopulatedKeys[];
|
|
19485
|
+
from_time?: number;
|
|
19486
|
+
to_time?: number;
|
|
19487
|
+
_id?: StringId | StringId[];
|
|
19488
|
+
presentation?: StringId | StringId[];
|
|
19489
|
+
client?: StringId | StringId[];
|
|
19490
|
+
tags?: StringId | StringId[];
|
|
19491
|
+
CLIENT_TAGS?: StringId | StringId[];
|
|
19492
|
+
AREA_TAGS?: StringId | StringId[];
|
|
19493
|
+
teams?: StringId | StringId[];
|
|
19494
|
+
route?: StringId | StringId[];
|
|
19495
|
+
creator?: StringId | StringId[];
|
|
19496
|
+
creator_id?: StringId | StringId[];
|
|
19497
|
+
creator_type?: StringId | StringId[];
|
|
19498
|
+
"creator._id"?: StringId | StringId[];
|
|
19499
|
+
"creator.type"?: StringId | StringId[];
|
|
19500
|
+
visit_id?: string | string[];
|
|
19501
|
+
visit?: StringId | StringId[];
|
|
19502
|
+
sync_id?: string | string[];
|
|
19503
|
+
};
|
|
19504
|
+
export interface Result extends DefaultPaginationResult {
|
|
19505
|
+
data: PopulatedDoc[];
|
|
19506
|
+
}
|
|
19507
|
+
}
|
|
19508
|
+
export namespace Get {
|
|
19509
|
+
export type ID = string;
|
|
19510
|
+
export type Params = { populatedKeys?: PopulatedKeys[] };
|
|
19511
|
+
export type Result = PopulatedDoc;
|
|
19512
|
+
}
|
|
19513
|
+
export namespace Create {
|
|
19514
|
+
export type Body = CreateBody;
|
|
19515
|
+
export type Result = Data;
|
|
19516
|
+
}
|
|
19517
|
+
}
|
|
19110
19518
|
}
|
|
19111
19519
|
|
|
19112
19520
|
export type StringId = string;
|