@hantera/portal-app 20260428.0.0-develop.1 → 20260609.0.0-develop.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.
Files changed (2) hide show
  1. package/dist/index.d.ts +278 -95
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -11,6 +11,7 @@ import { DataColumnValuesEnumSet } from '@hantera/design-system';
11
11
  import { DataColumnValuesEnumValue } from '@hantera/design-system';
12
12
  import { DataProvider } from '@hantera/design-system';
13
13
  import { DataRow } from '@hantera/design-system';
14
+ import { DateOnly } from '@hantera/design-system';
14
15
  import Decimal from 'decimal.js';
15
16
  import { DeepReadonly } from 'vue';
16
17
  import { default as default_2 } from 'decimal.js';
@@ -92,6 +93,8 @@ declare interface AddActivityLogCommand {
92
93
  messageTemplate: string;
93
94
  /** Dynamic properties to add to the log */
94
95
  dynamic?: Record<string, any>;
96
+ /** Override createdAt to align with external events. If not specified, time will be based on server time. */
97
+ createdAt?: any;
95
98
  }
96
99
 
97
100
  /**
@@ -105,6 +108,8 @@ declare interface AddActivityLogCommand_2 {
105
108
  messageTemplate: string;
106
109
  /** Dynamic properties to add to the log */
107
110
  dynamic?: Record<string, any>;
111
+ /** Override createdAt to align with external events. If not specified, time will be based on server time. */
112
+ createdAt?: any;
108
113
  }
109
114
 
110
115
  /**
@@ -118,6 +123,8 @@ declare interface AddActivityLogCommand_3 {
118
123
  messageTemplate: string;
119
124
  /** Dynamic properties to add to the log */
120
125
  dynamic?: Record<string, any>;
126
+ /** Override createdAt to align with external events. If not specified, time will be based on server time. */
127
+ createdAt?: any;
121
128
  }
122
129
 
123
130
  /**
@@ -131,6 +138,8 @@ declare interface AddActivityLogCommand_4 {
131
138
  messageTemplate: string;
132
139
  /** Dynamic properties to add to the log */
133
140
  dynamic?: Record<string, any>;
141
+ /** Override createdAt to align with external events. If not specified, time will be based on server time. */
142
+ createdAt?: any;
134
143
  }
135
144
 
136
145
  /**
@@ -267,11 +276,12 @@ export declare namespace Asset {
267
276
  GenerateAssetNumberByPrefixCommand,
268
277
  RemoveTagCommand_4 as RemoveTagCommand,
269
278
  SetDynamicFieldsCommand_4 as SetDynamicFieldsCommand,
270
- SetItemDynamicFieldsCommand_2 as SetItemDynamicFieldsCommand
279
+ SetItemDynamicFieldsCommand_2 as SetItemDynamicFieldsCommand,
280
+ SetTagsCommand_4 as SetTagsCommand
271
281
  }
272
282
  }
273
283
 
274
- declare type AssetCommand = AddActivityLogCommand_4 | AddTagCommand_4 | CreateItemCommand_2 | CreateItemRelationCommand_2 | CreateRelationCommand_2 | DeleteItemCommand_2 | DeleteItemRelationCommand_2 | DeleteRelationCommand_2 | GenerateAssetNumberByPrefixCommand | RemoveTagCommand_4 | SetDynamicFieldsCommand_4 | SetItemDynamicFieldsCommand_2;
284
+ declare type AssetCommand = AddActivityLogCommand_4 | AddTagCommand_4 | CreateItemCommand_2 | CreateItemRelationCommand_2 | CreateRelationCommand_2 | DeleteItemCommand_2 | DeleteItemRelationCommand_2 | DeleteRelationCommand_2 | GenerateAssetNumberByPrefixCommand | RemoveTagCommand_4 | SetDynamicFieldsCommand_4 | SetItemDynamicFieldsCommand_2 | SetTagsCommand_4;
275
285
 
276
286
  export declare const Authorize: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
277
287
 
@@ -374,15 +384,15 @@ declare interface BackOrder_2 {
374
384
 
375
385
  declare interface CalculatedDiscount {
376
386
  calculatedDiscountId: string;
377
- discountId?: string;
378
- promotionId?: string;
387
+ referenceType: 'staticDiscount' | 'promotion';
388
+ referenceId: string;
379
389
  value: default_2;
380
390
  }
381
391
 
382
392
  declare interface CalculatedDiscount_2 {
383
393
  calculatedDiscountId: string
384
- discountId?: string
385
- promotionId?: string
394
+ referenceType: 'staticDiscount' | 'promotion'
395
+ referenceId: string
386
396
  value: Decimal
387
397
  }
388
398
 
@@ -526,44 +536,6 @@ declare interface CreateAuthorizationCommand {
526
536
  authorizationState?: 'pending' | 'successful' | 'failed';
527
537
  }
528
538
 
529
- /**
530
- * Adds a new computed Order Discount to an Order using an embedded source code for the logic
531
- *
532
- * @see {@link https://developer.hantera.io/reference/actors/order/commands/create-computed-order-discount-by-source/|Hantera Developer Portal}
533
- */
534
- declare interface CreateComputedOrderDiscountBySourceCommand {
535
- type: 'createComputedOrderDiscountBySource';
536
- /** Optional Id. Must be unique. */
537
- discountId?: string;
538
- /** The source code for the discount logic */
539
- source: string;
540
- /** Additional parameters to pass to the discount logic, values must be in filtrera format */
541
- parameters?: Record<string, string>;
542
- /** Dynamic fields for metadata */
543
- dynamic?: Record<string, any>;
544
- /** Description/Name of discount. Should be meaningful to the customer as it's used on invoices and customer communication. */
545
- description?: string;
546
- }
547
-
548
- /**
549
- * Adds a new computed Order Discount to an Order based on a component
550
- *
551
- * @see {@link https://developer.hantera.io/reference/actors/order/commands/create-computed-order-discount/|Hantera Developer Portal}
552
- */
553
- declare interface CreateComputedOrderDiscountCommand {
554
- type: 'createComputedOrderDiscount';
555
- /** Optional Id. Must be unique. */
556
- discountId?: string;
557
- /** The component to use for the discount logic */
558
- componentId: string;
559
- /** Additional parameters to pass to the discount logic, values must be in filtrera format */
560
- parameters?: Record<string, string>;
561
- /** Dynamic fields for metadata */
562
- dynamic?: Record<string, any>;
563
- /** Description/Name of discount. Should be meaningful to the customer as it's used on invoices and customer communication. */
564
- description?: string;
565
- }
566
-
567
539
  /**
568
540
  * Adds a new Delivery to an Order
569
541
  *
@@ -676,6 +648,40 @@ declare interface CreateOrderLineCommand {
676
648
  skus?: Record<string, Decimal | number>;
677
649
  }
678
650
 
651
+ /**
652
+ * Creates a promotion on an Order with inline Filtrera source
653
+ *
654
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/create-promotion-by-source/|Hantera Developer Portal}
655
+ */
656
+ declare interface CreatePromotionBySourceCommand {
657
+ type: 'createPromotionBySource';
658
+ promotionId?: string;
659
+ source: string;
660
+ parameters?: Record<string, any>;
661
+ dynamic?: Record<string, any>;
662
+ description?: string;
663
+ promotionGroup: string;
664
+ canOnlyCombineWith?: string[];
665
+ canNotCombineWith?: string[];
666
+ }
667
+
668
+ /**
669
+ * Creates a promotion on an Order based on a component
670
+ *
671
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/create-promotion/|Hantera Developer Portal}
672
+ */
673
+ declare interface CreatePromotionCommand {
674
+ type: 'createPromotion';
675
+ promotionId?: string;
676
+ componentId: string;
677
+ parameters?: Record<string, any>;
678
+ dynamic?: Record<string, any>;
679
+ description?: string;
680
+ promotionGroup: string;
681
+ canOnlyCombineWith?: string[];
682
+ canNotCombineWith?: string[];
683
+ }
684
+
679
685
  /**
680
686
  * Adds a new graph node relation to a Ticket
681
687
  *
@@ -805,7 +811,7 @@ declare interface Customer_2 {
805
811
  orders: Array<Order_2>;
806
812
  }
807
813
 
808
- declare function date(date: Date | string, format?: string): string;
814
+ declare function date(date: DateOnly | Date | string): string;
809
815
 
810
816
  declare function dateTime(date: Date | string): string;
811
817
 
@@ -823,6 +829,9 @@ declare const _default_2: {
823
829
  timeline: AppSlot<Record<string, any>>;
824
830
  };
825
831
  delivery: {
832
+ header: AppSlot< {
833
+ delivery: Delivery;
834
+ }>;
826
835
  footer: AppSlot< {
827
836
  delivery: Delivery;
828
837
  }>;
@@ -1008,6 +1017,16 @@ declare interface DeleteOrderLineCommand {
1008
1017
  orderLineId: string;
1009
1018
  }
1010
1019
 
1020
+ /**
1021
+ * Deletes a promotion from an Order
1022
+ *
1023
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/delete-promotion/|Hantera Developer Portal}
1024
+ */
1025
+ declare interface DeletePromotionCommand {
1026
+ type: 'deletePromotion';
1027
+ promotionId: string;
1028
+ }
1029
+
1011
1030
  /**
1012
1031
  * Removes a graph node relation from a Ticket
1013
1032
  *
@@ -1050,8 +1069,6 @@ declare interface Delivery {
1050
1069
  deliveryNumber: string;
1051
1070
  deliveryState: 'open' | 'processing' | 'completed' | 'cancelled' | 'cancelledByOrder';
1052
1071
  deliveryAddress: Address;
1053
- inventoryKey: string;
1054
- inventoryDate?: Date;
1055
1072
  shippingPrice: default_2;
1056
1073
  shippingTaxFactor: default_2;
1057
1074
  shippingTaxTotal: default_2;
@@ -1073,8 +1090,6 @@ declare interface Delivery_2 {
1073
1090
  deliveryNumber: string
1074
1091
  deliveryState: 'open' | 'processing' | 'completed' | 'cancelled' | 'cancelledByOrder'
1075
1092
  deliveryAddress: Address_2
1076
- inventoryKey: string
1077
- inventoryDate?: Date
1078
1093
  shippingPrice: Decimal
1079
1094
  shippingTaxFactor: Decimal
1080
1095
  shippingTaxTotal: Decimal
@@ -1092,6 +1107,8 @@ declare interface Delivery_2 {
1092
1107
  shippingDiscounts: Array<Discount_2>
1093
1108
  }
1094
1109
 
1110
+ export declare type Dialogs = ReturnType<typeof useDialogs>;
1111
+
1095
1112
  declare interface Discount {
1096
1113
  discountId: string;
1097
1114
  discountType: 'percentage' | 'absolute';
@@ -1236,6 +1253,7 @@ export declare namespace Graph {
1236
1253
  Delivery_2 as Delivery,
1237
1254
  Payment_2 as Payment,
1238
1255
  Address_2 as Address,
1256
+ InvoiceRecipient,
1239
1257
  ActivityLog,
1240
1258
  Checkpoint,
1241
1259
  Invoice,
@@ -1256,6 +1274,7 @@ export declare namespace Graph_2 {
1256
1274
  Delivery,
1257
1275
  Payment,
1258
1276
  Address,
1277
+ InvoiceRecipient_2 as InvoiceRecipient,
1259
1278
  ActivityLog_2 as ActivityLog,
1260
1279
  Checkpoint_2 as Checkpoint,
1261
1280
  Invoice_2 as Invoice,
@@ -1649,7 +1668,7 @@ declare interface Invoice {
1649
1668
  invoiceNumber: string
1650
1669
  invoiceTotal: Decimal
1651
1670
  createdAt: Date
1652
- invoiceAddress: Address_2
1671
+ invoiceRecipient: InvoiceRecipient
1653
1672
  invoiceLines: InvoiceLine[]
1654
1673
  invoiceNetTotal: Decimal
1655
1674
  invoiceTaxTotal: Decimal
@@ -1663,7 +1682,7 @@ declare interface Invoice_2 {
1663
1682
  invoiceNumber: string;
1664
1683
  invoiceTotal: default_2;
1665
1684
  createdAt: Date;
1666
- invoiceAddress: Address;
1685
+ invoiceRecipient: InvoiceRecipient_2;
1667
1686
  invoiceLines: InvoiceLine_2[];
1668
1687
  invoiceNetTotal: default_2;
1669
1688
  invoiceTaxTotal: default_2;
@@ -1726,6 +1745,18 @@ declare interface InvoiceLineDiscount_2 {
1726
1745
  description: string;
1727
1746
  }
1728
1747
 
1748
+ declare interface InvoiceRecipient extends Address_2 {
1749
+ taxId?: string
1750
+ taxIdType?: string
1751
+ taxCountryCode?: string
1752
+ }
1753
+
1754
+ declare interface InvoiceRecipient_2 extends Address {
1755
+ taxId?: string;
1756
+ taxIdType?: string;
1757
+ taxCountryCode?: string;
1758
+ }
1759
+
1729
1760
  declare interface JobCompletedData {
1730
1761
  jobId: string;
1731
1762
  jobDefinitionId: string;
@@ -2315,6 +2346,14 @@ declare interface LiveQueryResult<T = unknown> {
2315
2346
  dispose(): void;
2316
2347
  }
2317
2348
 
2349
+ declare function loadLocales(): Promise<LocaleInfo[]>;
2350
+
2351
+ declare interface LocaleInfo {
2352
+ key: string;
2353
+ label: string;
2354
+ language: string;
2355
+ }
2356
+
2318
2357
  declare interface LocalizedLabel {
2319
2358
  default: string
2320
2359
  [languageCode: string]: string
@@ -2419,7 +2458,7 @@ declare interface Order {
2419
2458
  currencyCode: string
2420
2459
  channelKey?: string
2421
2460
  customerNumber?: string
2422
- invoiceAddress: Address_2
2461
+ invoiceRecipient: InvoiceRecipient
2423
2462
  locale: string
2424
2463
  notes?: string
2425
2464
  orderTaxTotal: Decimal
@@ -2448,7 +2487,7 @@ declare interface Order_2 {
2448
2487
  currencyCode: string;
2449
2488
  channelKey?: string;
2450
2489
  customerNumber?: string;
2451
- invoiceAddress: Address;
2490
+ invoiceRecipient: InvoiceRecipient_2;
2452
2491
  locale: string;
2453
2492
  notes?: string;
2454
2493
  orderTaxTotal: default_2;
@@ -2478,16 +2517,17 @@ export declare namespace Order_3 {
2478
2517
  CancelDeliveryCommand,
2479
2518
  CancelInvoiceCommand,
2480
2519
  CompleteDeliveryCommand,
2481
- CreateComputedOrderDiscountBySourceCommand,
2482
- CreateComputedOrderDiscountCommand,
2483
2520
  CreateDeliveryCommand,
2484
2521
  CreateOrderLineCommand,
2522
+ CreatePromotionBySourceCommand,
2523
+ CreatePromotionCommand,
2485
2524
  CreateReturnCommand,
2486
2525
  CreateStaticOrderDiscountCommand,
2487
2526
  CreateStaticOrderLineDiscountCommand,
2488
2527
  CreateStaticShippingDiscountCommand,
2489
2528
  DeleteDiscountCommand,
2490
2529
  DeleteOrderLineCommand,
2530
+ DeletePromotionCommand,
2491
2531
  DeleteReturnCommand,
2492
2532
  GenerateOrderNumberByPrefixCommand,
2493
2533
  InvoiceCommand,
@@ -2502,14 +2542,14 @@ export declare namespace Order_3 {
2502
2542
  RetractOrderLineFromInvoicingCommand,
2503
2543
  RetractShippingFromInvoicingCommand,
2504
2544
  SetChannelKeyCommand,
2505
- SetComputedOrderDiscountParametersCommand,
2506
2545
  SetCustomerNumberCommand,
2507
2546
  SetDeliveryAddressCommand,
2508
2547
  SetDeliveryDynamicFieldsCommand,
2509
- SetDeliveryInventoryCommand,
2548
+ SetDeliveryTagsCommand,
2510
2549
  SetDiscountDescriptionCommand,
2511
2550
  SetDiscountDynamicFieldsCommand,
2512
2551
  SetInvoiceAddressCommand,
2552
+ SetInvoiceRecipientCommand,
2513
2553
  SetLocaleCommand,
2514
2554
  SetNotesCommand,
2515
2555
  SetOrderDynamicFieldsCommand,
@@ -2520,16 +2560,20 @@ export declare namespace Order_3 {
2520
2560
  SetOrderLineTaxCommand,
2521
2561
  SetOrderLineUnitPriceCommand,
2522
2562
  SetOrderStateCommand,
2563
+ SetPromotionDescriptionCommand,
2564
+ SetPromotionDynamicFieldsCommand,
2565
+ SetPromotionParametersCommand,
2523
2566
  SetReturnDynamicFieldsCommand,
2524
2567
  SetShippingPriceCommand,
2525
2568
  SetShippingProductCommand,
2526
2569
  SetShippingTaxCommand,
2527
2570
  SetStaticDiscountValueCommand,
2528
- UnsetDeliveryInventoryCommand
2571
+ SetTagsCommand,
2572
+ SplitOrderLineCommand
2529
2573
  }
2530
2574
  }
2531
2575
 
2532
- declare type OrderCommand = AddActivityLogCommand | AddDeliveryTagCommand | AddTagCommand | CancelDeliveryCommand | CancelInvoiceCommand | CompleteDeliveryCommand | CreateComputedOrderDiscountBySourceCommand | CreateComputedOrderDiscountCommand | CreateDeliveryCommand | CreateOrderLineCommand | CreateReturnCommand | CreateStaticOrderDiscountCommand | CreateStaticOrderLineDiscountCommand | CreateStaticShippingDiscountCommand | DeleteDiscountCommand | DeleteOrderLineCommand | DeleteReturnCommand | GenerateOrderNumberByPrefixCommand | InvoiceCommand | LinkPaymentCommand | MoveOrderLineToDeliveryCommand | OpenDeliveryCommand | ReleaseDeliveryCommand | ReleaseOrderLineToInvoicingCommand | ReleaseShippingToInvoicingCommand | RemoveDeliveryTagCommand | RemoveTagCommand | RetractOrderLineFromInvoicingCommand | RetractShippingFromInvoicingCommand | SetChannelKeyCommand | SetComputedOrderDiscountParametersCommand | SetCustomerNumberCommand | SetDeliveryAddressCommand | SetDeliveryDynamicFieldsCommand | SetDeliveryInventoryCommand | SetDiscountDescriptionCommand | SetDiscountDynamicFieldsCommand | SetInvoiceAddressCommand | SetLocaleCommand | SetNotesCommand | SetOrderDynamicFieldsCommand | SetOrderLineDynamicFieldsCommand | SetOrderLineProductCommand | SetOrderLineQuantityCommand | SetOrderLineSkusCommand | SetOrderLineTaxCommand | SetOrderLineUnitPriceCommand | SetOrderStateCommand | SetReturnDynamicFieldsCommand | SetShippingPriceCommand | SetShippingProductCommand | SetShippingTaxCommand | SetStaticDiscountValueCommand | UnsetDeliveryInventoryCommand;
2576
+ declare type OrderCommand = AddActivityLogCommand | AddDeliveryTagCommand | AddTagCommand | CancelDeliveryCommand | CancelInvoiceCommand | CompleteDeliveryCommand | CreateDeliveryCommand | CreateOrderLineCommand | CreatePromotionBySourceCommand | CreatePromotionCommand | CreateReturnCommand | CreateStaticOrderDiscountCommand | CreateStaticOrderLineDiscountCommand | CreateStaticShippingDiscountCommand | DeleteDiscountCommand | DeleteOrderLineCommand | DeletePromotionCommand | DeleteReturnCommand | GenerateOrderNumberByPrefixCommand | InvoiceCommand | LinkPaymentCommand | MoveOrderLineToDeliveryCommand | OpenDeliveryCommand | ReleaseDeliveryCommand | ReleaseOrderLineToInvoicingCommand | ReleaseShippingToInvoicingCommand | RemoveDeliveryTagCommand | RemoveTagCommand | RetractOrderLineFromInvoicingCommand | RetractShippingFromInvoicingCommand | SetChannelKeyCommand | SetCustomerNumberCommand | SetDeliveryAddressCommand | SetDeliveryDynamicFieldsCommand | SetDeliveryTagsCommand | SetDiscountDescriptionCommand | SetDiscountDynamicFieldsCommand | SetInvoiceAddressCommand | SetInvoiceRecipientCommand | SetLocaleCommand | SetNotesCommand | SetOrderDynamicFieldsCommand | SetOrderLineDynamicFieldsCommand | SetOrderLineProductCommand | SetOrderLineQuantityCommand | SetOrderLineSkusCommand | SetOrderLineTaxCommand | SetOrderLineUnitPriceCommand | SetOrderStateCommand | SetPromotionDescriptionCommand | SetPromotionDynamicFieldsCommand | SetPromotionParametersCommand | SetReturnDynamicFieldsCommand | SetShippingPriceCommand | SetShippingProductCommand | SetShippingTaxCommand | SetStaticDiscountValueCommand | SetTagsCommand | SplitOrderLineCommand;
2533
2577
 
2534
2578
  declare interface OrderJournalEntry {
2535
2579
  orderJournalEntryId: string
@@ -2640,6 +2684,23 @@ declare const orderView: {
2640
2684
  contextMenuProvider: AppService< {
2641
2685
  buildDeliveryContextMenu(context: PortalContext, orderViewContext: OrderViewContext, delivery: Models_2.Graph.Delivery): ContextMenuSection;
2642
2686
  }>;
2687
+ /**
2688
+ * Allows services to react to events occurring in the standard order view,
2689
+ * such as the order being saved.
2690
+ */
2691
+ eventsProvider: AppService< {
2692
+ /**
2693
+ * Called after the order has been successfully saved (commands applied and
2694
+ * order state refreshed). `appliedCommands` are the commands that were
2695
+ * committed in this save.
2696
+ */
2697
+ onOrderSaved?(event: {
2698
+ context: PortalContext;
2699
+ orderViewContext: OrderViewContext;
2700
+ order: Models_2.Graph.Order;
2701
+ appliedCommands: OrderCommand[];
2702
+ }): Promise<void>;
2703
+ }>;
2643
2704
  };
2644
2705
 
2645
2706
  declare interface OrderViewContext {
@@ -2670,8 +2731,10 @@ declare interface OrderViewContext {
2670
2731
  redo(): boolean;
2671
2732
  /**
2672
2733
  * Saves pending changes. Automatically refreshes the order state.
2734
+ * Resolves with the list of commands that were committed in this save
2735
+ * (empty if there was nothing to save).
2673
2736
  */
2674
- save(): Promise<void>;
2737
+ save(): Promise<OrderCommand[]>;
2675
2738
  /**
2676
2739
  * Refreshes the order state with the server. If there are pending changes, they will be previewed.
2677
2740
  */
@@ -2750,7 +2813,8 @@ export declare namespace Payment_3 {
2750
2813
  RemoveTagCommand_2 as RemoveTagCommand,
2751
2814
  SetAuthorizationAmountCommand,
2752
2815
  SetAuthorizationStateCommand,
2753
- SetDynamicFieldsCommand
2816
+ SetDynamicFieldsCommand,
2817
+ SetTagsCommand_2 as SetTagsCommand
2754
2818
  }
2755
2819
  }
2756
2820
 
@@ -2786,7 +2850,7 @@ declare interface PaymentCapture_2 {
2786
2850
  }
2787
2851
  }
2788
2852
 
2789
- declare type PaymentCommand = AddActivityLogCommand_2 | AddTagCommand_2 | CreateAuthorizationCommand | GeneratePaymentNumberByPrefixCommand | RemoveTagCommand_2 | SetAuthorizationAmountCommand | SetAuthorizationStateCommand | SetDynamicFieldsCommand;
2853
+ declare type PaymentCommand = AddActivityLogCommand_2 | AddTagCommand_2 | CreateAuthorizationCommand | GeneratePaymentNumberByPrefixCommand | RemoveTagCommand_2 | SetAuthorizationAmountCommand | SetAuthorizationStateCommand | SetDynamicFieldsCommand | SetTagsCommand_2;
2790
2854
 
2791
2855
  declare interface PaymentJournalEntry {
2792
2856
  paymentJournalEntryId: string;
@@ -3062,7 +3126,7 @@ declare interface ReserveCommand {
3062
3126
  inventoryKey: string;
3063
3127
  /** The number of units to reserve. Must be greater than zero. */
3064
3128
  quantity: Decimal | number;
3065
- /** Optional date/time when the reserved stock should be available if the stock is not needed immediately. */
3129
+ /** Optional date when the reserved stock should be available if the stock is not needed immediately. */
3066
3130
  inventoryDate?: any;
3067
3131
  /** Optional list of allocations to use for the reservation. */
3068
3132
  stockAllocations?: string[];
@@ -3102,6 +3166,10 @@ declare interface SearchProduct {
3102
3166
  export declare interface ServiceContext {
3103
3167
  processes: Processes;
3104
3168
  backend: BackendApi;
3169
+ dialogs: Dialogs;
3170
+ localization: {
3171
+ resolveLabel: (label: string | Record<string, string> | null | undefined) => string;
3172
+ };
3105
3173
  }
3106
3174
 
3107
3175
  /**
@@ -3169,17 +3237,6 @@ declare interface SetChannelKeyCommand_2 {
3169
3237
  value: string;
3170
3238
  }
3171
3239
 
3172
- /**
3173
- * Sets a computed order discount's parameters
3174
- *
3175
- * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-computed-order-discount-parameters/|Hantera Developer Portal}
3176
- */
3177
- declare interface SetComputedOrderDiscountParametersCommand {
3178
- type: 'setComputedOrderDiscountParameters';
3179
- discountId: string;
3180
- parameters: Record<string, string>;
3181
- }
3182
-
3183
3240
  /**
3184
3241
  * Sets the customer number of an order.
3185
3242
  *
@@ -3225,16 +3282,16 @@ declare interface SetDeliveryDynamicFieldsCommand {
3225
3282
  }
3226
3283
 
3227
3284
  /**
3228
- * Sets the inventory and inventory date of a Delivery. Stock reservations will be updated if there are any.
3285
+ * Replaces all tags on a Delivery
3229
3286
  *
3230
- * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-delivery-inventory/|Hantera Developer Portal}
3287
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-delivery-tags/|Hantera Developer Portal}
3231
3288
  */
3232
- declare interface SetDeliveryInventoryCommand {
3233
- type: 'setDeliveryInventory';
3234
- /** The ID of the Delivery to set the inventory of */
3289
+ declare interface SetDeliveryTagsCommand {
3290
+ type: 'setDeliveryTags';
3291
+ /** The ID of the Delivery to set tags on */
3235
3292
  deliveryId: string;
3236
- inventoryKey: string;
3237
- inventoryDate: any;
3293
+ /** The tag keys */
3294
+ keys: string[];
3238
3295
  }
3239
3296
 
3240
3297
  /**
@@ -3310,7 +3367,7 @@ declare interface SetIncomingStockCommand {
3310
3367
  reference: string;
3311
3368
  /** The key of the inventory the incoming stock is expected at. */
3312
3369
  inventoryKey: string;
3313
- /** Date of when the incoming stock is expected to be available for outbound shipments. */
3370
+ /** Date when the incoming stock is expected to be available for outbound shipments. */
3314
3371
  expectedOn: any;
3315
3372
  /** The number of units expected */
3316
3373
  quantity: Decimal | number;
@@ -3319,6 +3376,7 @@ declare interface SetIncomingStockCommand {
3319
3376
  /**
3320
3377
  * Sets the invoice address of an Order which will be used for new invoices
3321
3378
  *
3379
+ * @deprecated Use SetInvoiceRecipient command instead
3322
3380
  * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-invoice-address/|Hantera Developer Portal}
3323
3381
  */
3324
3382
  declare interface SetInvoiceAddressCommand {
@@ -3336,6 +3394,29 @@ declare interface SetInvoiceAddressCommand {
3336
3394
  phone?: string;
3337
3395
  }
3338
3396
 
3397
+ /**
3398
+ * Sets the invoice recipient of an Order which will be used for new invoices
3399
+ *
3400
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-invoice-recipient/|Hantera Developer Portal}
3401
+ */
3402
+ declare interface SetInvoiceRecipientCommand {
3403
+ type: 'setInvoiceRecipient';
3404
+ name?: string;
3405
+ careOf?: string;
3406
+ attention?: string;
3407
+ addressLine1?: string;
3408
+ addressLine2?: string;
3409
+ city?: string;
3410
+ state?: string;
3411
+ postalCode?: string;
3412
+ countryCode?: string;
3413
+ email?: string;
3414
+ phone?: string;
3415
+ taxId?: string;
3416
+ taxIdType?: string;
3417
+ taxCountryCode?: string;
3418
+ }
3419
+
3339
3420
  /**
3340
3421
  * Sets dynamic fields of a ticket item. Non specified fields will be left unchanged. Set value to null to remove field.
3341
3422
  *
@@ -3500,6 +3581,39 @@ declare interface SetPhysicalStockCommand {
3500
3581
  relative: boolean;
3501
3582
  }
3502
3583
 
3584
+ /**
3585
+ * Sets the description on a promotion
3586
+ *
3587
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-promotion-description/|Hantera Developer Portal}
3588
+ */
3589
+ declare interface SetPromotionDescriptionCommand {
3590
+ type: 'setPromotionDescription';
3591
+ promotionId: string;
3592
+ description?: string;
3593
+ }
3594
+
3595
+ /**
3596
+ * Sets dynamic fields on a promotion
3597
+ *
3598
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-promotion-dynamic-fields/|Hantera Developer Portal}
3599
+ */
3600
+ declare interface SetPromotionDynamicFieldsCommand {
3601
+ type: 'setPromotionDynamicFields';
3602
+ promotionId: string;
3603
+ fields: Record<string, any>;
3604
+ }
3605
+
3606
+ /**
3607
+ * Sets parameters on a promotion
3608
+ *
3609
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-promotion-parameters/|Hantera Developer Portal}
3610
+ */
3611
+ declare interface SetPromotionParametersCommand {
3612
+ type: 'setPromotionParameters';
3613
+ promotionId: string;
3614
+ parameters: Record<string, any>;
3615
+ }
3616
+
3503
3617
  /**
3504
3618
  * Sets dynamic fields of a return. Non specified fields will be left unchanged. Set value to null to remove field.
3505
3619
  *
@@ -3572,7 +3686,55 @@ declare interface SetStaticDiscountValueCommand {
3572
3686
  value: Decimal | number;
3573
3687
  }
3574
3688
 
3689
+ /**
3690
+ * Replaces all tags on an Order
3691
+ *
3692
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/set-tags/|Hantera Developer Portal}
3693
+ */
3694
+ declare interface SetTagsCommand {
3695
+ type: 'setTags';
3696
+ /** The tag keys */
3697
+ keys: string[];
3698
+ }
3699
+
3700
+ /**
3701
+ * Replaces all tags on a Payment
3702
+ *
3703
+ * @see {@link https://developer.hantera.io/reference/actors/payment/commands/set-tags/|Hantera Developer Portal}
3704
+ */
3705
+ declare interface SetTagsCommand_2 {
3706
+ type: 'setTags';
3707
+ /** The tag keys */
3708
+ keys: string[];
3709
+ }
3710
+
3711
+ /**
3712
+ * Replaces all tags on a Ticket
3713
+ *
3714
+ * @see {@link https://developer.hantera.io/reference/actors/ticket/commands/set-tags/|Hantera Developer Portal}
3715
+ */
3716
+ declare interface SetTagsCommand_3 {
3717
+ type: 'setTags';
3718
+ /** The tag keys */
3719
+ keys: string[];
3720
+ }
3721
+
3722
+ /**
3723
+ * Replaces all tags on an Asset
3724
+ *
3725
+ * @see {@link https://developer.hantera.io/reference/actors/asset/commands/set-tags/|Hantera Developer Portal}
3726
+ */
3727
+ declare interface SetTagsCommand_4 {
3728
+ type: 'setTags';
3729
+ /** The tag keys */
3730
+ keys: string[];
3731
+ }
3732
+
3575
3733
  declare interface ShippingProduct {
3734
+ /**
3735
+ * Optional unique internal ID, useful if multiple options share the same productNumber.
3736
+ */
3737
+ optionId?: string;
3576
3738
  productNumber: string;
3577
3739
  description: string;
3578
3740
  price: default_2;
@@ -3599,6 +3761,23 @@ export declare namespace Sku {
3599
3761
 
3600
3762
  declare type SkuCommand = ReserveCommand | SetAllocationCommand | SetDynamicFieldsCommand_2 | SetIncomingStockCommand | SetPhysicalStockCommand | UnreserveCommand;
3601
3763
 
3764
+ /**
3765
+ * Splits an existing order line into two by moving a portion of its quantity onto a new order line. The new line inherits product, price, dynamic fields and per-unit SKU composition from the original. Discounts and totals are left to be recomputed by the order pipeline.
3766
+ *
3767
+ * @see {@link https://developer.hantera.io/reference/actors/order/commands/split-order-line/|Hantera Developer Portal}
3768
+ */
3769
+ declare interface SplitOrderLineCommand {
3770
+ type: 'splitOrderLine';
3771
+ /** The ID of the existing Order Line to split. */
3772
+ orderLineId: string;
3773
+ /** Optional. The ID to assign to the new Order Line. A new GUID is generated when omitted. */
3774
+ newOrderLineId?: string;
3775
+ /** The quantity to move from the original Order Line onto the new one. Must be greater than 0 and less than the original line's quantity. */
3776
+ quantity: Decimal | number;
3777
+ /** Optional. The ID of an existing Delivery to place the new Order Line in. The new line stays in the original line's Delivery when omitted. */
3778
+ newDeliveryId?: string;
3779
+ }
3780
+
3602
3781
  export declare namespace standardServices {
3603
3782
  export {
3604
3783
  ShippingProduct,
@@ -3706,11 +3885,12 @@ export declare namespace Ticket {
3706
3885
  RemoveTagCommand_3 as RemoveTagCommand,
3707
3886
  SetChannelKeyCommand_2 as SetChannelKeyCommand,
3708
3887
  SetDynamicFieldsCommand_3 as SetDynamicFieldsCommand,
3709
- SetItemDynamicFieldsCommand
3888
+ SetItemDynamicFieldsCommand,
3889
+ SetTagsCommand_3 as SetTagsCommand
3710
3890
  }
3711
3891
  }
3712
3892
 
3713
- declare type TicketCommand = AddActivityLogCommand_3 | AddTagCommand_3 | CreateItemCommand | CreateItemRelationCommand | CreateRelationCommand | DeleteItemCommand | DeleteItemRelationCommand | DeleteRelationCommand | GenerateTicketNumberByPrefixCommand | RemoveTagCommand_3 | SetChannelKeyCommand_2 | SetDynamicFieldsCommand_3 | SetItemDynamicFieldsCommand;
3893
+ declare type TicketCommand = AddActivityLogCommand_3 | AddTagCommand_3 | CreateItemCommand | CreateItemRelationCommand | CreateRelationCommand | DeleteItemCommand | DeleteItemRelationCommand | DeleteRelationCommand | GenerateTicketNumberByPrefixCommand | RemoveTagCommand_3 | SetChannelKeyCommand_2 | SetDynamicFieldsCommand_3 | SetItemDynamicFieldsCommand | SetTagsCommand_3;
3714
3894
 
3715
3895
  declare function time(date: Date | string): string;
3716
3896
 
@@ -3730,17 +3910,6 @@ declare interface UnreserveCommand {
3730
3910
  orderLineId: string;
3731
3911
  }
3732
3912
 
3733
- /**
3734
- * Removes the inventory from a Delivery. Stock reservations will be updated if there are any.
3735
- *
3736
- * @see {@link https://developer.hantera.io/reference/actors/order/commands/unset-delivery-inventory/|Hantera Developer Portal}
3737
- */
3738
- declare interface UnsetDeliveryInventoryCommand {
3739
- type: 'unsetDeliveryInventory';
3740
- /** The ID of the Delivery to set the address to */
3741
- deliveryId: string;
3742
- }
3743
-
3744
3913
  export declare function useAppContext(): {
3745
3914
  appId: string;
3746
3915
  getAppViewPath(relativePath: string, appId?: string): string;
@@ -3916,6 +4085,20 @@ export declare function useRegistry(): {
3916
4085
  listChannels(): Promise<Record<string, ChannelEntry_2>>;
3917
4086
  };
3918
4087
 
4088
+ export declare function useResolveLabel(): {
4089
+ resolve: (label: string | Record<string, string> | undefined | null) => string;
4090
+ locales: Ref< {
4091
+ key: string;
4092
+ label: string;
4093
+ language: string;
4094
+ }[], LocaleInfo[] | {
4095
+ key: string;
4096
+ label: string;
4097
+ language: string;
4098
+ }[]>;
4099
+ loadLocales: typeof loadLocales;
4100
+ };
4101
+
3919
4102
  export declare interface ViewContext {
3920
4103
  /**
3921
4104
  * A unique ID identifying this view instance
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hantera/portal-app",
3
- "version": "20260428.0.0-develop.1",
3
+ "version": "20260609.0.0-develop.3",
4
4
  "types": "./dist/index.d.ts",
5
5
  "scripts": {
6
6
  "build": "cpx ../../portal/portal-app/dist/**/*.d.ts ./dist -C"