@retaila/shared-types 1.1.122 → 1.1.123

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.mts CHANGED
@@ -1182,6 +1182,22 @@ declare enum OrderDeliveryType {
1182
1182
  SHIPPING = "SHIPPING",
1183
1183
  PICKUP = "PICKUP"
1184
1184
  }
1185
+ /**
1186
+ * Pseudo-estado amigable para la vista/filtro de órdenes en backoffice.
1187
+ * Cada valor se deriva de combinaciones de status, paymentStatus, fulfillmentStatus y deliveryType.
1188
+ */
1189
+ declare enum DisplayOrderStatus {
1190
+ PENDIENTES_DE_PAGO = "PENDIENTES_DE_PAGO",
1191
+ EN_PROCESO = "EN_PROCESO",
1192
+ LISTAS_PARA_ENVIAR = "LISTAS_PARA_ENVIAR",
1193
+ LISTAS_PARA_RETIRAR = "LISTAS_PARA_RETIRAR",
1194
+ ENVIADAS = "ENVIADAS",
1195
+ ENTREGADAS = "ENTREGADAS",
1196
+ EN_ESPERA = "EN_ESPERA",
1197
+ CON_PROBLEMAS = "CON_PROBLEMAS",
1198
+ CANCELADAS = "CANCELADAS",
1199
+ REEMBOLSADAS = "REEMBOLSADAS"
1200
+ }
1185
1201
  interface StatusChangeHistory {
1186
1202
  type: 'order' | 'fulfillment' | 'payment';
1187
1203
  status: OrderStatus | FulfillmentStatus | PaymentStatus;
@@ -1225,6 +1241,16 @@ interface AdminOrderStatusChangeDto {
1225
1241
 
1226
1242
  declare function getOrderStatusInfo(status: OrderStatus): StatusInfo;
1227
1243
  declare function getOrderPaymentStatusInfo(status: OrderPaymentStatus): StatusInfo;
1244
+ declare function getDisplayOrderStatusInfo(displayStatus: DisplayOrderStatus): StatusInfo;
1245
+ /** Order-like minimal shape for computing display status */
1246
+ type OrderForDisplayStatus = Pick<Order, 'status' | 'paymentStatus' | 'deliveryType'> & {
1247
+ fulfillmentStatus?: FulfillmentStatus | null;
1248
+ };
1249
+ /**
1250
+ * Derives the display (pseudo) status for an order from real status, paymentStatus, fulfillmentStatus and deliveryType.
1251
+ * Evaluation order matters: Canceladas and Reembolsadas are mutually exclusive (Canceladas wins).
1252
+ */
1253
+ declare function getDisplayOrderStatus(order: OrderForDisplayStatus): DisplayOrderStatus;
1228
1254
 
1229
1255
  /**
1230
1256
  * Add an item to the cart
@@ -1295,6 +1321,7 @@ interface CartUpdateDto {
1295
1321
  department: string;
1296
1322
  };
1297
1323
  accountPaymentMethodId?: string;
1324
+ customerNote?: string | null;
1298
1325
  }
1299
1326
  /**
1300
1327
  * Confirm a cart
@@ -3348,4 +3375,4 @@ interface AccountServiceBillingCharge {
3348
3375
  deletedAt?: Date | null;
3349
3376
  }
3350
3377
 
3351
- export { type Account, type AccountAiCreditTransaction, type AccountAiCredits, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, type AccountServiceBillingCharge, type AccountServicePlan, AccountServicePlanStatus, AccountStatus, type AccountUserRoleLink, type ActiveSession, type Address, type AdminOrderStatusChangeDto, AiCreditSource, AiCreditTransactionReason, AiCreditType, type AiCreditsBalance, type AnalyticsEvent, AnalyticsEventType, type AnalyticsFunnelStep, type AnalyticsOverview, type AnalyticsPageview, type AnalyticsPagination, type AnalyticsQueryParams, type AnalyticsSession, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, BillingInterval, type ButtonStyle, COUNTRY_DEFAULTS, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, type CampaignData, type CampaignPerformance, CampaignStatus, type Cart, type CartConfirmDto, type CartDeliveryMethod, type CartDeliveryMethodAdjustment, type CartDeliveryMethodCreateData, type CartDeliveryMethodCreateDto, type CartDeliveryMethodFindParams, type CartDeliveryMethodResponse, type CartDeliveryMethodUpdateData, type CartDeliveryMethodUpdateDto, CartDeliveryType, type CartItem, type CartItemAddDto, type CartItemAttributeDetail, CartItemErrorCode, type CartItemRemoveDto, type CartItemUpdateDto, type CartItemValidation, type CartLineItemAdjustment, type CartPromotion, CartSource, CartStatus, type CartUpdateDto, type ChargeSellerAllocation, ChargeStatus, ChargeType, type Collection, type CollectionMedia, type CollectionProductLink, type CollectionRule, CollectionRuleField, CollectionRuleFieldLabels, CollectionRuleOperator, CollectionRuleOperatorLabels, CollectionRulesLogic, CollectionStatus, CollectionStatusLabels, CollectionType, CollectionTypeLabels, type ColorVariant, type CountryDefaultBranchAddress, type CountryDefaultConfig, type CountryDefaultTax, type CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateAnalyticsSessionDto, type CreateCollectionDTO, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, type CreateRoleDTO, type CreateStoreComponentTemplateDTO, type CreateStoreTemplateDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type DesignTokens, DeviceType, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, type Fulfillment, type FulfillmentDeliveryOption, type FulfillmentItem, type FulfillmentLabel, type FulfillmentLabelCreateData, type FulfillmentLabelUpdateData, type FulfillmentProviderAdapter, type FulfillmentProviderContext, type FulfillmentProviderCreateInput, type FulfillmentProviderCreateOutput, type FulfillmentProviderKey, type FulfillmentProviderProcessWebhookInput, type FulfillmentProviderProcessWebhookOutput, type FulfillmentRecollectionCapabilities, type FulfillmentRecollectionConfig, type FulfillmentRecollectionMode, type FulfillmentRecollectionSchedule, FulfillmentStatus, type FulfillmentTrackingEvent, type FunnelData, FunnelStep, type FunnelStepData, type GeoZone, type GeoZoneInput, GeoZoneStatus, type HistoricalDataPoint, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type InternalNotificationConfig, InternalNotificationType, type LinkButtonStyle, type MapPosition, type Media, MediaType, NavigationItemType, type NavigationMenuConfig, type NavigationMenuItem, type NeutralColorScale, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type PageData, PageType, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Permission, type Phone, type PickupLocation, type Product, type ProductAnalyticsData, type ProductAnalyticsItem, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, ProductVariantStatus, type Promotion, type PromotionApplicationMethod, type PromotionApplicationMethodInput, type PromotionApplicationMethodPromotionRule, PromotionApplicationType, type PromotionListFilters, type PromotionPromotionRule, type PromotionRule, type PromotionRuleInput, PromotionRuleOperator, type PromotionRuleValue, PromotionStatus, PromotionTargetType, PromotionType, PubSubTopics, type RealtimeAnalytics, type RecentEvent, type Role, type RolePermissionLink, type RoundingConfig, RoundingMethod, RoundingRule, SUPPORTED_COUNTRIES, type Seller, type SellerPeriodBalance, type ServiceBillingPlan, type ServiceBillingPlanLimits, type ServiceBillingPlanPrice, type ServiceBillingPlanSpec, type ServiceBillingPlanSpecCategory, type ServiceBillingPlanSpecItem, type SessionHeartbeatDto, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreComponentTemplate, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationFooterZone, type StoreCustomizationHeaderZone, type StoreCustomizationLayout, type StoreCustomizationLayoutComponent, type StoreCustomizationLayoutLegacy, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type StoreSettings, type StoreTemplate, type StoreTemplateMocks, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type SupportedCountryCode, type SurfaceColors, type ThemeBorderRadius, type ThemeBorderWidth, type ThemeBorders, type ThemeButtonSize, type ThemeButtonSizes, type ThemeButtonVariant, type ThemeButtonVariants, type ThemeButtons, type ThemeColorPalette, type ThemeConfig, type ThemeFonts, type ThemeProductCard, type ThemeShadows, type ThemeSpacing, type ThemeTypography, type ThemeTypographySizes, type ThemeTypographyStyles, type TopPagesData, type TrackEventDto, type TrackPageviewDto, TrafficSource, type TrafficSourceItem, type TrafficSourcesData, type TypographyStyle, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateCollectionDTO, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdateNotificationSettingsDTO, type UpdatePromotionDTO, type UpdateRoleDTO, type UpdateStoreComponentTemplateDTO, type UpdateStoreTemplateDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCountryDefaults, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, isLegacyLayout, isSupportedCountry, isZonedLayout, parsePriceFormatPattern };
3378
+ export { type Account, type AccountAiCreditTransaction, type AccountAiCredits, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, type AccountServiceBillingCharge, type AccountServicePlan, AccountServicePlanStatus, AccountStatus, type AccountUserRoleLink, type ActiveSession, type Address, type AdminOrderStatusChangeDto, AiCreditSource, AiCreditTransactionReason, AiCreditType, type AiCreditsBalance, type AnalyticsEvent, AnalyticsEventType, type AnalyticsFunnelStep, type AnalyticsOverview, type AnalyticsPageview, type AnalyticsPagination, type AnalyticsQueryParams, type AnalyticsSession, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, BillingInterval, type ButtonStyle, COUNTRY_DEFAULTS, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, type CampaignData, type CampaignPerformance, CampaignStatus, type Cart, type CartConfirmDto, type CartDeliveryMethod, type CartDeliveryMethodAdjustment, type CartDeliveryMethodCreateData, type CartDeliveryMethodCreateDto, type CartDeliveryMethodFindParams, type CartDeliveryMethodResponse, type CartDeliveryMethodUpdateData, type CartDeliveryMethodUpdateDto, CartDeliveryType, type CartItem, type CartItemAddDto, type CartItemAttributeDetail, CartItemErrorCode, type CartItemRemoveDto, type CartItemUpdateDto, type CartItemValidation, type CartLineItemAdjustment, type CartPromotion, CartSource, CartStatus, type CartUpdateDto, type ChargeSellerAllocation, ChargeStatus, ChargeType, type Collection, type CollectionMedia, type CollectionProductLink, type CollectionRule, CollectionRuleField, CollectionRuleFieldLabels, CollectionRuleOperator, CollectionRuleOperatorLabels, CollectionRulesLogic, CollectionStatus, CollectionStatusLabels, CollectionType, CollectionTypeLabels, type ColorVariant, type CountryDefaultBranchAddress, type CountryDefaultConfig, type CountryDefaultTax, type CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateAnalyticsSessionDto, type CreateCollectionDTO, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, type CreateRoleDTO, type CreateStoreComponentTemplateDTO, type CreateStoreTemplateDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type DesignTokens, DeviceType, DisplayOrderStatus, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, type Fulfillment, type FulfillmentDeliveryOption, type FulfillmentItem, type FulfillmentLabel, type FulfillmentLabelCreateData, type FulfillmentLabelUpdateData, type FulfillmentProviderAdapter, type FulfillmentProviderContext, type FulfillmentProviderCreateInput, type FulfillmentProviderCreateOutput, type FulfillmentProviderKey, type FulfillmentProviderProcessWebhookInput, type FulfillmentProviderProcessWebhookOutput, type FulfillmentRecollectionCapabilities, type FulfillmentRecollectionConfig, type FulfillmentRecollectionMode, type FulfillmentRecollectionSchedule, FulfillmentStatus, type FulfillmentTrackingEvent, type FunnelData, FunnelStep, type FunnelStepData, type GeoZone, type GeoZoneInput, GeoZoneStatus, type HistoricalDataPoint, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type InternalNotificationConfig, InternalNotificationType, type LinkButtonStyle, type MapPosition, type Media, MediaType, NavigationItemType, type NavigationMenuConfig, type NavigationMenuItem, type NeutralColorScale, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type PageData, PageType, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Permission, type Phone, type PickupLocation, type Product, type ProductAnalyticsData, type ProductAnalyticsItem, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, ProductVariantStatus, type Promotion, type PromotionApplicationMethod, type PromotionApplicationMethodInput, type PromotionApplicationMethodPromotionRule, PromotionApplicationType, type PromotionListFilters, type PromotionPromotionRule, type PromotionRule, type PromotionRuleInput, PromotionRuleOperator, type PromotionRuleValue, PromotionStatus, PromotionTargetType, PromotionType, PubSubTopics, type RealtimeAnalytics, type RecentEvent, type Role, type RolePermissionLink, type RoundingConfig, RoundingMethod, RoundingRule, SUPPORTED_COUNTRIES, type Seller, type SellerPeriodBalance, type ServiceBillingPlan, type ServiceBillingPlanLimits, type ServiceBillingPlanPrice, type ServiceBillingPlanSpec, type ServiceBillingPlanSpecCategory, type ServiceBillingPlanSpecItem, type SessionHeartbeatDto, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreComponentTemplate, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationFooterZone, type StoreCustomizationHeaderZone, type StoreCustomizationLayout, type StoreCustomizationLayoutComponent, type StoreCustomizationLayoutLegacy, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type StoreSettings, type StoreTemplate, type StoreTemplateMocks, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type SupportedCountryCode, type SurfaceColors, type ThemeBorderRadius, type ThemeBorderWidth, type ThemeBorders, type ThemeButtonSize, type ThemeButtonSizes, type ThemeButtonVariant, type ThemeButtonVariants, type ThemeButtons, type ThemeColorPalette, type ThemeConfig, type ThemeFonts, type ThemeProductCard, type ThemeShadows, type ThemeSpacing, type ThemeTypography, type ThemeTypographySizes, type ThemeTypographyStyles, type TopPagesData, type TrackEventDto, type TrackPageviewDto, TrafficSource, type TrafficSourceItem, type TrafficSourcesData, type TypographyStyle, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateCollectionDTO, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdateNotificationSettingsDTO, type UpdatePromotionDTO, type UpdateRoleDTO, type UpdateStoreComponentTemplateDTO, type UpdateStoreTemplateDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCountryDefaults, getCurrencySymbol, getDisplayOrderStatus, getDisplayOrderStatusInfo, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, isLegacyLayout, isSupportedCountry, isZonedLayout, parsePriceFormatPattern };
package/dist/index.d.ts CHANGED
@@ -1182,6 +1182,22 @@ declare enum OrderDeliveryType {
1182
1182
  SHIPPING = "SHIPPING",
1183
1183
  PICKUP = "PICKUP"
1184
1184
  }
1185
+ /**
1186
+ * Pseudo-estado amigable para la vista/filtro de órdenes en backoffice.
1187
+ * Cada valor se deriva de combinaciones de status, paymentStatus, fulfillmentStatus y deliveryType.
1188
+ */
1189
+ declare enum DisplayOrderStatus {
1190
+ PENDIENTES_DE_PAGO = "PENDIENTES_DE_PAGO",
1191
+ EN_PROCESO = "EN_PROCESO",
1192
+ LISTAS_PARA_ENVIAR = "LISTAS_PARA_ENVIAR",
1193
+ LISTAS_PARA_RETIRAR = "LISTAS_PARA_RETIRAR",
1194
+ ENVIADAS = "ENVIADAS",
1195
+ ENTREGADAS = "ENTREGADAS",
1196
+ EN_ESPERA = "EN_ESPERA",
1197
+ CON_PROBLEMAS = "CON_PROBLEMAS",
1198
+ CANCELADAS = "CANCELADAS",
1199
+ REEMBOLSADAS = "REEMBOLSADAS"
1200
+ }
1185
1201
  interface StatusChangeHistory {
1186
1202
  type: 'order' | 'fulfillment' | 'payment';
1187
1203
  status: OrderStatus | FulfillmentStatus | PaymentStatus;
@@ -1225,6 +1241,16 @@ interface AdminOrderStatusChangeDto {
1225
1241
 
1226
1242
  declare function getOrderStatusInfo(status: OrderStatus): StatusInfo;
1227
1243
  declare function getOrderPaymentStatusInfo(status: OrderPaymentStatus): StatusInfo;
1244
+ declare function getDisplayOrderStatusInfo(displayStatus: DisplayOrderStatus): StatusInfo;
1245
+ /** Order-like minimal shape for computing display status */
1246
+ type OrderForDisplayStatus = Pick<Order, 'status' | 'paymentStatus' | 'deliveryType'> & {
1247
+ fulfillmentStatus?: FulfillmentStatus | null;
1248
+ };
1249
+ /**
1250
+ * Derives the display (pseudo) status for an order from real status, paymentStatus, fulfillmentStatus and deliveryType.
1251
+ * Evaluation order matters: Canceladas and Reembolsadas are mutually exclusive (Canceladas wins).
1252
+ */
1253
+ declare function getDisplayOrderStatus(order: OrderForDisplayStatus): DisplayOrderStatus;
1228
1254
 
1229
1255
  /**
1230
1256
  * Add an item to the cart
@@ -1295,6 +1321,7 @@ interface CartUpdateDto {
1295
1321
  department: string;
1296
1322
  };
1297
1323
  accountPaymentMethodId?: string;
1324
+ customerNote?: string | null;
1298
1325
  }
1299
1326
  /**
1300
1327
  * Confirm a cart
@@ -3348,4 +3375,4 @@ interface AccountServiceBillingCharge {
3348
3375
  deletedAt?: Date | null;
3349
3376
  }
3350
3377
 
3351
- export { type Account, type AccountAiCreditTransaction, type AccountAiCredits, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, type AccountServiceBillingCharge, type AccountServicePlan, AccountServicePlanStatus, AccountStatus, type AccountUserRoleLink, type ActiveSession, type Address, type AdminOrderStatusChangeDto, AiCreditSource, AiCreditTransactionReason, AiCreditType, type AiCreditsBalance, type AnalyticsEvent, AnalyticsEventType, type AnalyticsFunnelStep, type AnalyticsOverview, type AnalyticsPageview, type AnalyticsPagination, type AnalyticsQueryParams, type AnalyticsSession, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, BillingInterval, type ButtonStyle, COUNTRY_DEFAULTS, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, type CampaignData, type CampaignPerformance, CampaignStatus, type Cart, type CartConfirmDto, type CartDeliveryMethod, type CartDeliveryMethodAdjustment, type CartDeliveryMethodCreateData, type CartDeliveryMethodCreateDto, type CartDeliveryMethodFindParams, type CartDeliveryMethodResponse, type CartDeliveryMethodUpdateData, type CartDeliveryMethodUpdateDto, CartDeliveryType, type CartItem, type CartItemAddDto, type CartItemAttributeDetail, CartItemErrorCode, type CartItemRemoveDto, type CartItemUpdateDto, type CartItemValidation, type CartLineItemAdjustment, type CartPromotion, CartSource, CartStatus, type CartUpdateDto, type ChargeSellerAllocation, ChargeStatus, ChargeType, type Collection, type CollectionMedia, type CollectionProductLink, type CollectionRule, CollectionRuleField, CollectionRuleFieldLabels, CollectionRuleOperator, CollectionRuleOperatorLabels, CollectionRulesLogic, CollectionStatus, CollectionStatusLabels, CollectionType, CollectionTypeLabels, type ColorVariant, type CountryDefaultBranchAddress, type CountryDefaultConfig, type CountryDefaultTax, type CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateAnalyticsSessionDto, type CreateCollectionDTO, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, type CreateRoleDTO, type CreateStoreComponentTemplateDTO, type CreateStoreTemplateDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type DesignTokens, DeviceType, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, type Fulfillment, type FulfillmentDeliveryOption, type FulfillmentItem, type FulfillmentLabel, type FulfillmentLabelCreateData, type FulfillmentLabelUpdateData, type FulfillmentProviderAdapter, type FulfillmentProviderContext, type FulfillmentProviderCreateInput, type FulfillmentProviderCreateOutput, type FulfillmentProviderKey, type FulfillmentProviderProcessWebhookInput, type FulfillmentProviderProcessWebhookOutput, type FulfillmentRecollectionCapabilities, type FulfillmentRecollectionConfig, type FulfillmentRecollectionMode, type FulfillmentRecollectionSchedule, FulfillmentStatus, type FulfillmentTrackingEvent, type FunnelData, FunnelStep, type FunnelStepData, type GeoZone, type GeoZoneInput, GeoZoneStatus, type HistoricalDataPoint, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type InternalNotificationConfig, InternalNotificationType, type LinkButtonStyle, type MapPosition, type Media, MediaType, NavigationItemType, type NavigationMenuConfig, type NavigationMenuItem, type NeutralColorScale, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type PageData, PageType, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Permission, type Phone, type PickupLocation, type Product, type ProductAnalyticsData, type ProductAnalyticsItem, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, ProductVariantStatus, type Promotion, type PromotionApplicationMethod, type PromotionApplicationMethodInput, type PromotionApplicationMethodPromotionRule, PromotionApplicationType, type PromotionListFilters, type PromotionPromotionRule, type PromotionRule, type PromotionRuleInput, PromotionRuleOperator, type PromotionRuleValue, PromotionStatus, PromotionTargetType, PromotionType, PubSubTopics, type RealtimeAnalytics, type RecentEvent, type Role, type RolePermissionLink, type RoundingConfig, RoundingMethod, RoundingRule, SUPPORTED_COUNTRIES, type Seller, type SellerPeriodBalance, type ServiceBillingPlan, type ServiceBillingPlanLimits, type ServiceBillingPlanPrice, type ServiceBillingPlanSpec, type ServiceBillingPlanSpecCategory, type ServiceBillingPlanSpecItem, type SessionHeartbeatDto, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreComponentTemplate, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationFooterZone, type StoreCustomizationHeaderZone, type StoreCustomizationLayout, type StoreCustomizationLayoutComponent, type StoreCustomizationLayoutLegacy, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type StoreSettings, type StoreTemplate, type StoreTemplateMocks, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type SupportedCountryCode, type SurfaceColors, type ThemeBorderRadius, type ThemeBorderWidth, type ThemeBorders, type ThemeButtonSize, type ThemeButtonSizes, type ThemeButtonVariant, type ThemeButtonVariants, type ThemeButtons, type ThemeColorPalette, type ThemeConfig, type ThemeFonts, type ThemeProductCard, type ThemeShadows, type ThemeSpacing, type ThemeTypography, type ThemeTypographySizes, type ThemeTypographyStyles, type TopPagesData, type TrackEventDto, type TrackPageviewDto, TrafficSource, type TrafficSourceItem, type TrafficSourcesData, type TypographyStyle, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateCollectionDTO, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdateNotificationSettingsDTO, type UpdatePromotionDTO, type UpdateRoleDTO, type UpdateStoreComponentTemplateDTO, type UpdateStoreTemplateDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCountryDefaults, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, isLegacyLayout, isSupportedCountry, isZonedLayout, parsePriceFormatPattern };
3378
+ export { type Account, type AccountAiCreditTransaction, type AccountAiCredits, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, type AccountServiceBillingCharge, type AccountServicePlan, AccountServicePlanStatus, AccountStatus, type AccountUserRoleLink, type ActiveSession, type Address, type AdminOrderStatusChangeDto, AiCreditSource, AiCreditTransactionReason, AiCreditType, type AiCreditsBalance, type AnalyticsEvent, AnalyticsEventType, type AnalyticsFunnelStep, type AnalyticsOverview, type AnalyticsPageview, type AnalyticsPagination, type AnalyticsQueryParams, type AnalyticsSession, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, BillingInterval, type ButtonStyle, COUNTRY_DEFAULTS, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, type CampaignData, type CampaignPerformance, CampaignStatus, type Cart, type CartConfirmDto, type CartDeliveryMethod, type CartDeliveryMethodAdjustment, type CartDeliveryMethodCreateData, type CartDeliveryMethodCreateDto, type CartDeliveryMethodFindParams, type CartDeliveryMethodResponse, type CartDeliveryMethodUpdateData, type CartDeliveryMethodUpdateDto, CartDeliveryType, type CartItem, type CartItemAddDto, type CartItemAttributeDetail, CartItemErrorCode, type CartItemRemoveDto, type CartItemUpdateDto, type CartItemValidation, type CartLineItemAdjustment, type CartPromotion, CartSource, CartStatus, type CartUpdateDto, type ChargeSellerAllocation, ChargeStatus, ChargeType, type Collection, type CollectionMedia, type CollectionProductLink, type CollectionRule, CollectionRuleField, CollectionRuleFieldLabels, CollectionRuleOperator, CollectionRuleOperatorLabels, CollectionRulesLogic, CollectionStatus, CollectionStatusLabels, CollectionType, CollectionTypeLabels, type ColorVariant, type CountryDefaultBranchAddress, type CountryDefaultConfig, type CountryDefaultTax, type CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateAnalyticsSessionDto, type CreateCollectionDTO, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, type CreateRoleDTO, type CreateStoreComponentTemplateDTO, type CreateStoreTemplateDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type DesignTokens, DeviceType, DisplayOrderStatus, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, type Fulfillment, type FulfillmentDeliveryOption, type FulfillmentItem, type FulfillmentLabel, type FulfillmentLabelCreateData, type FulfillmentLabelUpdateData, type FulfillmentProviderAdapter, type FulfillmentProviderContext, type FulfillmentProviderCreateInput, type FulfillmentProviderCreateOutput, type FulfillmentProviderKey, type FulfillmentProviderProcessWebhookInput, type FulfillmentProviderProcessWebhookOutput, type FulfillmentRecollectionCapabilities, type FulfillmentRecollectionConfig, type FulfillmentRecollectionMode, type FulfillmentRecollectionSchedule, FulfillmentStatus, type FulfillmentTrackingEvent, type FunnelData, FunnelStep, type FunnelStepData, type GeoZone, type GeoZoneInput, GeoZoneStatus, type HistoricalDataPoint, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type InternalNotificationConfig, InternalNotificationType, type LinkButtonStyle, type MapPosition, type Media, MediaType, NavigationItemType, type NavigationMenuConfig, type NavigationMenuItem, type NeutralColorScale, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type PageData, PageType, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Permission, type Phone, type PickupLocation, type Product, type ProductAnalyticsData, type ProductAnalyticsItem, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, ProductVariantStatus, type Promotion, type PromotionApplicationMethod, type PromotionApplicationMethodInput, type PromotionApplicationMethodPromotionRule, PromotionApplicationType, type PromotionListFilters, type PromotionPromotionRule, type PromotionRule, type PromotionRuleInput, PromotionRuleOperator, type PromotionRuleValue, PromotionStatus, PromotionTargetType, PromotionType, PubSubTopics, type RealtimeAnalytics, type RecentEvent, type Role, type RolePermissionLink, type RoundingConfig, RoundingMethod, RoundingRule, SUPPORTED_COUNTRIES, type Seller, type SellerPeriodBalance, type ServiceBillingPlan, type ServiceBillingPlanLimits, type ServiceBillingPlanPrice, type ServiceBillingPlanSpec, type ServiceBillingPlanSpecCategory, type ServiceBillingPlanSpecItem, type SessionHeartbeatDto, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreComponentTemplate, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationFooterZone, type StoreCustomizationHeaderZone, type StoreCustomizationLayout, type StoreCustomizationLayoutComponent, type StoreCustomizationLayoutLegacy, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type StoreSettings, type StoreTemplate, type StoreTemplateMocks, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type SupportedCountryCode, type SurfaceColors, type ThemeBorderRadius, type ThemeBorderWidth, type ThemeBorders, type ThemeButtonSize, type ThemeButtonSizes, type ThemeButtonVariant, type ThemeButtonVariants, type ThemeButtons, type ThemeColorPalette, type ThemeConfig, type ThemeFonts, type ThemeProductCard, type ThemeShadows, type ThemeSpacing, type ThemeTypography, type ThemeTypographySizes, type ThemeTypographyStyles, type TopPagesData, type TrackEventDto, type TrackPageviewDto, TrafficSource, type TrafficSourceItem, type TrafficSourcesData, type TypographyStyle, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateCollectionDTO, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdateNotificationSettingsDTO, type UpdatePromotionDTO, type UpdateRoleDTO, type UpdateStoreComponentTemplateDTO, type UpdateStoreTemplateDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCountryDefaults, getCurrencySymbol, getDisplayOrderStatus, getDisplayOrderStatusInfo, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, isLegacyLayout, isSupportedCountry, isZonedLayout, parsePriceFormatPattern };
package/dist/index.js CHANGED
@@ -63,6 +63,7 @@ __export(index_exports, {
63
63
  DayOfWeek: () => DayOfWeek,
64
64
  DeliveryType: () => DeliveryType,
65
65
  DeviceType: () => DeviceType,
66
+ DisplayOrderStatus: () => DisplayOrderStatus,
66
67
  FulfillmentStatus: () => FulfillmentStatus,
67
68
  FunnelStep: () => FunnelStep,
68
69
  GeoZoneStatus: () => GeoZoneStatus,
@@ -111,6 +112,8 @@ __export(index_exports, {
111
112
  getAccountPaymentMethodStatusInfo: () => getAccountPaymentMethodStatusInfo,
112
113
  getCountryDefaults: () => getCountryDefaults,
113
114
  getCurrencySymbol: () => getCurrencySymbol,
115
+ getDisplayOrderStatus: () => getDisplayOrderStatus,
116
+ getDisplayOrderStatusInfo: () => getDisplayOrderStatusInfo,
114
117
  getFulfillmentStatusInfo: () => getFulfillmentStatusInfo,
115
118
  getIntegrationCategoryName: () => getIntegrationCategoryName,
116
119
  getOrderPaymentStatusInfo: () => getOrderPaymentStatusInfo,
@@ -523,6 +526,28 @@ var OrderDeliveryType = /* @__PURE__ */ ((OrderDeliveryType2) => {
523
526
  OrderDeliveryType2["PICKUP"] = "PICKUP";
524
527
  return OrderDeliveryType2;
525
528
  })(OrderDeliveryType || {});
529
+ var DisplayOrderStatus = /* @__PURE__ */ ((DisplayOrderStatus2) => {
530
+ DisplayOrderStatus2["PENDIENTES_DE_PAGO"] = "PENDIENTES_DE_PAGO";
531
+ DisplayOrderStatus2["EN_PROCESO"] = "EN_PROCESO";
532
+ DisplayOrderStatus2["LISTAS_PARA_ENVIAR"] = "LISTAS_PARA_ENVIAR";
533
+ DisplayOrderStatus2["LISTAS_PARA_RETIRAR"] = "LISTAS_PARA_RETIRAR";
534
+ DisplayOrderStatus2["ENVIADAS"] = "ENVIADAS";
535
+ DisplayOrderStatus2["ENTREGADAS"] = "ENTREGADAS";
536
+ DisplayOrderStatus2["EN_ESPERA"] = "EN_ESPERA";
537
+ DisplayOrderStatus2["CON_PROBLEMAS"] = "CON_PROBLEMAS";
538
+ DisplayOrderStatus2["CANCELADAS"] = "CANCELADAS";
539
+ DisplayOrderStatus2["REEMBOLSADAS"] = "REEMBOLSADAS";
540
+ return DisplayOrderStatus2;
541
+ })(DisplayOrderStatus || {});
542
+
543
+ // src/fulfillment/types.ts
544
+ var FulfillmentStatus = /* @__PURE__ */ ((FulfillmentStatus2) => {
545
+ FulfillmentStatus2["PENDING"] = "pending";
546
+ FulfillmentStatus2["SHIPPED"] = "shipped";
547
+ FulfillmentStatus2["DELIVERED"] = "delivered";
548
+ FulfillmentStatus2["CANCELLED"] = "cancelled";
549
+ return FulfillmentStatus2;
550
+ })(FulfillmentStatus || {});
526
551
 
527
552
  // src/order/helpers.ts
528
553
  function getOrderStatusInfo(status) {
@@ -549,6 +574,50 @@ function getOrderPaymentStatusInfo(status) {
549
574
  };
550
575
  return map[status] ?? { text: String(status), class: "secondary" };
551
576
  }
577
+ var DISPLAY_ORDER_STATUS_INFO = {
578
+ ["PENDIENTES_DE_PAGO" /* PENDIENTES_DE_PAGO */]: { text: "Pendientes de pago", class: "warning", actionText: "" },
579
+ ["EN_PROCESO" /* EN_PROCESO */]: { text: "En proceso", class: "info", actionText: "" },
580
+ ["LISTAS_PARA_ENVIAR" /* LISTAS_PARA_ENVIAR */]: { text: "Listas para enviar", class: "primary", actionText: "" },
581
+ ["LISTAS_PARA_RETIRAR" /* LISTAS_PARA_RETIRAR */]: { text: "Listas para retirar", class: "primary", actionText: "" },
582
+ ["ENVIADAS" /* ENVIADAS */]: { text: "Enviadas", class: "warning", actionText: "" },
583
+ ["ENTREGADAS" /* ENTREGADAS */]: { text: "Entregadas", class: "success", actionText: "" },
584
+ ["EN_ESPERA" /* EN_ESPERA */]: { text: "En espera", class: "secondary", actionText: "" },
585
+ ["CON_PROBLEMAS" /* CON_PROBLEMAS */]: { text: "Con problemas", class: "danger", actionText: "" },
586
+ ["CANCELADAS" /* CANCELADAS */]: { text: "Canceladas", class: "danger", actionText: "" },
587
+ ["REEMBOLSADAS" /* REEMBOLSADAS */]: { text: "Reembolsadas", class: "success", actionText: "" }
588
+ };
589
+ function getDisplayOrderStatusInfo(displayStatus) {
590
+ return DISPLAY_ORDER_STATUS_INFO[displayStatus] ?? { text: String(displayStatus), class: "secondary" };
591
+ }
592
+ function getDisplayOrderStatus(order) {
593
+ const status = order.status;
594
+ const paymentStatus = order.paymentStatus;
595
+ const fulfillmentStatus = order.fulfillmentStatus ?? "pending" /* PENDING */;
596
+ const deliveryType = order.deliveryType;
597
+ if (status === "CANCELLED" /* CANCELLED */) return "CANCELADAS" /* CANCELADAS */;
598
+ if (paymentStatus === "REFUNDED" /* REFUNDED */ || paymentStatus === "PARTIALLY_REFUNDED" /* PARTIALLY_REFUNDED */) {
599
+ return "REEMBOLSADAS" /* REEMBOLSADAS */;
600
+ }
601
+ if (status === "FAILED" /* FAILED */) return "CON_PROBLEMAS" /* CON_PROBLEMAS */;
602
+ if (status === "ON_HOLD" /* ON_HOLD */) return "EN_ESPERA" /* EN_ESPERA */;
603
+ if (status === "COMPLETED" /* COMPLETED */ || fulfillmentStatus === "delivered" /* DELIVERED */) {
604
+ return "ENTREGADAS" /* ENTREGADAS */;
605
+ }
606
+ if (fulfillmentStatus === "shipped" /* SHIPPED */) return "ENVIADAS" /* ENVIADAS */;
607
+ if (status === "PROCESSED" /* PROCESSED */ && deliveryType === "SHIPPING" /* SHIPPING */ && fulfillmentStatus === "pending" /* PENDING */) {
608
+ return "LISTAS_PARA_ENVIAR" /* LISTAS_PARA_ENVIAR */;
609
+ }
610
+ if (status === "PROCESSED" /* PROCESSED */ && deliveryType === "PICKUP" /* PICKUP */) {
611
+ return "LISTAS_PARA_RETIRAR" /* LISTAS_PARA_RETIRAR */;
612
+ }
613
+ if ((status === "CONFIRMED" /* CONFIRMED */ || status === "PROCESSING" /* PROCESSING */) && (paymentStatus === "PAID" /* PAID */ || paymentStatus === "OVERPAID" /* OVERPAID */)) {
614
+ return "EN_PROCESO" /* EN_PROCESO */;
615
+ }
616
+ if (status === "PENDING" /* PENDING */ && (paymentStatus === "PENDING" /* PENDING */ || paymentStatus === "PARTIAL" /* PARTIAL */)) {
617
+ return "PENDIENTES_DE_PAGO" /* PENDIENTES_DE_PAGO */;
618
+ }
619
+ return "PENDIENTES_DE_PAGO" /* PENDIENTES_DE_PAGO */;
620
+ }
552
621
 
553
622
  // src/payment/types.ts
554
623
  var PaymentStatus = /* @__PURE__ */ ((PaymentStatus2) => {
@@ -955,15 +1024,6 @@ var SupportConversationMessageSenderType = /* @__PURE__ */ ((SupportConversation
955
1024
  return SupportConversationMessageSenderType2;
956
1025
  })(SupportConversationMessageSenderType || {});
957
1026
 
958
- // src/fulfillment/types.ts
959
- var FulfillmentStatus = /* @__PURE__ */ ((FulfillmentStatus2) => {
960
- FulfillmentStatus2["PENDING"] = "pending";
961
- FulfillmentStatus2["SHIPPED"] = "shipped";
962
- FulfillmentStatus2["DELIVERED"] = "delivered";
963
- FulfillmentStatus2["CANCELLED"] = "cancelled";
964
- return FulfillmentStatus2;
965
- })(FulfillmentStatus || {});
966
-
967
1027
  // src/fulfillment/helpers.ts
968
1028
  function getFulfillmentStatusInfo(status) {
969
1029
  const map = {
@@ -1162,6 +1222,7 @@ var ChargeStatus = /* @__PURE__ */ ((ChargeStatus2) => {
1162
1222
  DayOfWeek,
1163
1223
  DeliveryType,
1164
1224
  DeviceType,
1225
+ DisplayOrderStatus,
1165
1226
  FulfillmentStatus,
1166
1227
  FunnelStep,
1167
1228
  GeoZoneStatus,
@@ -1210,6 +1271,8 @@ var ChargeStatus = /* @__PURE__ */ ((ChargeStatus2) => {
1210
1271
  getAccountPaymentMethodStatusInfo,
1211
1272
  getCountryDefaults,
1212
1273
  getCurrencySymbol,
1274
+ getDisplayOrderStatus,
1275
+ getDisplayOrderStatusInfo,
1213
1276
  getFulfillmentStatusInfo,
1214
1277
  getIntegrationCategoryName,
1215
1278
  getOrderPaymentStatusInfo,