repzo 1.0.247 → 1.0.249

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.
@@ -2448,6 +2448,7 @@ export declare namespace Service {
2448
2448
  rep_must_add_delivery_date_on_invoice?: boolean;
2449
2449
  rep_can_view_stock_on_transfers?: boolean;
2450
2450
  rep_must_invoice_items_from_cross_inventory_and_msl?: boolean;
2451
+ rep_can_create_client_line_approval_request?: boolean;
2451
2452
  }
2452
2453
  interface TargetResults {
2453
2454
  totalPoints: number;
@@ -2706,6 +2707,7 @@ export declare namespace Service {
2706
2707
  "permissions.rep_can_access_sales_reports"?: boolean;
2707
2708
  "permissions.rep_must_add_delivery_date_on_sales_order"?: boolean;
2708
2709
  "permissions.rep_must_add_delivery_date_on_invoice"?: boolean;
2710
+ "permissions.rep_can_create_client_line_approval_request"?: boolean;
2709
2711
  "permissions.rep_can_view_stock_on_transfers"?: boolean;
2710
2712
  "permissions.rep_must_invoice_items_from_cross_inventory_and_msl"?: boolean;
2711
2713
  "settings.rep_must_end_day_after"?: `${number}:${number}`;
@@ -4970,11 +4972,7 @@ export declare namespace Service {
4970
4972
  score?: number;
4971
4973
  is_completed?: boolean;
4972
4974
  forms_v2?: {
4973
- form_id: StringId | {
4974
- _id: StringId;
4975
- name: string;
4976
- local_name?: string;
4977
- };
4975
+ form_id: StringId | Pick<FormV2.Data, "_id" | "name" | "local_name">;
4978
4976
  form_activity_id?: StringId;
4979
4977
  completion_required_for_dunning?: boolean;
4980
4978
  score_required_for_dunning?: boolean;
@@ -12461,11 +12459,11 @@ export declare namespace Service {
12461
12459
  _id: StringId;
12462
12460
  app_code: string;
12463
12461
  document_id?: StringId;
12464
- document_type: "client" | "visit";
12462
+ document_type: "client" | "visit" | "client-line";
12465
12463
  sync_id: string;
12466
12464
  method?: "create" | "update" | "delete" | "patch";
12467
12465
  visit_id?: string;
12468
- type: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client";
12466
+ type: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client" | "update_client_line";
12469
12467
  subtype?: "client_details" | "client_assigned_to" | "client_location" | "client_credit_limit";
12470
12468
  implementation_type: "create_doc" | "update_doc" | "delete_doc" | "no_implementation";
12471
12469
  creator: AdminOrRepOrTenant;
@@ -12531,11 +12529,11 @@ export declare namespace Service {
12531
12529
  };
12532
12530
  export interface CreateBody {
12533
12531
  document_id?: StringId;
12534
- document_type: "client" | "visit";
12532
+ document_type: "client" | "visit" | "client-line";
12535
12533
  sync_id: string;
12536
12534
  method?: "create" | "update" | "delete" | "patch";
12537
12535
  visit_id?: string;
12538
- type: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client";
12536
+ type: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client" | "update_client_line";
12539
12537
  subtype?: "client_details" | "client_assigned_to" | "client_location" | "client_credit_limit";
12540
12538
  implementation_type: "create_doc" | "update_doc" | "delete_doc" | "no_implementation";
12541
12539
  creator?: AdminOrRepOrTenant;
@@ -12591,11 +12589,11 @@ export declare namespace Service {
12591
12589
  _id?: StringId;
12592
12590
  app_code?: string;
12593
12591
  document_id?: StringId;
12594
- document_type?: "client" | "visit";
12592
+ document_type?: "client" | "visit" | "client-line";
12595
12593
  sync_id?: string;
12596
12594
  method?: "create" | "update" | "delete" | "patch";
12597
12595
  visit_id?: string;
12598
- type?: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client";
12596
+ type?: "skip_job_at_visit_end" | "end_visit_out_of_geofence" | "skip_visit_from_route" | "create_client" | "update_client" | "delete_client" | "update_client_line";
12599
12597
  subtype?: "client_details" | "client_assigned_to" | "client_location" | "client_credit_limit";
12600
12598
  implementation_type?: "create_doc" | "update_doc" | "delete_doc" | "no_implementation";
12601
12599
  creator?: AdminOrRepOrTenant;
@@ -14203,235 +14201,6 @@ export declare namespace Service {
14203
14201
  current_granularity?: Granularity;
14204
14202
  }
14205
14203
  }
14206
- namespace FormV2 {
14207
- export interface Visibility {
14208
- operator: "and" | "or";
14209
- conditions: {
14210
- division_id: string;
14211
- field_id: string;
14212
- type: "Boolean" | "List" | "YesNo";
14213
- custom_list?: string | CustomList.Data;
14214
- operator: "lte" | "lt" | "gte" | "gt" | "eq" | "ne" | "in" | "nin";
14215
- value: any[];
14216
- }[];
14217
- }
14218
- export const fieldType_enums: readonly ["Text", "String", "Phone", "Email", "Date", "Number", "List", "Separator", "Heading", "Media", "Signature", "DateTime", "YesNo", "ProductBarcodeScan", "BarcodeScan", "GeoPoint"];
14219
- export type FormV2FieldType = (typeof fieldType_enums)[number];
14220
- interface FieldPrintSettings {
14221
- three_inch: {
14222
- grid_column?: 1 | 2;
14223
- alignment?: "right" | "left" | "center";
14224
- border_width?: number;
14225
- label_font_size?: number;
14226
- value_font_size?: number;
14227
- media_height?: number | string;
14228
- media_width?: number | string;
14229
- align_media?: "right" | "left" | "center";
14230
- label_value_spacing?: number;
14231
- is_hidden?: boolean;
14232
- };
14233
- }
14234
- interface UsedField {
14235
- code: string;
14236
- key: string;
14237
- data_type: AvailableField.Data["data_type"];
14238
- field_type: "template_field" | "source_attribute" | "activity_attribute";
14239
- label: string;
14240
- isArray?: boolean;
14241
- formula_key: string;
14242
- field_id?: string;
14243
- example_value: AvailableField.Data["data_type"];
14244
- manipulator_function?: string;
14245
- lookup?: {
14246
- from?: string;
14247
- localField?: string;
14248
- foreignField?: string;
14249
- as?: string;
14250
- select?: string;
14251
- unwind?: boolean;
14252
- filter?: {
14253
- input?: string;
14254
- as: string;
14255
- cond: any;
14256
- };
14257
- };
14258
- }
14259
- export interface Field {
14260
- _id?: string;
14261
- name: string;
14262
- local_name?: string;
14263
- description?: string;
14264
- local_description?: string;
14265
- type: FormV2FieldType;
14266
- isArray?: boolean;
14267
- isRequired?: boolean;
14268
- disabled?: boolean;
14269
- formula_key?: string;
14270
- scoring_enabled?: boolean;
14271
- required_for_completion?: boolean;
14272
- visibility?: Visibility;
14273
- default_value?: any[];
14274
- custom_list?: string | CustomList.Data;
14275
- is_na_allowed?: boolean;
14276
- score_accumulator_type?: "max" | "sum";
14277
- yes_score?: number;
14278
- no_score?: number;
14279
- na_score?: number;
14280
- exist_score?: number;
14281
- media?: (string | MediaDoc)[];
14282
- invisible: boolean;
14283
- parent_field?: string;
14284
- custom_list_element?: string;
14285
- force_live_photo?: boolean;
14286
- min?: number;
14287
- max?: number;
14288
- is_integer?: boolean;
14289
- styles?: "check_list" | "toggle_yes_no_na" | "toggle_yes_no" | "buttons";
14290
- field_print_settings?: FieldPrintSettings;
14291
- is_calculated_field?: boolean;
14292
- formula?: string;
14293
- used_fields?: UsedField[];
14294
- }
14295
- interface Division {
14296
- _id: string;
14297
- name: string;
14298
- local_name?: string;
14299
- description?: string;
14300
- local_description?: string;
14301
- disabled?: boolean;
14302
- min_questions_to_answer_for_completion?: number;
14303
- min_score_for_completion?: number;
14304
- visibility?: Visibility;
14305
- fields: Field[];
14306
- }
14307
- interface PrintSettings {
14308
- three_inch: {
14309
- grid_columns?: 1 | 2;
14310
- logo_height?: number | string;
14311
- logo_width?: number | string;
14312
- align_logo?: "right" | "left" | "center";
14313
- space_y?: number;
14314
- };
14315
- A_four: {
14316
- banner_media?: string;
14317
- banner_height: number;
14318
- banner_width: number;
14319
- align_banner: "right" | "left" | "center";
14320
- header_label_font_size: number;
14321
- header_value_font_size: number;
14322
- align_header: "right" | "left" | "center";
14323
- division_name_font_size: number;
14324
- align_division: "right" | "left" | "center";
14325
- grid_columns: 1 | 2 | 3 | 4;
14326
- space_y: number;
14327
- field_label_size: number;
14328
- field_value_size: number;
14329
- footer_media?: string;
14330
- align_footer_media: "right" | "left" | "center";
14331
- footer_media_height: number;
14332
- footer_media_width: number;
14333
- footer_details: string;
14334
- align_footer_details: "right" | "left" | "center";
14335
- compressed_media_size: "original" | "small" | "medium" | "large" | "extra";
14336
- view_custom_list_element: boolean;
14337
- };
14338
- }
14339
- export interface Data {
14340
- _id: string;
14341
- disabled: boolean;
14342
- name: string;
14343
- local_name?: string;
14344
- description?: string;
14345
- local_description?: string;
14346
- copied_from?: string;
14347
- scoring_enabled?: boolean;
14348
- completion_rules_enabled?: boolean;
14349
- min_questions_to_answer_for_completion?: number;
14350
- min_score_for_completion?: number;
14351
- divisions: Division[];
14352
- company_namespace: string[];
14353
- print_settings?: PrintSettings;
14354
- createdAt: Date;
14355
- updatedAt: Date;
14356
- }
14357
- export {};
14358
- }
14359
- namespace ActivityFormV2Result {
14360
- const fieldType_enums: readonly ["Text", "String", "Phone", "Email", "Date", "Number", "List", "Separator", "Heading", "Media", "Signature", "DateTime", "YesNo", "ProductBarcodeScan", "BarcodeScan", "GeoPoint"];
14361
- type FormV2FieldType = (typeof fieldType_enums)[number];
14362
- interface FieldResult {
14363
- _id?: string;
14364
- field_id: string;
14365
- name: string;
14366
- type: FormV2FieldType;
14367
- isArray?: boolean;
14368
- isRequired?: boolean;
14369
- custom_list?: string;
14370
- formula_key?: string;
14371
- is_calculated_field?: boolean;
14372
- calculation_status?: "success" | "failed";
14373
- calculation_error?: any[];
14374
- score?: number;
14375
- is_completed?: boolean;
14376
- result: string[] | number[] | ["yes"] | ["no"] | ["na"] | [] | {
14377
- coordinates: [number, number];
14378
- type: "Point";
14379
- }[] | {
14380
- _id: string;
14381
- value: string | number;
14382
- type: "Number" | "String";
14383
- score?: number;
14384
- }[];
14385
- }
14386
- interface DivisionResult {
14387
- _id: string;
14388
- division_id: string;
14389
- name: string;
14390
- score?: number;
14391
- is_completed?: boolean;
14392
- fields: FieldResult[];
14393
- }
14394
- interface Data {
14395
- _id: string;
14396
- creator: AdminOrRepOrTenantOrClient;
14397
- editor?: AdminOrRepOrTenantOrClient;
14398
- serial_number: SerialNumber;
14399
- teams: string[];
14400
- tags: string[];
14401
- time: number;
14402
- client?: string;
14403
- client_name?: string;
14404
- visit?: string;
14405
- visit_id?: string;
14406
- route?: string;
14407
- workorder?: string;
14408
- sync_id: string;
14409
- geo_tag?: GeoTag;
14410
- geoPoint?: GeoPoint;
14411
- platform?: string;
14412
- version_name?: string;
14413
- battery_level?: number;
14414
- device_brand?: string;
14415
- device_os?: string;
14416
- device_os_version?: string;
14417
- device_model?: string;
14418
- identifier?: number;
14419
- device_id?: string;
14420
- device_unique_id?: string;
14421
- network_state?: number;
14422
- time_zone?: string;
14423
- job_start_time?: number;
14424
- job_end_time?: number;
14425
- job_duration?: number;
14426
- form_id: string;
14427
- results: DivisionResult[];
14428
- score?: number;
14429
- is_completed: boolean;
14430
- company_namespace: string[];
14431
- createdAt: Date;
14432
- updatedAt: Date;
14433
- }
14434
- }
14435
14204
  namespace ActivityItemStatus {
14436
14205
  type ItemStatus = "current_user" | "non_user" | "generic_user" | "competitor_user" | "other";
14437
14206
  interface Item {
@@ -17722,6 +17491,393 @@ export declare namespace Service {
17722
17491
  type Result = Data;
17723
17492
  }
17724
17493
  }
17494
+ namespace FormV2 {
17495
+ export interface Visibility {
17496
+ operator: "and" | "or";
17497
+ conditions: {
17498
+ division_id: string;
17499
+ field_id: string;
17500
+ type: "Boolean" | "List" | "YesNo";
17501
+ custom_list?: string | CustomList.Data;
17502
+ operator: "lte" | "lt" | "gte" | "gt" | "eq" | "ne" | "in" | "nin";
17503
+ value: any[];
17504
+ }[];
17505
+ }
17506
+ export const fieldType_enums: readonly ["Text", "String", "Phone", "Email", "Date", "Number", "List", "Separator", "Heading", "Media", "Signature", "DateTime", "YesNo", "ProductBarcodeScan", "BarcodeScan", "GeoPoint"];
17507
+ export type FormV2FieldType = (typeof fieldType_enums)[number];
17508
+ interface FieldPrintSettings {
17509
+ three_inch: {
17510
+ grid_column?: 1 | 2;
17511
+ alignment?: "right" | "left" | "center";
17512
+ border_width?: number;
17513
+ label_font_size?: number;
17514
+ value_font_size?: number;
17515
+ media_height?: number | string;
17516
+ media_width?: number | string;
17517
+ align_media?: "right" | "left" | "center";
17518
+ label_value_spacing?: number;
17519
+ is_hidden?: boolean;
17520
+ };
17521
+ }
17522
+ interface UsedField {
17523
+ code: string;
17524
+ key: string;
17525
+ data_type: AvailableField.Data["data_type"];
17526
+ field_type: "template_field" | "source_attribute" | "activity_attribute";
17527
+ label: string;
17528
+ isArray?: boolean;
17529
+ formula_key: string;
17530
+ field_id?: string;
17531
+ example_value: AvailableField.Data["data_type"];
17532
+ manipulator_function?: string;
17533
+ lookup?: {
17534
+ from?: string;
17535
+ localField?: string;
17536
+ foreignField?: string;
17537
+ as?: string;
17538
+ select?: string;
17539
+ unwind?: boolean;
17540
+ filter?: {
17541
+ input?: string;
17542
+ as: string;
17543
+ cond: any;
17544
+ };
17545
+ };
17546
+ }
17547
+ export interface Field {
17548
+ _id?: string;
17549
+ name: string;
17550
+ local_name?: string;
17551
+ description?: string;
17552
+ local_description?: string;
17553
+ type: FormV2FieldType;
17554
+ isArray?: boolean;
17555
+ isRequired?: boolean;
17556
+ disabled?: boolean;
17557
+ formula_key?: string;
17558
+ scoring_enabled?: boolean;
17559
+ required_for_completion?: boolean;
17560
+ visibility?: Visibility;
17561
+ default_value?: any[];
17562
+ custom_list?: string | CustomList.Data;
17563
+ is_na_allowed?: boolean;
17564
+ score_accumulator_type?: "max" | "sum";
17565
+ yes_score?: number;
17566
+ no_score?: number;
17567
+ na_score?: number;
17568
+ exist_score?: number;
17569
+ media?: (string | MediaDoc)[];
17570
+ invisible: boolean;
17571
+ parent_field?: string;
17572
+ custom_list_element?: string;
17573
+ force_live_photo?: boolean;
17574
+ min?: number;
17575
+ max?: number;
17576
+ is_integer?: boolean;
17577
+ styles?: "check_list" | "toggle_yes_no_na" | "toggle_yes_no" | "buttons";
17578
+ field_print_settings?: FieldPrintSettings;
17579
+ is_calculated_field?: boolean;
17580
+ formula?: string;
17581
+ used_fields?: UsedField[];
17582
+ }
17583
+ interface Division {
17584
+ _id: string;
17585
+ name: string;
17586
+ local_name?: string;
17587
+ description?: string;
17588
+ local_description?: string;
17589
+ disabled?: boolean;
17590
+ min_questions_to_answer_for_completion?: number;
17591
+ min_score_for_completion?: number;
17592
+ visibility?: Visibility;
17593
+ fields: Field[];
17594
+ }
17595
+ interface PrintSettings {
17596
+ three_inch: {
17597
+ grid_columns?: 1 | 2;
17598
+ logo_height?: number | string;
17599
+ logo_width?: number | string;
17600
+ align_logo?: "right" | "left" | "center";
17601
+ space_y?: number;
17602
+ };
17603
+ A_four: {
17604
+ banner_media?: string | MediaDoc;
17605
+ banner_height: number;
17606
+ banner_width: number;
17607
+ align_banner: "right" | "left" | "center";
17608
+ header_label_font_size: number;
17609
+ header_value_font_size: number;
17610
+ align_header: "right" | "left" | "center";
17611
+ division_name_font_size: number;
17612
+ align_division: "right" | "left" | "center";
17613
+ grid_columns: 1 | 2 | 3 | 4;
17614
+ space_y: number;
17615
+ field_label_size: number;
17616
+ field_value_size: number;
17617
+ footer_media?: string | MediaDoc;
17618
+ align_footer_media: "right" | "left" | "center";
17619
+ footer_media_height: number;
17620
+ footer_media_width: number;
17621
+ footer_details: string;
17622
+ align_footer_details: "right" | "left" | "center";
17623
+ compressed_media_size: "original" | "small" | "medium" | "large" | "extra";
17624
+ view_custom_list_element: boolean;
17625
+ };
17626
+ }
17627
+ export interface Data {
17628
+ _id: string;
17629
+ disabled: boolean;
17630
+ name: string;
17631
+ local_name?: string;
17632
+ description?: string;
17633
+ local_description?: string;
17634
+ copied_from?: string;
17635
+ scoring_enabled?: boolean;
17636
+ completion_rules_enabled?: boolean;
17637
+ min_questions_to_answer_for_completion?: number;
17638
+ min_score_for_completion?: number;
17639
+ divisions: Division[];
17640
+ company_namespace: string[];
17641
+ print_settings?: PrintSettings;
17642
+ createdAt: Date;
17643
+ updatedAt: Date;
17644
+ }
17645
+ export interface CreateBody {
17646
+ disabled?: boolean;
17647
+ name: string;
17648
+ local_name?: string;
17649
+ description?: string;
17650
+ local_description?: string;
17651
+ copied_from?: string;
17652
+ scoring_enabled?: boolean;
17653
+ completion_rules_enabled?: boolean;
17654
+ min_questions_to_answer_for_completion?: number;
17655
+ min_score_for_completion?: number;
17656
+ divisions: Division[];
17657
+ company_namespace?: string[];
17658
+ print_settings?: PrintSettings;
17659
+ }
17660
+ export type UpdateBody = Partial<Data>;
17661
+ export type PopulatedDoc = Data & {
17662
+ presentation_populated?: CLMPresentation.Data;
17663
+ sequence_populated?: Pick<CLMSequence.Data, "position" | "_id" | "product" | "presentation">[];
17664
+ photo_media_populated?: PopulatedMediaStorage & {
17665
+ ContentLength?: number;
17666
+ };
17667
+ };
17668
+ type PopulatedKeys = "custom_list" | "media" | "banner_media" | "footer_media";
17669
+ type SortingKeys = "_id" | "position" | "updatedAt";
17670
+ export namespace Find {
17671
+ type Params = DefaultPaginationQueryParams & {
17672
+ sortBy?: {
17673
+ field: SortingKeys;
17674
+ type: "asc" | "desc";
17675
+ }[];
17676
+ populatedKeys?: PopulatedKeys | PopulatedKeys[];
17677
+ _id?: StringId | StringId[];
17678
+ search?: string;
17679
+ name?: string;
17680
+ scoring_enabled?: boolean | boolean[];
17681
+ completion_rules_enabled?: boolean | boolean[];
17682
+ disabled?: boolean;
17683
+ };
17684
+ interface Result extends DefaultPaginationResult {
17685
+ data: PopulatedDoc[];
17686
+ }
17687
+ }
17688
+ export namespace Get {
17689
+ type ID = string;
17690
+ type Params = {
17691
+ populatedKeys?: PopulatedKeys[];
17692
+ };
17693
+ type Result = PopulatedDoc & {
17694
+ can_edit_types?: boolean;
17695
+ };
17696
+ }
17697
+ export namespace Create {
17698
+ type Body = CreateBody;
17699
+ type Result = Data;
17700
+ }
17701
+ export namespace Update {
17702
+ type ID = StringId;
17703
+ type Body = UpdateBody;
17704
+ type Result = Data;
17705
+ }
17706
+ export namespace Remove {
17707
+ type ID = string;
17708
+ type Result = Data;
17709
+ }
17710
+ export {};
17711
+ }
17712
+ namespace ActivityFormV2Result {
17713
+ export const fieldType_enums: readonly ["Text", "String", "Phone", "Email", "Date", "Number", "List", "Separator", "Heading", "Media", "Signature", "DateTime", "YesNo", "ProductBarcodeScan", "BarcodeScan", "GeoPoint"];
17714
+ export type FormV2FieldType = (typeof fieldType_enums)[number];
17715
+ export interface FieldResult {
17716
+ _id?: string;
17717
+ field_id: string;
17718
+ name: string;
17719
+ type: FormV2FieldType;
17720
+ isArray?: boolean;
17721
+ isRequired?: boolean;
17722
+ custom_list?: string;
17723
+ formula_key?: string;
17724
+ is_calculated_field?: boolean;
17725
+ calculation_status?: "success" | "failed";
17726
+ calculation_error?: any[];
17727
+ score?: number;
17728
+ is_completed?: boolean;
17729
+ result: string[] | number[] | ["yes"] | ["no"] | ["na"] | [] | {
17730
+ coordinates: [number, number];
17731
+ type: "Point";
17732
+ }[] | {
17733
+ _id: string;
17734
+ value: string | number;
17735
+ type: "Number" | "String";
17736
+ score?: number;
17737
+ }[];
17738
+ }
17739
+ export interface DivisionResult {
17740
+ _id?: string;
17741
+ division_id: string;
17742
+ name: string;
17743
+ score?: number;
17744
+ is_completed?: boolean;
17745
+ fields: FieldResult[];
17746
+ }
17747
+ export interface Data {
17748
+ _id: StringId;
17749
+ creator: AdminOrRepOrTenantOrClient;
17750
+ editor?: AdminOrRepOrTenantOrClient;
17751
+ serial_number: SerialNumber;
17752
+ teams: StringId[];
17753
+ tags: StringId[];
17754
+ time: number;
17755
+ client?: StringId;
17756
+ client_name?: string;
17757
+ visit?: StringId;
17758
+ visit_id?: string;
17759
+ route?: StringId;
17760
+ workorder?: StringId;
17761
+ sync_id: string;
17762
+ geo_tag?: GeoTag;
17763
+ geoPoint?: GeoPoint;
17764
+ platform?: string;
17765
+ version_name?: string;
17766
+ battery_level?: number;
17767
+ device_brand?: string;
17768
+ device_os?: string;
17769
+ device_os_version?: string;
17770
+ device_model?: string;
17771
+ identifier?: number;
17772
+ device_id?: string;
17773
+ device_unique_id?: string;
17774
+ network_state?: number;
17775
+ time_zone?: string;
17776
+ job_start_time?: number;
17777
+ job_end_time?: number;
17778
+ job_duration?: number;
17779
+ form_id: StringId;
17780
+ results: DivisionResult[];
17781
+ score?: number;
17782
+ is_completed: boolean;
17783
+ company_namespace: string[];
17784
+ createdAt: Date;
17785
+ updatedAt: Date;
17786
+ }
17787
+ export interface CreateBody {
17788
+ creator: AdminOrRepOrTenantOrClient;
17789
+ serial_number?: SerialNumber;
17790
+ teams?: StringId[];
17791
+ tags?: StringId[];
17792
+ time?: number;
17793
+ client?: StringId;
17794
+ client_name?: string;
17795
+ visit?: StringId;
17796
+ visit_id?: string;
17797
+ route?: StringId;
17798
+ workorder?: StringId;
17799
+ sync_id: string;
17800
+ geo_tag?: GeoTag;
17801
+ geoPoint?: GeoPoint;
17802
+ platform?: string;
17803
+ version_name?: string;
17804
+ battery_level?: number;
17805
+ device_brand?: string;
17806
+ device_os?: string;
17807
+ device_os_version?: string;
17808
+ device_model?: string;
17809
+ identifier?: number;
17810
+ device_id?: string;
17811
+ device_unique_id?: string;
17812
+ network_state?: number;
17813
+ time_zone?: string;
17814
+ job_start_time?: number;
17815
+ job_end_time?: number;
17816
+ job_duration?: number;
17817
+ form_id: StringId;
17818
+ results: DivisionResult[];
17819
+ score?: number;
17820
+ is_completed?: boolean;
17821
+ company_namespace?: string[];
17822
+ }
17823
+ export type UpdateBody = Partial<Data>;
17824
+ export type PopulatedDoc = Data & {
17825
+ presentation_populated?: CLMPresentation.Data;
17826
+ sequence_populated?: Pick<CLMSequence.Data, "position" | "_id" | "product" | "presentation">[];
17827
+ photo_media_populated?: PopulatedMediaStorage & {
17828
+ ContentLength?: number;
17829
+ };
17830
+ };
17831
+ type PopulatedKeys = "custom_list" | "client" | "workorder" | "visit" | "route" | "form_id" | "teams" | "tags" | "media";
17832
+ export namespace Find {
17833
+ type Params = DefaultPaginationQueryParams & {
17834
+ populatedKeys?: PopulatedKeys | PopulatedKeys[];
17835
+ _id?: StringId | StringId[];
17836
+ search?: string;
17837
+ from_time?: number;
17838
+ to_time?: number;
17839
+ client?: StringId | StringId[];
17840
+ tags?: StringId | StringId[];
17841
+ CLIENT_TAGS?: StringId | StringId[];
17842
+ AREA_TAGS?: StringId | StringId[];
17843
+ form_id?: StringId | StringId[];
17844
+ teams?: StringId | StringId[];
17845
+ route?: StringId | StringId[];
17846
+ is_completed?: boolean;
17847
+ from_score?: number;
17848
+ to_score?: number;
17849
+ score?: number | number[];
17850
+ "creator._id"?: StringId | StringId[];
17851
+ "creator.type"?: Data["creator"]["type"] | Data["creator"]["type"][];
17852
+ visit_id?: string | string[];
17853
+ visit?: StringId | StringId[];
17854
+ workorder?: StringId | StringId[];
17855
+ "serial_number.formatted"?: string | string[];
17856
+ };
17857
+ interface Result extends DefaultPaginationResult {
17858
+ data: PopulatedDoc[];
17859
+ }
17860
+ }
17861
+ export namespace Get {
17862
+ type ID = string;
17863
+ type Params = {
17864
+ populatedKeys?: PopulatedKeys[];
17865
+ };
17866
+ type Result = PopulatedDoc & {
17867
+ can_edit_types?: boolean;
17868
+ };
17869
+ }
17870
+ export namespace Create {
17871
+ type Body = CreateBody;
17872
+ type Result = Data;
17873
+ }
17874
+ export namespace Update {
17875
+ type ID = StringId;
17876
+ type Body = UpdateBody;
17877
+ type Result = Data;
17878
+ }
17879
+ export {};
17880
+ }
17725
17881
  }
17726
17882
  export type StringId = string;
17727
17883
  export type NameSpaces = string[];