feat(fulfillment): Soft deletes (#6630)
**What** - Ensure soft delete works properly according to the soft delete configuration and validate all relation of the entire data model - Add is_enabled to the providers in order to manage new providers to enabled or disabled - include joiner config update FIXES CORE-1853 FIXES CORE-1830 FIXES CORE-1719
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
||||
import { ShippingOptionDTO } from "./shipping-option"
|
||||
|
||||
export interface ServiceProviderDTO {
|
||||
export interface FulfillmentProviderDTO {
|
||||
id: string
|
||||
name: string
|
||||
metadata: Record<string, unknown> | null
|
||||
@@ -1,5 +1,5 @@
|
||||
import { ShippingOptionDTO } from "./shipping-option"
|
||||
import { ServiceProviderDTO } from "./service-provider"
|
||||
import { FulfillmentProviderDTO } from "./fulfillment-provider"
|
||||
import { FulfillmentAddressDTO } from "./address"
|
||||
import { FulfillmentItemDTO } from "./fulfillment-item"
|
||||
import { FulfillmentLabelDTO } from "./fulfillment-label"
|
||||
@@ -17,7 +17,7 @@ export interface FulfillmentDTO {
|
||||
shipping_option_id: string | null
|
||||
metadata: Record<string, unknown> | null
|
||||
shipping_option: ShippingOptionDTO | null
|
||||
provider: ServiceProviderDTO
|
||||
provider: FulfillmentProviderDTO
|
||||
delivery_address: FulfillmentAddressDTO
|
||||
items: FulfillmentItemDTO[]
|
||||
labels: FulfillmentLabelDTO[]
|
||||
|
||||
@@ -6,7 +6,7 @@ export * from "./shipping-option"
|
||||
export * from "./shipping-option-type"
|
||||
export * from "./service-zone"
|
||||
export * from "./geo-zone"
|
||||
export * from "./service-provider"
|
||||
export * from "./fulfillment-provider"
|
||||
export * from "./fulfillment"
|
||||
export * from "./fulfillment-item"
|
||||
export * from "./fulfillment-label"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { FilterableServiceZoneProps, ServiceZoneDTO } from "./service-zone"
|
||||
import { ShippingProfileDTO } from "./shipping-profile"
|
||||
import { ServiceProviderDTO } from "./service-provider"
|
||||
import { FulfillmentProviderDTO } from "./fulfillment-provider"
|
||||
import {
|
||||
FilterableShippingOptionTypeProps,
|
||||
ShippingOptionTypeDTO,
|
||||
@@ -10,6 +10,7 @@ import {
|
||||
ShippingOptionRuleDTO,
|
||||
} from "./shipping-option-rule"
|
||||
import { BaseFilterable, OperatorMap } from "../../dal"
|
||||
import { FulfillmentDTO } from "./fulfillment"
|
||||
|
||||
export type ShippingOptionPriceType = "calculated" | "flat"
|
||||
|
||||
@@ -19,15 +20,16 @@ export interface ShippingOptionDTO {
|
||||
price_type: ShippingOptionPriceType
|
||||
service_zone_id: string
|
||||
shipping_profile_id: string
|
||||
service_provider_id: string
|
||||
fulfillment_provider_id: string
|
||||
shipping_option_type_id: string | null
|
||||
data: Record<string, unknown> | null
|
||||
metadata: Record<string, unknown> | null
|
||||
service_zone: ServiceZoneDTO
|
||||
shipping_profile: ShippingProfileDTO
|
||||
service_provider: ServiceProviderDTO
|
||||
shipping_option_type: ShippingOptionTypeDTO
|
||||
fulfillment_provider: FulfillmentProviderDTO
|
||||
type: ShippingOptionTypeDTO
|
||||
rules: ShippingOptionRuleDTO[]
|
||||
fulfillments: FulfillmentDTO[]
|
||||
created_at: Date
|
||||
updated_at: Date
|
||||
deleted_at: Date | null
|
||||
|
||||
@@ -7,7 +7,7 @@ export interface CreateShippingOptionDTO {
|
||||
price_type: ShippingOptionPriceType
|
||||
service_zone_id: string
|
||||
shipping_profile_id: string
|
||||
service_provider_id: string
|
||||
fulfillment_provider_id: string
|
||||
type: Omit<CreateShippingOptionTypeDTO, "shipping_option_id">
|
||||
data?: Record<string, unknown> | null
|
||||
rules?: Omit<CreateShippingOptionRuleDTO, "shipping_option_id">[]
|
||||
@@ -19,7 +19,7 @@ export interface UpdateShippingOptionDTO {
|
||||
price_type?: ShippingOptionPriceType
|
||||
service_zone_id?: string
|
||||
shipping_profile_id?: string
|
||||
service_provider_id?: string
|
||||
fulfillment_provider_id?: string
|
||||
type: Omit<CreateShippingOptionTypeDTO, "shipping_option_id"> | { id: string }
|
||||
data?: Record<string, unknown> | null
|
||||
rules?: (
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user