@luminocity/lemonate-gateway 8.2.0 → 8.2.3

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/dist/index.d.ts CHANGED
@@ -6,6 +6,8 @@ import { CustomField as CustomField$1, CustomFieldDefinition as CustomFieldDefin
6
6
  import { WebsocketProvider } from 'y-websocket';
7
7
  import * as awarenessProtocol from 'y-protocols/awareness';
8
8
  import { CollabDocument } from '@/collabstate/CollabDocument';
9
+ import { ItemCopier } from '@/ItemCopier';
10
+ import { ExecutableExporter } from '@/ExecutableExporter';
9
11
  import { ScriptItem as ScriptItem$1, Script as Script$1 } from '@/repo/Script';
10
12
  import { ScriptField as ScriptField$1 } from '@/repo/ScriptField';
11
13
  import { TemplateEntry as TemplateEntry$1 } from '@/repo/TemplateEntry';
@@ -677,7 +679,7 @@ declare class JobManager {
677
679
  jobs: Map<string, JobEntry>;
678
680
  constructor(apiClient: any);
679
681
  getJobs(): JobEntry[];
680
- execute(type: string, elements: any[], parameters: any[], progressCallback?: Function | undefined): Promise<JobState>;
682
+ execute(type: string, elements: any[], parameters: any[], progressCallback: Function | undefined, requiredParameters: any): Promise<JobState>;
681
683
  }
682
684
 
683
685
  type PublishedVersion = {
@@ -1297,6 +1299,11 @@ type ApiClientOptions = {
1297
1299
  websocketPath: string;
1298
1300
  debug: boolean;
1299
1301
  };
1302
+ type ItemCopyResult = {
1303
+ original: string;
1304
+ clone: string;
1305
+ replaced?: string;
1306
+ };
1300
1307
  /**
1301
1308
  * Class representing an ApiClient.
1302
1309
  * @extends EventEmitter
@@ -1328,6 +1335,8 @@ declare class ApiClient extends EventEmitter {
1328
1335
  jobManager: JobManager;
1329
1336
  serializer: Serializer;
1330
1337
  collab: Collab;
1338
+ itemCopier: ItemCopier;
1339
+ executableExporter: ExecutableExporter;
1331
1340
  eventBus: typeof eventBus;
1332
1341
  api: AxiosInstance;
1333
1342
  ws: WebSocket | null;
@@ -1366,6 +1375,8 @@ declare class ApiClient extends EventEmitter {
1366
1375
  * @param data - The message to send.
1367
1376
  */
1368
1377
  websocketSend(data: string): void;
1378
+ getItemCopier(): ItemCopier;
1379
+ getExecutableExporter(): ExecutableExporter;
1369
1380
  getCollab(): Collab;
1370
1381
  getCollabUrl(): string;
1371
1382
  /**
@@ -1768,6 +1779,14 @@ declare class ApiClient extends EventEmitter {
1768
1779
  * @returns {Promise<Object>} The item history.
1769
1780
  */
1770
1781
  getItemHistory(id: any): Promise<any>;
1782
+ /**
1783
+ * Copies one or more items to a target folder. Returns a list of objects containing clone
1784
+ * @param itemIds array of item IDs to copy
1785
+ * @param targetFolderId target folder id
1786
+ * @param deepCopy should linked items also be copied?
1787
+ * @return Promise<ItemCopyResult[]>
1788
+ */
1789
+ copyItems(itemIds: string[], targetFolderId: string, deepCopy: boolean, overwrite: boolean): Promise<ItemCopyResult[]>;
1771
1790
  /**
1772
1791
  * Create a new item.
1773
1792
  * @param data - The item data.
@@ -2834,6 +2853,7 @@ declare class ApiClient extends EventEmitter {
2834
2853
  type: string;
2835
2854
  elements: any[];
2836
2855
  parameters: any[];
2856
+ requiredParameters: any;
2837
2857
  }): Promise<string>;
2838
2858
  /**
2839
2859
  * Get the list of manual job types.
@@ -10401,6 +10421,207 @@ declare function getDatatypes(): ({
10401
10421
  type: string;
10402
10422
  }[];
10403
10423
  typeName: string;
10424
+ } | {
10425
+ displayName: string;
10426
+ fields: ({
10427
+ datatype: string;
10428
+ defaultValue: string;
10429
+ displayName: string;
10430
+ name: string;
10431
+ type: string;
10432
+ options?: undefined;
10433
+ minValue?: undefined;
10434
+ if?: undefined;
10435
+ maxValue?: undefined;
10436
+ step?: undefined;
10437
+ info?: undefined;
10438
+ } | {
10439
+ datatype: string;
10440
+ defaultValue: boolean;
10441
+ displayName: string;
10442
+ name: string;
10443
+ type: string;
10444
+ options?: undefined;
10445
+ minValue?: undefined;
10446
+ if?: undefined;
10447
+ maxValue?: undefined;
10448
+ step?: undefined;
10449
+ info?: undefined;
10450
+ } | {
10451
+ datatype: string;
10452
+ defaultValue: {
10453
+ r: number;
10454
+ g: number;
10455
+ b: number;
10456
+ a: number;
10457
+ };
10458
+ displayName: string;
10459
+ name: string;
10460
+ type: string;
10461
+ options?: undefined;
10462
+ minValue?: undefined;
10463
+ if?: undefined;
10464
+ maxValue?: undefined;
10465
+ step?: undefined;
10466
+ info?: undefined;
10467
+ } | {
10468
+ datatype: string;
10469
+ defaultValue: string;
10470
+ displayName: string;
10471
+ name: string;
10472
+ type: string;
10473
+ options: string[];
10474
+ minValue?: undefined;
10475
+ if?: undefined;
10476
+ maxValue?: undefined;
10477
+ step?: undefined;
10478
+ info?: undefined;
10479
+ } | {
10480
+ datatype: string;
10481
+ defaultValue: number;
10482
+ displayName: string;
10483
+ minValue: number;
10484
+ name: string;
10485
+ type: string;
10486
+ if: {
10487
+ FogType: string;
10488
+ $or?: undefined;
10489
+ EnableFogNoise?: undefined;
10490
+ EnableFogHeight?: undefined;
10491
+ EnableFogWidth?: undefined;
10492
+ };
10493
+ options?: undefined;
10494
+ maxValue?: undefined;
10495
+ step?: undefined;
10496
+ info?: undefined;
10497
+ } | {
10498
+ datatype: string;
10499
+ defaultValue: number;
10500
+ displayName: string;
10501
+ minValue: number;
10502
+ maxValue: number;
10503
+ name: string;
10504
+ type: string;
10505
+ step: number;
10506
+ if: {
10507
+ $or: {
10508
+ FogType: string;
10509
+ }[];
10510
+ FogType?: undefined;
10511
+ EnableFogNoise?: undefined;
10512
+ EnableFogHeight?: undefined;
10513
+ EnableFogWidth?: undefined;
10514
+ };
10515
+ options?: undefined;
10516
+ info?: undefined;
10517
+ } | {
10518
+ datatype: string;
10519
+ defaultValue: boolean;
10520
+ displayName: string;
10521
+ name: string;
10522
+ info: string;
10523
+ type: string;
10524
+ options?: undefined;
10525
+ minValue?: undefined;
10526
+ if?: undefined;
10527
+ maxValue?: undefined;
10528
+ step?: undefined;
10529
+ } | {
10530
+ datatype: string;
10531
+ defaultValue: number;
10532
+ displayName: string;
10533
+ minValue: number;
10534
+ name: string;
10535
+ type: string;
10536
+ step: number;
10537
+ if: {
10538
+ EnableFogNoise: boolean;
10539
+ FogType?: undefined;
10540
+ $or?: undefined;
10541
+ EnableFogHeight?: undefined;
10542
+ EnableFogWidth?: undefined;
10543
+ };
10544
+ options?: undefined;
10545
+ maxValue?: undefined;
10546
+ info?: undefined;
10547
+ } | {
10548
+ datatype: string;
10549
+ defaultValue: number;
10550
+ displayName: string;
10551
+ maxValue: number;
10552
+ minValue: number;
10553
+ name: string;
10554
+ type: string;
10555
+ step: number;
10556
+ if: {
10557
+ EnableFogNoise: boolean;
10558
+ FogType?: undefined;
10559
+ $or?: undefined;
10560
+ EnableFogHeight?: undefined;
10561
+ EnableFogWidth?: undefined;
10562
+ };
10563
+ options?: undefined;
10564
+ info?: undefined;
10565
+ } | {
10566
+ datatype: string;
10567
+ defaultValue: number;
10568
+ displayName: string;
10569
+ name: string;
10570
+ type: string;
10571
+ step: number;
10572
+ if: {
10573
+ EnableFogHeight: boolean;
10574
+ FogType?: undefined;
10575
+ $or?: undefined;
10576
+ EnableFogNoise?: undefined;
10577
+ EnableFogWidth?: undefined;
10578
+ };
10579
+ options?: undefined;
10580
+ minValue?: undefined;
10581
+ maxValue?: undefined;
10582
+ info?: undefined;
10583
+ } | {
10584
+ datatype: string;
10585
+ defaultValue: number;
10586
+ displayName: string;
10587
+ name: string;
10588
+ type: string;
10589
+ step: number;
10590
+ if: {
10591
+ EnableFogWidth: boolean;
10592
+ FogType?: undefined;
10593
+ $or?: undefined;
10594
+ EnableFogNoise?: undefined;
10595
+ EnableFogHeight?: undefined;
10596
+ };
10597
+ options?: undefined;
10598
+ minValue?: undefined;
10599
+ maxValue?: undefined;
10600
+ info?: undefined;
10601
+ } | {
10602
+ datatype: string;
10603
+ defaultValue: number;
10604
+ maxValue: number;
10605
+ displayName: string;
10606
+ info: string;
10607
+ name: string;
10608
+ type: string;
10609
+ step: number;
10610
+ options?: undefined;
10611
+ minValue?: undefined;
10612
+ if?: undefined;
10613
+ })[];
10614
+ inputs: {
10615
+ displayName: string;
10616
+ name: string;
10617
+ types: string[];
10618
+ }[];
10619
+ outputs: {
10620
+ displayName: string;
10621
+ name: string;
10622
+ type: string;
10623
+ }[];
10624
+ typeName: string;
10404
10625
  } | {
10405
10626
  displayName: string;
10406
10627
  fields: ({
@@ -12163,10 +12384,12 @@ declare function hasPermission(userInfo: any, perm: any, needsSuperadmin: boolea
12163
12384
 
12164
12385
  declare class TemplateFactory {
12165
12386
  private templates;
12387
+ private templatesByField;
12166
12388
  private static _instance;
12167
12389
  static get instance(): TemplateFactory;
12168
- addTemplates(fieldName: string, templates: TemplateEntry$1[]): void;
12169
- getTemplate(fieldName: string, templateName: string): TemplateEntry$1 | undefined;
12390
+ addTemplates(itemType: string, fieldName: string, templates: TemplateEntry$1[]): void;
12391
+ getTemplate(itemType: string, fieldName: string, templateName: string): TemplateEntry$1 | undefined;
12392
+ getTemplates(itemType: string, fieldName: string): TemplateEntry$1[];
12170
12393
  }
12171
12394
 
12172
12395
  declare class LinkableItemsCache {