diff --git a/packages/admin-ui/src/lib/order/src/common/modify-order-types.ts b/packages/admin-ui/src/lib/order/src/common/modify-order-types.ts index 10a2856be5..5b7cb5b6dd 100644 --- a/packages/admin-ui/src/lib/order/src/common/modify-order-types.ts +++ b/packages/admin-ui/src/lib/order/src/common/modify-order-types.ts @@ -4,8 +4,8 @@ import { ModifyOrderInput, OrderDetailFragment, OrderLineInput, + ProductSelectorSearchQuery, } from '@vendure/admin-ui/core'; -import { ProductSelectorItem } from '../components/order-editor/order-editor.component'; export interface OrderSnapshot { totalWithTax: number; @@ -14,6 +14,8 @@ export interface OrderSnapshot { lines: OrderDetailFragment['lines']; } +export type ProductSelectorItem = ProductSelectorSearchQuery['search']['items'][number]; + export interface AddedLine { id: string; featuredAsset?: ProductSelectorItem['productAsset'] | null; diff --git a/packages/admin-ui/src/lib/order/src/components/order-editor/order-editor.component.ts b/packages/admin-ui/src/lib/order/src/components/order-editor/order-editor.component.ts index 70cd1e6a5a..833826a950 100644 --- a/packages/admin-ui/src/lib/order/src/components/order-editor/order-editor.component.ts +++ b/packages/admin-ui/src/lib/order/src/components/order-editor/order-editor.component.ts @@ -20,7 +20,6 @@ import { OrderAddressFragment, OrderDetailFragment, OrderDetailQueryDocument, - ProductSelectorSearchQuery, SortOrder, SurchargeInput, transformRelationCustomFieldInputs, @@ -30,7 +29,12 @@ import { assertNever, notNullOrUndefined } from '@vendure/common/lib/shared-util import { simpleDeepClone } from '@vendure/common/lib/simple-deep-clone'; import { EMPTY, Observable, of } from 'rxjs'; import { mapTo, shareReplay, switchMap, take, takeUntil } from 'rxjs/operators'; -import { AddedLine, ModifyOrderData, OrderSnapshot } from '../../common/modify-order-types'; +import { + AddedLine, + ModifyOrderData, + OrderSnapshot, + ProductSelectorItem, +} from '../../common/modify-order-types'; import { OrderTransitionService } from '../../providers/order-transition.service'; import { @@ -38,8 +42,6 @@ import { OrderEditsPreviewDialogComponent, } from '../order-edits-preview-dialog/order-edits-preview-dialog.component'; -export type ProductSelectorItem = ProductSelectorSearchQuery['search']['items'][number]; - @Component({ selector: 'vdr-order-editor', templateUrl: './order-editor.component.html', diff --git a/packages/admin-ui/src/lib/order/src/components/order-modification-summary/order-modification-summary.component.ts b/packages/admin-ui/src/lib/order/src/components/order-modification-summary/order-modification-summary.component.ts index ce982f7612..787bded990 100644 --- a/packages/admin-ui/src/lib/order/src/components/order-modification-summary/order-modification-summary.component.ts +++ b/packages/admin-ui/src/lib/order/src/components/order-modification-summary/order-modification-summary.component.ts @@ -1,7 +1,7 @@ import { ChangeDetectionStrategy, Component, Input } from '@angular/core'; import { FormControl, FormGroup } from '@angular/forms'; -import { OrderEditorComponent } from '@vendure/admin-ui/order'; import { notNullOrUndefined } from '@vendure/common/lib/shared-utils'; +import type { OrderEditorComponent } from '../order-editor/order-editor.component'; import { AddedLine, ModifyOrderData, OrderSnapshot } from '../../common/modify-order-types'; @Component({ diff --git a/packages/admin-ui/src/lib/order/src/order.module.ts b/packages/admin-ui/src/lib/order/src/order.module.ts index 6c856b0eaa..fe875f98ae 100644 --- a/packages/admin-ui/src/lib/order/src/order.module.ts +++ b/packages/admin-ui/src/lib/order/src/order.module.ts @@ -38,6 +38,7 @@ import { OrderStateSelectDialogComponent } from './components/order-state-select import { OrderTableComponent } from './components/order-table/order-table.component'; import { PaymentDetailComponent } from './components/payment-detail/payment-detail.component'; import { PaymentStateLabelComponent } from './components/payment-state-label/payment-state-label.component'; +import { RefundDetailComponent } from './components/refund-detail/refund-detail.component'; import { RefundOrderDialogComponent } from './components/refund-order-dialog/refund-order-dialog.component'; import { RefundStateLabelComponent } from './components/refund-state-label/refund-state-label.component'; import { SelectAddressDialogComponent } from './components/select-address-dialog/select-address-dialog.component'; @@ -102,6 +103,7 @@ import { OrderModificationSummaryComponent } from './components/order-modificati OrderTotalColumnComponent, PaymentForRefundSelectorComponent, OrderModificationSummaryComponent, + RefundDetailComponent, ], exports: [OrderCustomFieldsCardComponent], }) diff --git a/packages/admin-ui/src/lib/order/src/public_api.ts b/packages/admin-ui/src/lib/order/src/public_api.ts index ef9b27472d..26c1b9de4f 100644 --- a/packages/admin-ui/src/lib/order/src/public_api.ts +++ b/packages/admin-ui/src/lib/order/src/public_api.ts @@ -1,4 +1,6 @@ // This file was generated by the build-public-api.ts script +export * from './common/get-refundable-payments'; +export * from './common/modify-order-types'; export * from './components/add-manual-payment-dialog/add-manual-payment-dialog.component'; export * from './components/cancel-order-dialog/cancel-order-dialog.component'; export * from './components/coupon-code-selector/coupon-code-selector.component'; @@ -20,6 +22,7 @@ export * from './components/order-edits-preview-dialog/order-edits-preview-dialo export * from './components/order-history/order-history-entry-host.component'; export * from './components/order-history/order-history.component'; export * from './components/order-list/order-list.component'; +export * from './components/order-modification-summary/order-modification-summary.component'; export * from './components/order-payment-card/order-payment-card.component'; export * from './components/order-process-graph/constants'; export * from './components/order-process-graph/order-process-edge.component'; @@ -30,7 +33,9 @@ export * from './components/order-process-graph-dialog/order-process-graph-dialo export * from './components/order-state-select-dialog/order-state-select-dialog.component'; export * from './components/order-table/order-table.component'; export * from './components/payment-detail/payment-detail.component'; +export * from './components/payment-for-refund-selector/payment-for-refund-selector.component'; export * from './components/payment-state-label/payment-state-label.component'; +export * from './components/refund-detail/refund-detail.component'; export * from './components/refund-order-dialog/refund-order-dialog.component'; export * from './components/refund-state-label/refund-state-label.component'; export * from './components/select-address-dialog/select-address-dialog.component'; @@ -45,5 +50,3 @@ export * from './order.module'; export * from './order.routes'; export * from './providers/order-transition.service'; export * from './providers/routing/order.guard'; -export { AddedLine } from './common/modify-order-types'; -export { ModifyOrderData } from './common/modify-order-types';